crimac/unet
CRIMAC WP4 UNet Classifier
516
This repository contains scripts for:
The code on this repository was tested using Python 3.8 and the requirements which are listed in the requirements.txt document.
Create the file setpyenv.json
in the local root directory:
### setpyenv.json ###
### Replace each "/dir_path/" with appropriate directory path.
{
"path_to_echograms": "/dir_path/"
"path_to_zarr_files": "/dir_path/"
"path_to_trained_model": "/dir_path/"
"path_for_saving_preds_labels": "/dir_path/"
"path_for_saving_figs": "/dir_path/"
"path_to_korona_data": "/dir_path/"
"path_to_korona_transducer_depths": "/dir_path/"
}
"path_to_echograms"
: Directory path to echogram folders stored in memmap format (optional if working with zarr files is wished)"path_to_zarr_files"
: Directory path to echogram folders stored in zarr format (optional if working with memmap files is wished)"path_to_trained_model"
: Directory path to the trained model"path_for_saving_preds_labels"
: [Optional] Directory path for saving predictions and labels after training"path_for_saving_figs"
: [Optional] Directory path for saving figures related to the evaluation of the model"path_to_korona_data"
: [Optional] Directory path to Korona predictions (only used when working with memmap files)"path_to_korona_transducer_depths"
: [Optional] Directory path to Korona transducer depths (only used when working with memmap files)Set the following configuration options in the pipeline_config.yaml file:
Run the following program: /pipeline_train_predict/save_predict.py
The program will then make predictions with the trained model and save the predictions (and labels) to disk (possibility to use path_for_saving_preds_labels indicated in setpyenv.json
)
/pipeline_train_predict/predict.py
Set the following configuration options in the pipeline_config.yaml file:
Run the following program: /pipeline_train_predict/evaluate.py
The program will then compute and plot evaluation metrics for assessing the quality of the predictions obtained with a trained model.
The results will be saved to disk (possibility to use path_for_saving_figs indicated in setpyenv.json
).
/pipeline_train_predict/train.py
setpyenv.json
).NB: The training procedure is not yet adjusted to the pre-processed 'zarr' data since the format of the labels may continue changing and sampling the data for training depends on this.
docker pull crimac/unet