MCPcopy Create free account
hub / github.com/Project-MONAI/MONAI / _get_meta_dict

Method _get_meta_dict

monai/data/image_reader.py:1430–1437  ·  view source on GitHub ↗

Get the all the metadata of the image and convert to dict type. Args: img: a PIL Image object loaded from an image file.

(self, img)

Source from the content-addressed store, hash-verified

1428 return _stack_images(img_array, compatible_meta), compatible_meta
1429
1430 def _get_meta_dict(self, img) -> dict:
1431 """
1432 Get the all the metadata of the image and convert to dict type.
1433 Args:
1434 img: a PIL Image object loaded from an image file.
1435
1436 """
1437 return {"format": img.format, "mode": img.mode, "width": img.width, "height": img.height}
1438
1439 def _get_spatial_shape(self, img):
1440 """

Callers 1

get_dataMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected