Skip to content

Getting started

villekf edited this page Apr 20, 2021 · 14 revisions

Getting Started

Installation

To install OMEGA, extract the contents of the zip-file (if you downloaded the release) and put the OMEGA-folder and all its subfolders to MATLAB/Octave path. Finally run install_mex. When using git clone, the process is the same. Installation on Octave is identical to that of MATLAB.

Whether installed as a package or as a collection of individual files, the install_mex function needs to be run first. This will automatically attempt to build all required mex-files. Some of them might fail to build (e.g. ROOT will always fail on Windows). You can view the build logs with install_mex(1). If OpenCL headers/ROOT/ArrayFire are in non-standard locations and not on path, you can specify their paths with install_mex(0, OpenCL_include_path, OpenCL_lib_path, AF_PATH, ROOT_PATH). OpenCL_include_path should be the folder where cl.h is located, OpenCL_lib_path the folder where OpenCL.lib/libOpenCL.so (Windows/Linux) is located, AF_PATH the path to ArrayFire installation location and ROOT_PATH to ROOT installation location.

Examples

PET data

GATE users should use the gate_main.m file to reconstruct GATE PET data. For other PET data, the file you should start with is main_PET.m. For computing the forward and/or backward projections use forward_backward_projections_example.m. For custom (gradient-based) priors, use custom_prior_test_main.m. A more simplified main-file for GATE data (simple OSEM reconstruction) is available in gate_main_simple.m. Inveon users should use Inveon_PET_main.m while Biograph mCT data can be used with Biograph_mCT_main.m and Biograph Vision with Biograph_Vision_main.m.

A GATE example with GATE macros is available in exampleGATE-folder. Simply run the GATE macros as a GATE simulation (GATE material database needs to be in the same folder) and then run the gate_main_example-file to reconstruct the data. By default, ASCII data is used in the reconstruction. This example is based on both benchPET and the cylindrical PET example found from https://opengate.readthedocs.io/en/latest/defining_a_system_scanner_ct_pet_spect_optical.html#cylindricalpet

exampleGATE also contains macros for normalization.

When using GATE data, all the output files of the specified format will be read in the specified folder. E.g. if you select ASCII data, all .dat-files with Coincidences in the file name will be loaded from the specified folder, with LMF all .ccs files and with ROOT all .root files.

Example MAT-files for non-GATE situation (created from GATE data) can be found from: DOI. These files are based on the above GATE-example. Raw data obtained from the GATE macros mentioned above (not normalization) can be found from: DOI

Example Inveon data is available from: DOI. The Inveon_PET_main.m file can be used automatically for this data.

CT data

Several different example scripts for CT data are provided, for different kind of CT-scanners. These include preclinical CT and µCT scanners as well as GATE simulated (imageCT) data. When using CT data, the direction of rotation should be from top to bottom or from bottom to top. If you have data that is rotated from left to right/right to left, you should transpose (permute) it and adjust the xSize and ySize variables according to the final transposed dimensions. Currently also only cone/fan beam CT scanners with flat panel detectors are inherently supported. You can use also other type of scanners, but then you have to input the detector/source coordinates yourself (see e.g. Custom detector coordinates and/or list mode reconstruction).

For GATE data, use gate_CT_main.m. An example of µCT (using either DOI or DOI) is provided with the walnut_CT_main.m. A 2D (sinogram) example is shown in walnut2D_CT_main.m (uses DOI). Lastly, an example script using preclinical Inveon CT is in Inveon_CT_main.m (uses DOI). In all cases, the examples include both how to do built-in reconstruction or how to use the forward/backward projection class for your own custom algorithms.

Help

For a short PET tutorial in image reconstruction in OMEGA see Tutorial. For CT imaging, see.

For help on using the individual main-files or the various functions see Function help

If you want to extract GATE PET scatter, randoms and/or trues data to MATLAB see Extracting GATE scatter, randoms and trues data

For recommendations and things to watch out, see Useful information

Contact

Currently it is recommended to ask questions in GitHub discussions.

However, if you prefer using e-mail for contact, use the following address:

Contact