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

Method __call__

monai/data/grid_dataset.py:85–99  ·  view source on GitHub ↗

Args: array: the image to generate patches from.

(self, array: NdarrayTensor)

Source from the content-addressed store, hash-verified

83 self.pad_opts = pad_opts
84
85 def __call__(self, array: NdarrayTensor) -> Generator[tuple[NdarrayTensor, np.ndarray], None, None]:
86 """
87 Args:
88 array: the image to generate patches from.
89
90 """
91 yield from iter_patch(
92 array,
93 patch_size=self.patch_size, # type: ignore
94 start_pos=self.start_pos,
95 overlap=0.0,
96 copy_back=False,
97 mode=self.mode,
98 **self.pad_opts,
99 )
100
101
102class PatchIterd:

Callers

nothing calls this directly

Calls 1

iter_patchFunction · 0.90

Tested by

no test coverage detected