MATLAB compatibility interface: the matlab module

This module implements a MATLAB-like interface to the ASTRA Toolbox.

Note that all functions are called with a string as the first argument, specifying the operation to perform. This un-pythonic way is used to make transitioning from MATLAB code to Python code easier, as the MATLAB interface uses the same type of method calling.

After an initial import astra, these functions can be accessed in the astra.m module.

astra.matlab.algorithm(command, *args)[source]

MATLAB-like interface to the astra.algorithm module

For example:

astra.m.algorithm('run',i,1000) – Run an algorithm with 1000 iterations.

astra.matlab.astra(command, *args)[source]

MATLAB-like interface to the astra.astra module

For example:

astra.m.astra('use_cuda') – Check if CUDA is enabled.

astra.matlab.data2d(command, *args)[source]

MATLAB-like interface to the astra.data2d module

For example:

astra.m.data2d('create',type,geometry,data) – Create a 2D object.

astra.matlab.data3d(command, *args)[source]

MATLAB-like interface to the astra.data3d module

For example:

astra.m.data3d('get',i) – Get 3D object data.

astra.matlab.matrix(command, *args)[source]

MATLAB-like interface to the astra.matrix module

For example:

astra.m.matrix('delete',i) – Delete a matrix.

astra.matlab.projector(command, *args)[source]

MATLAB-like interface to the astra.projector module

For example:

astra.m.projector('volume_geometry',i) – Get volume geometry.

Previous topic

Helper class: the ASTRAProjector module

Next topic

Additional ASTRA methods: the astra module

This Page