mipcandy.inference#
Module Contents#
Classes#
Functions#
API#
- mipcandy.inference.parse_predictant(x: mipcandy.types.SupportedPredictant, loader: type[mipcandy.data.Loader], *, as_label: bool = False) tuple[list[torch.Tensor], list[str] | None][source]#
- class mipcandy.inference.Predictor(experiment_folder: str | os.PathLike[str], example_shape: mipcandy.types.AmbiguousShape, *, checkpoint: str = 'checkpoint_best.pth', device: mipcandy.types.Device = 'cpu')[source]#
Bases:
mipcandy.layer.WithPaddingModule,mipcandy.layer.WithNetworkInitialization
- _predict(x: mipcandy.types.SupportedPredictant | mipcandy.data.UnsupervisedDataset) tuple[list[torch.Tensor], list[str] | None][source]#
- predict(x: mipcandy.types.SupportedPredictant | mipcandy.data.UnsupervisedDataset) list[torch.Tensor][source]#
- save_predictions(outputs: Sequence[torch.Tensor], folder: str | os.PathLike[str], *, filenames: Sequence[str | os.PathLike[str]] | None = None) None[source]#