Bases: NBOBaseClass
Represents the XML element Pixels.
The Pixels element is going to be removed in the future, but it is still required. This is just notice that the contents of Pixels will be moved up to Image in a future release. This is because there has only been 1 Pixels object in each Image for some time. The concept of multiple Pixels sets for one Image failed to take off. It is therefore redundant. The Image will be unreadable if any of the required Pixel attributes are missing. The Pixels themselves can be stored within the OME-XML compressed by Plane, and encoded in Base64. Or the Pixels may be stored in TIFF format. The Pixels element should contain a list of BinData or TiffData, each containing a single Plane of pixels. These Pixels elements, when read in document order, must produce a 5-D Pixel array of the size specified in this element, and in the dimension order specified by 'DimensionOrder'. All of the values in the Pixels object when present should match the same value stored in any associated TIFF format (e.g. SizeX should be the same). Where there is a mismatch our readers will take the value from the TIFF structure as overriding the value in the OME-XML. This is simply a pragmatic decision as it increases the likelihood of reading data from a slightly incorrect file.
fromBase ( base )
staticmethod
fromJsonFile ( path , validate = True )
fromJsonString ( json_string , validate = True )
fromXmlFile ( path , validate = True )
fromXmlString ( xml_string , validate = True )
toXmlFile ( filename , validate = True )
toXmlString ( validate = True )
setID ( value , validate = True )
setDimensionOrder ( value , validate = True )
setSizeX ( value , validate = True )
setSizeY ( value , validate = True )
setSizeZ ( value , validate = True )
setSizeC ( value , validate = True )
setSizeT ( value , validate = True )
setPhysicalSizeX ( value , validate = True )
hasPhysicalSizeX ()
Checks whether the optional PhysicalSizeX attribute is present.
This field records the real world Physical Width represented by a Pixel in this Image. This measure is often referred to as X Pixel Size.
Returns:
Type
Description
boolean
true if the optional attribute has been set, false otherwise
setPhysicalSizeXUnit ( value , validate = True )
setPhysicalSizeY ( value , validate = True )
hasPhysicalSizeY ()
Checks whether the optional PhysicalSizeY attribute is present.
This field records the real world Physical Height represented by a Pixel in this Image. This measure is often referred to as Y Pixel Size.
Returns:
Type
Description
boolean
true if the optional attribute has been set, false otherwise
setPhysicalSizeYUnit ( value , validate = True )
setPhysicalSizeZ ( value , validate = True )
Sets the value of the PhysicalSizeZ attribute.
This field records the real world Physical distance between the individual Z-Planes recorded for this Image. This measure is sometimes referred to as Z Pixel or Voxel Size.
Parameters:
Name
Type
Description
Default
value
PositiveFloat_Type
required
validate
(boolean , optional )
If true, validates constraints on value. Default is true.
True
getPhysicalSizeZ ()
Returns the value of the PhysicalSizeZ attribute.
This field records the real world Physical distance between the individual Z-Planes recorded for this Image. This measure is sometimes referred to as Z Pixel or Voxel Size.
Returns:
Type
Description
PositiveFloat_Type
The value of the attribute
resetPhysicalSizeZ ()
Resets the PhysicalSizeZ attribute to an unset state.
This field records the real world Physical distance between the individual Z-Planes recorded for this Image. This measure is sometimes referred to as Z Pixel or Voxel Size.
hasPhysicalSizeZ ()
Checks whether the optional PhysicalSizeZ attribute is present.
This field records the real world Physical distance between the individual Z-Planes recorded for this Image. This measure is sometimes referred to as Z Pixel or Voxel Size.
Returns:
Type
Description
boolean
true if the optional attribute has been set, false otherwise
setPhysicalSizeZUnit ( value , validate = True )
setTimeIncrement ( value , validate = True )
Sets the value of the TimeIncrement attribute.
In cases in which a time series is acquired with a global timing specification setting, this field describes the time between each sequential plane (or frame) in the series (i.e., from the start of time point 1 to the start of time point 2). Examples include, a video stream or a multi-dimensional Acquisition routine. Note that, this field is not intended to substitute the Timestamp attribute recorded in Plane. Also note that in case this field is not relevant e.g. a time lapse Acquisition with irregular increments, the value -1 should be used to indicate that only the Timestamps (in the Plane element) are valid.
Parameters:
Name
Type
Description
Default
value
PositiveFloat_Type
required
validate
(boolean , optional )
If true, validates constraints on value. Default is true.
True
getTimeIncrement ()
Returns the value of the TimeIncrement attribute.
In cases in which a time series is acquired with a global timing specification setting, this field describes the time between each sequential plane (or frame) in the series (i.e., from the start of time point 1 to the start of time point 2). Examples include, a video stream or a multi-dimensional Acquisition routine. Note that, this field is not intended to substitute the Timestamp attribute recorded in Plane. Also note that in case this field is not relevant e.g. a time lapse Acquisition with irregular increments, the value -1 should be used to indicate that only the Timestamps (in the Plane element) are valid.
Returns:
Type
Description
PositiveFloat_Type
The value of the attribute
resetTimeIncrement ()
Resets the TimeIncrement attribute to an unset state.
In cases in which a time series is acquired with a global timing specification setting, this field describes the time between each sequential plane (or frame) in the series (i.e., from the start of time point 1 to the start of time point 2). Examples include, a video stream or a multi-dimensional Acquisition routine. Note that, this field is not intended to substitute the Timestamp attribute recorded in Plane. Also note that in case this field is not relevant e.g. a time lapse Acquisition with irregular increments, the value -1 should be used to indicate that only the Timestamps (in the Plane element) are valid.
hasTimeIncrement ()
Checks whether the optional TimeIncrement attribute is present.
In cases in which a time series is acquired with a global timing specification setting, this field describes the time between each sequential plane (or frame) in the series (i.e., from the start of time point 1 to the start of time point 2). Examples include, a video stream or a multi-dimensional Acquisition routine. Note that, this field is not intended to substitute the Timestamp attribute recorded in Plane. Also note that in case this field is not relevant e.g. a time lapse Acquisition with irregular increments, the value -1 should be used to indicate that only the Timestamps (in the Plane element) are valid.
Returns:
Type
Description
boolean
true if the optional attribute has been set, false otherwise
setTimeIncrementUnit ( value , validate = True )
setPixelType ( value , validate = True )
setInterleaved ( value , validate = True )
Sets the value of the Interleaved attribute.
This field records the order in which the Channels are arranged within the data block: True if Channels are stored RGBRGBRGB...; False if Channels are stored RRR...GGG...BBB…
Parameters:
Name
Type
Description
Default
value
boolean
required
validate
(boolean , optional )
If true, validates constraints on value. Default is true.
True
getInterleaved ()
Returns the value of the Interleaved attribute.
This field records the order in which the Channels are arranged within the data block: True if Channels are stored RGBRGBRGB...; False if Channels are stored RRR...GGG...BBB…
Returns:
Type
Description
boolean
The value of the attribute
resetInterleaved ()
Resets the Interleaved attribute to an unset state.
This field records the order in which the Channels are arranged within the data block: True if Channels are stored RGBRGBRGB...; False if Channels are stored RRR...GGG...BBB…
hasInterleaved ()
Checks whether the Interleaved attribute is present.
This field records the order in which the Channels are arranged within the data block: True if Channels are stored RGBRGBRGB...; False if Channels are stored RRR...GGG...BBB…
Returns:
Type
Description
boolean
true if the attribute has been set, false otherwise
setSignificantBits ( value , validate = True )
Sets the value of the SignificantBits attribute.
This field records the number of bits within the type storing each Pixel value that are significant. e.g.,. you can store 12-bit data within a 16-bit type. This does not reduce the storage requirements but can be a useful indicator when processing or viewing the Image data.
Parameters:
Name
Type
Description
Default
value
PositiveInt_Type
required
validate
(boolean , optional )
If true, validates constraints on value. Default is true.
True
getSignificantBits ()
Returns the value of the SignificantBits attribute.
This field records the number of bits within the type storing each Pixel value that are significant. e.g.,. you can store 12-bit data within a 16-bit type. This does not reduce the storage requirements but can be a useful indicator when processing or viewing the Image data.
Returns:
Type
Description
PositiveInt_Type
The value of the attribute
resetSignificantBits ()
Resets the SignificantBits attribute to an unset state.
This field records the number of bits within the type storing each Pixel value that are significant. e.g.,. you can store 12-bit data within a 16-bit type. This does not reduce the storage requirements but can be a useful indicator when processing or viewing the Image data.
hasSignificantBits ()
Checks whether the optional SignificantBits attribute is present.
This field records the number of bits within the type storing each Pixel value that are significant. e.g.,. you can store 12-bit data within a 16-bit type. This does not reduce the storage requirements but can be a useful indicator when processing or viewing the Image data.
Returns:
Type
Description
boolean
true if the optional attribute has been set, false otherwise
setBigEndian ( value , validate = True )
Sets the value of the BigEndian attribute.
This field is True if the pixels data was written in BigEndian order. If this value is present, it should match the value used in BinData or TiffData. If it is not, a reader should be used that honors the value used in the BinData or TiffData. This value is useful for MetadataOnly files and is to allow for future storage solutions.
Parameters:
Name
Type
Description
Default
value
boolean
required
validate
(boolean , optional )
If true, validates constraints on value. Default is true.
True
getBigEndian ()
Returns the value of the BigEndian attribute.
This field is True if the pixels data was written in BigEndian order. If this value is present, it should match the value used in BinData or TiffData. If it is not, a reader should be used that honors the value used in the BinData or TiffData. This value is useful for MetadataOnly files and is to allow for future storage solutions.
Returns:
Type
Description
boolean
The value of the attribute
resetBigEndian ()
Resets the BigEndian attribute to an unset state.
This field is True if the pixels data was written in BigEndian order. If this value is present, it should match the value used in BinData or TiffData. If it is not, a reader should be used that honors the value used in the BinData or TiffData. This value is useful for MetadataOnly files and is to allow for future storage solutions.
hasBigEndian ()
Checks whether the BigEndian attribute is present.
This field is True if the pixels data was written in BigEndian order. If this value is present, it should match the value used in BinData or TiffData. If it is not, a reader should be used that honors the value used in the BinData or TiffData. This value is useful for MetadataOnly files and is to allow for future storage solutions.
Returns:
Type
Description
boolean
true if the attribute has been set, false otherwise
setPlane_List ( value , validate = True )
addToPlane_List ( value , validate = True )
setChannel_List ( value , validate = True )
addToChannel_List ( value , validate = True )
setAdditionalDimensionMap ( value , validate = True )
getAdditionalDimensionMap ()
resetAdditionalDimensionMap ()
hasAdditionalDimensionMap ()
setpixels_choice ( value , validate = True )