MCPcopy Index your code
hub / github.com/Project-MONAI/MONAI / __format__

Method __format__

monai/data/meta_tensor.py:599–603  ·  view source on GitHub ↗

returns the output of pytorch tensor's ``__format__`` method.

(self, format_spec)

Source from the content-addressed store, hash-verified

597 return f"meta{str(self.as_tensor())}"
598
599 def __format__(self, format_spec):
600 """
601 returns the output of pytorch tensor's ``__format__`` method.
602 """
603 return self.as_tensor().__format__(format_spec)
604
605 def print_verbose(self) -> None:
606 """Verbose print with meta data."""

Callers

nothing calls this directly

Calls 1

as_tensorMethod · 0.95

Tested by

no test coverage detected