Package: elektronn3
elektronn3A PyTorch-based library for working with 3D and 2D convolutional neural networks, with focus on semantic segmentation of volumetric biomedical image data.Quick overview ofelektronn3's code structure:elektronn3.training: Utilities for training, monitoring, visualization and model evaluation. Provides a flexibleTrainerclass that can be used for arbitrary PyTorch models and Data sets.elektronn3.data: Data loading and augmentation code for semantic segmentation and other dense prediction tasks. The main focus is on 3D (volumetric) biomedical image data stored as HDF5 files, but most of the code also supports 2D and n-dimensional data.elektronn3.inference: Code for deployment of trained models and for efficient tiled inference on large input volumes.elektronn3.models: Neural network architectures for segmentation and other pixel-wise prediction tasks.models.unet.UNetprovides a highly flexible PyTorch model class inspired by3D U-Netthat works in 2D and 3D and supports custom depths, data anisotropy handling, batch normalization and many more configurable features.elektronn3.modules: Modules (in the sense oftorch.nn.Module) for building neural networks and loss functions.examples: Scripts that demonstrate how the library can be used for biomedical image segmentation.elektronn3's modular codebase makes it easy to extend/replace parts of it with your own code: For example, you can use the training tools included inelektronn3.trainingwith your own data sets, augmentation methods, network models etc. or use the data loading and augmentation code ofelektronn3.datawith your own training code. The neural network architectures inelektronn3.modelscan also be freely used with custom training and/or data loading code.Documentation can be found atelektronn3.readthedocs.io.For a roadmap of planned features, see the"enhancement" issues on the tracker.RequirementsLinux (support for Windows, MacOS and other systems is not planned)Python 3.6 or laterPyTorch 1.6 or later (earlier versions may work, but are untested)For other requirements seerequirements.txtSetupEnsure that all of the requirements listed above are installed.
We recommend using conda or a virtualenv for that.
To installelektronn3in development mode, rungit clone https://github.com/ELEKTRONN/elektronn3 elektronn3-dev
pip install -e elektronn3-devTo update your installation, justgit pullin your clone
directory.If you are not familiar with virtualenv and conda or are not sure about some of
the required steps, you can find a more detailed setup guidehereTrainingFor a quick test run, first ensure that the neuro_data_cdhw data set is
in the expected path:wget https://github.com/ELEKTRONN/elektronn.github.io/releases/download/neuro_data_cdhw/neuro_data_cdhw.zip
unzip neuro_data_cdhw.zip -d ~/neuro_data_cdhwTo test training with our custom U-Net-inspired architecture inelektronn3,
you can run:python3 train_unet_neurodata.pyUsing TensorboardTensorboard logs are saved in~/e3training/by default, so you can track training
progress by running a tensorboard server there:tensorboard --logdir ~/e3training/Then you can view the visualizations athttp://localhost:6006.ContributorsTheelektronn3project is being developed by theELEKTRONN team.Jörgen Kornfeldis academic advisor to this project.