mednet.data.segment.typing

Define specialized data typing for semantic segmentation tasks.

Classes

SegmentationData

Type for segmentation data.

SegmentationRawDataLoader()

Loader object that handles samples and labels from storage.

class mednet.data.segment.typing.SegmentationData[source]

Bases: TypedDict

Type for segmentation data.

image: Tensor
target: Tensor
mask: Tensor
class mednet.data.segment.typing.SegmentationRawDataLoader[source]

Bases: RawDataLoader

Loader object that handles samples and labels from storage.

sample(sample)[source]

Load whole samples from media.

Parameters:

sample (tuple[str, str, str | None]) – Information about the sample to load. Implementation dependent.

Return type:

tuple[SegmentationData, Mapping[str, Any]]