Developer Guide

Getting Started

You will need conda/mamba, CUDA and gcc installed, see the Installation instructions.

First download the Mantid Imaging source code using Git.

git clone https://github.com/mantidproject/mantidimaging.git

If you have a github account you can use ssh access:

git clone git@github.com:mantidproject/mantidimaging.git

To set up a developer environment, from with in the cloned directory run:

python3 ./setup.py create_dev_env

This will create a conda environment containing all the packages needed to run and develop Mantid Imaging. The activate command will activate the environment.

Afterwards the environment can be activated by running:

conda activate mantidimaging-dev

To check that the set up was successful, try running the tests from the source directory:

python3 -m pytest

Mantid Imaging can be run directly from the checked-out git directory:

python3 -m mantidimaging

or to run with additional diagnostics:

python3 -X faulthandler -m mantidimaging --log-level DEBUG

Command Line Arguments

  • --log-level - Set the log verbosity level. Available options are: TRACE, DEBUG, INFO, WARN, CRITICAL

  • --version - Print the version number and exit.

  • --path - Set the path for the data you wish to load.

The following command line arguments will only work if a valid path containing images has been given:

  • --operation - Opens the operation window on start up with the given operation selected in the combo box. The operation name should the same was what appears in Mantid Imaging but joined with hyphens in place of spaces. Case insensitive.

  • --recon - Shows the recon window on start up.