Pretrained VGG16 adapted to classify SEM images of coralline algae
This repository contains all the necessary files to fine tune a pretrained VGG16 CNN starting from custom images and to predict SEM images of calcareous red algae using saved models. For more information regarding the method, have a look at: REF
These instructions will get you a copy of the project up and running on your local machine.
The following prerequisites are needed:
Install conda from the official website. Once conda is installed, it can be used to generate the environment saved in the environment.yml file.
The environment can be created with conda as follows (after saving the environment.yml file in the working directory):
conda env create -f environment.yml
Activate jupyter notebook inside the environment as follows:
conda activate kerasclonenv
jupyter notebook
Now go to the notebooks directory.
There are two notebooks allowing to reproduce the work in REF.
- "CNN_SEM_VGG16_MODEL" contains the code used for the training and prediction in the Internal validatione and External test setups.
- "EXPLANATION" allows to load the saved models, predict custom images and return the explanation in terms of LIME, GradCAM and saliency.
Example images are present in the "images" folder.
Piazza, G.; Valsecchi, C.; Sottocornola, G. Deep Learning Applied to SEM Images for Supporting Marine Coralline Algae Classification. Diversity 2021, 13, 640. https://doi.org/10.3390/d13120640
