vak.predict.parametric_umap.predict_with_parametric_umap_model¶
- vak.predict.parametric_umap.predict_with_parametric_umap_model(model_config: dict, dataset_config: dict, trainer_config: dict, checkpoint_path, num_workers=2, transform_params: dict | None = None, output_dir=None)[source]¶
Make predictions on a dataset with a trained
vak.models.ParametricUMAPModel
.- model_configdict
Model configuration in a
dict
. Can be obtained by callingvak.config.ModelConfig.asdict()
.- dataset_config: dict
Dataset configuration in a
dict
. Can be obtained by callingvak.config.DatasetConfig.asdict()
.- trainer_config: dict
Configuration for
lightning.pytorch.Trainer
. Can be obtained by callingvak.config.TrainerConfig.asdict()
.- checkpoint_pathstr
path to directory with checkpoint files saved by Torch, to reload model
- num_workersint
Number of processes to use for parallel loading of data. Argument to torch.DataLoader. Default is 2.
- timebins_keystr
key for accessing vector of time bins in files. Default is ‘t’.
- annot_csv_filenamestr
name of .csv file containing predicted annotations. Default is None, in which case the name of the dataset .csv is used, with ‘.annot.csv’ appended to it.
- output_dirstr, Path
path to location where .csv containing predicted annotation should be saved. Defaults to current working directory.