Engine.dataset

Engine.dataset(model, split, *, augmented=False, only_images=None)

only_images defaults to what the split actually has rather than to False.

It used to default to False, so asking for a test split of images alone built a dataset that would read masks and fail on the first item. The engine knew: it had just discovered the split without them.

Parameters

Name Type Description Default
model SegmentationModel Which model’s settings to read. required
split str Which data. required
augmented bool Apply the model’s augmentation. Training only. False
only_images bool | None Read images alone. Defaults to what the split actually has. None

Returns

Name Type Description
SegmentationDataset A SegmentationDataset. inspect_masks() on it is what fit calls to refuse
SegmentationDataset a colormap matching none of the labelled tissue.