This is a deep learning toolbox to train models on medical images (or more generally, 3D images). It integrates seamlessly with cloud computing in Azure.
On the modelling side, this toolbox supports
- Segmentation models
- Classification and regression models
- Sequence models
Classification, regression, and sequence models can be built with only images as inputs, or a combination of images and non-imaging data as input. This supports typical use cases on medical data where measurements, biomarkers, or patient characteristics are often available in addition to images.
On the user side, this toolbox focusses on enabling machine learning teams to achieve more. It is cloud-first, and relies on Azure Machine Learning Services (AzureML) for execution, bookkeeping, and visualization. Taken together, this gives:
- Traceability: AzureML keeps a full record of all experiments that were executed, including a snapshot of the code. Tags are added to the experiments automatically, that can later help filter and find old experiments.
- Transparency: All team members have access to each other's experiments and results.
- Reproducibility: Two model training runs using the same code and data will result in exactly the same metrics. All sources of randomness like multithreading are controlled for.
- Cost reduction: Using AzureML, all compute (virtual machines, VMs) is requested at the time of starting the training job, and freed up at the end. Idle VMs will not incur costs. In addition, Azure low priority nodes can be used to further reduce costs (up to 80% cheaper).
- Scale out: Large numbers of VMs can be requested easily to cope with a burst in jobs.
Despite the cloud focus, all training and model testing works just as well on local compute, which is important for model prototyping, debugging, and in cases where the cloud can't be used.
In addition, our toolbox supports:
- Cross-validation using AzureML's built-in support, where the models for individual folds are trained in parallel. This is particularly important for the long-running training jobs often seen with medical images.
- Hyperparameter tuning using Hyperdrive.
- Building ensemble models.
- Easy creation of new models via a configuration-based approach, and inheritance from an existing architecture.
Once training in AzureML is done, the models can be deployed from within AzureML or via Azure Stack Hub.
Clone the repository via
git lfs install
git clone https://github.com/microsoft/InnerEye-DeepLearning
After that, you need to set up your Python environment:
- Install
conda
orminiconda
for your operating system - Create a Conda environment from the
environment.yml
file in the repository, by runningconda env create --file environment.yml
- Activate the environment by running
conda activate InnerEye
Now try to run the Hello World segmentation model, by running
python InnerEye/ML/runner.py --model=HelloWorld
If that works: Congratulations! You have successfully built your first model using the InnerEye toolbox
Detailed instructions, including setup in Azure, are here:
- Setting up your environment
- Training a Hello World segmentation model
- Setting up Azure Machine Learning
- Creating a dataset
- Building models in Azure ML
- Sample Segmentation and Classification tasks
- Debugging and monitoring models
You are responsible for the performance and any necessary testing or regulatory clearances for any models generated
Please send an email to [email protected] if you would like further information on this project.
If you have any requests or issues with the InnerEye-DeepLearning, please submit an Issue via GitHub.
If you are interested in using the InnerEye Deep Learning Toolkit to develop your own products and services, including using Azure Stack Hub, please email [email protected]
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.