image_classifier_3d package¶
Subpackages¶
Submodules¶
image_classifier_3d.proj_tester module¶
-
class
image_classifier_3d.proj_tester.
ProjectTester
(mode: str = 'inference', save_model_output: bool = False)[source]¶ Bases:
object
Main class for applying a new classifier on evaluation data or new data
initialization
- mode: str
running mode, either “inference” (no ground truth) or “evaluation” (ground truth is available)
- save_model_output: bool
whether to save the raw prediction from model(s)
-
run_tester_config
(config_filename: Union[str, pathlib.Path], output_path: Union[str, pathlib.Path], return_df: bool = False)[source]¶ do testing using a config yaml file
- config_filename: Union[str, Path]
the configuration file to use
- output_path: Union[str, Path]
where to save the prediction outputs (as a CSV file)
- return_df: bool
whether a dataframe will be returned besides saving to CSV, default is False
-
run_tester_csv
(csv_filename: Union[str, pathlib.Path], output_path: Union[str, pathlib.Path], return_df: bool = False, project_name: str = 'mitotic_classifier', config_yaml: Union[str, pathlib.Path] = 'default') → Optional[pandas.core.frame.DataFrame][source]¶ do testing using data from a csv file
- csv_filename: Union[str, Path]
the filepath to the csv file
- output_path: Union[str, Path]
where to save the prediction outputs (as a CSV file)
- return_df: bool
whether a dataframe will be returned besides saving to CSV, default is False
- project_name: str
which project (i.e., which kind of classifier) to use
- config_yaml: Union[str, Path]
the configuration file to use, if it is “default”, the a yaml at ../model_zoo/test_config_{project_name}.yaml is used by default