Series#

The Series level is the natural level of interaction for most use cases in imaging, since individual scans are typically stored in separate series.

Reading values#

Series.coords

return a dictionary of coordinates.

Series.values

Return the values of one or more attributes for each frame in the series.

Series.frames

Return the frames of given coordinates in the correct order

Series.shape

Return the shape of the series along given dimensions.

Series.spacing

3D pixel spacing in mm

Series.unique

Return the unique values of an attribute, sorted by any number of variables.

Series.gridcoords

return a dictionary of grid coordinates.

Series.pixel_values

Return a numpy.ndarray with pixel data.

Series.affine

Return the affine of the Series.

Setting values#

Series.set_coords

Set a dictionary of coordinates.

Series.set_gridcoords

Set a dictionary of grid coordinates.

Series.set_values

Set the values of an attribute.

Series.set_pixel_values

Set a numpy.ndarray with pixel data.

Series.set_affine

Set the affine matrix of a series.

Reshaping#

Series.expand

Series.extract

Get a slice of the series by dimension values

Series.split_by

Split the series into multiple subseries based on keyword value.