The yt-napari JSON schema

The yt-napari plugins rely on pydantic models for setting variables and properties required to load in data from yt. The primary pydantic model, is exported as a json-schema to facilitate loading in data (see the json schema example) and to semi-automatically build the widget plugin.

The latest json schema is rendered below, but the raw json can be viewed directly here or downloaded here.

InputModel

type

object

properties

  • datasets

Datasets

list of dataset containers to load

type

array

default

null

items

#/$defs/DataContainer

  • timeseries

Timeseries

List of timeseries to load

type

array

default

null

items

#/$defs/Timeseries

$defs

  • DataContainer

DataContainer

type

object

properties

  • filename

Filename

the filename for the dataset

type

string

default

null

  • selections

selections to load in this dataset

default

null

allOf

#/$defs/SelectionObject

  • store_in_cache

Store In Cache

if enabled, will store references to yt datasets.

type

boolean

default

True

  • Left_Edge

Left_Edge

type

object

properties

  • value

Value

3-element unitful tuple.

type

array

default

0.0

0.0

0.0

maxItems

3

minItems

3

  • unit

Unit

the unit length string.

type

string

default

code_length

  • Length_Tuple

Length_Tuple

type

object

properties

  • value

Value

3-element unitful tuple.

type

array

default

null

maxItems

3

minItems

3

  • unit

Unit

the unit length string.

type

string

default

code_length

  • Length_Value

Length_Value

type

object

properties

  • value

Value

Single unitful value.

type

number

default

null

  • unit

Unit

the unit length string.

type

string

default

code_length

  • Region

Region

type

object

properties

  • fields

Fields

list of fields to load for this selection

type

array

default

null

items

#/$defs/ytField

  • left_edge

the left edge (min x, min y, min z)

default

null

allOf

#/$defs/Left_Edge

  • right_edge

the right edge (max x, max y, max z)

default

null

allOf

#/$defs/Right_Edge

  • resolution

Resolution

the resolution at which to sample between the edges.

type

array

default

400

400

400

maxItems

3

minItems

3

  • rescale

Rescale

rescale the final image between 0,1

type

boolean

default

False

  • Right_Edge

Right_Edge

type

object

properties

  • value

Value

3-element unitful tuple.

type

array

default

1.0

1.0

1.0

maxItems

3

minItems

3

  • unit

Unit

the unit length string.

type

string

default

code_length

  • SelectionObject

SelectionObject

type

object

properties

  • regions

Regions

a list of regions to load

type

array

default

null

items

#/$defs/Region

  • slices

Slices

a list of slices to load

type

array

default

null

items

#/$defs/Slice

  • Slice

Slice

type

object

properties

  • fields

Fields

list of fields to load for this selection

type

array

default

null

items

#/$defs/ytField

  • normal

Normal

the normal axis of the slice

type

string

default

null

  • center

The center point of the slice, default domain center

default

null

allOf

#/$defs/Length_Tuple

  • slice_width

The slice width, defaults to full domain

default

null

allOf

#/$defs/Length_Value

  • slice_height

The slice width, defaults to full domain

default

null

allOf

#/$defs/Length_Value

  • resolution

Resolution

the resolution at which to sample the slice

type

array

default

400

400

maxItems

2

minItems

2

  • periodic

Periodic

should the slice be periodic? default False.

type

boolean

default

False

  • rescale

Rescale

rescale the final image between 0,1

type

boolean

default

False

  • TimeSeriesFileSelection

TimeSeriesFileSelection

type

object

properties

  • directory

Directory

The directory of the timseries

type

string

default

null

  • file_pattern

File Pattern

The file pattern to match

type

string

default

null

  • file_list

File List

List of files to load.

type

array

default

null

items

type

string

  • file_range

File Range

Given files matched by file_pattern, this option will select a range. Argument orderis taken as start:stop:step.

type

array

default

null

maxItems

3

minItems

3

  • Timeseries

Timeseries

type

object

properties

  • file_selection

#/$defs/TimeSeriesFileSelection

  • selections

selections to load in this dataset

default

null

allOf

#/$defs/SelectionObject

  • load_as_stack

Load As Stack

If True, will stack images along a new dimension.

type

boolean

default

False

  • ytField

ytField

type

object

properties

  • field_type

Field Type

a field type in the yt dataset

type

string

default

null

  • field_name

Field Name

a field in the yt dataset

type

string

default

null

  • take_log

Take Log

if true, will apply log10 to the selected data

type

boolean

default

True

List of schema versions

The following versions are available (latest first):

yt-napari_0.4.0.json : view , download

yt-napari_0.3.0.json : view , download

yt-napari_0.2.1.json : view , download

yt-napari_0.2.0.json : view , download

yt-napari_0.1.0.json : view , download

yt-napari_0.0.1.json : view , download