class documentation

class ImageMetadata(Metadata): (source)

View In Hierarchy

Class for storing metadata about image samples.

Parameters
size_bytesthe size of the image on disk, in bytes
mime_typethe MIME type of the image
widththe width of the image, in pixels
heightthe height of the image, in pixels
num_channelsthe number of channels in the image
Class Method build_for Builds an ImageMetadata object for the given image.
Class Variable height Undocumented
Class Variable num_channels Undocumented
Class Variable width Undocumented
Class Method _build_for_img Undocumented
Class Method _build_for_local Undocumented
Class Method _build_for_url Undocumented
@classmethod
def build_for(cls, img_or_path_or_url, mime_type=None): (source)

Builds an ImageMetadata object for the given image.

Parameters
img_or_path_or_urlan image, an image path on disk, or a URL
mime_type:Nonethe MIME type of the image. If not provided, it will be guessed
Returns
an ImageMetadata

Undocumented

num_channels: None = (source)

Undocumented

Undocumented

@classmethod
def _build_for_img(cls, img, mime_type=None): (source)

Undocumented

@classmethod
def _build_for_local(cls, path, mime_type=None): (source)
@classmethod
def _build_for_url(cls, url, mime_type=None): (source)