models.voxel_grid.VoxelGrid#

class VoxelGrid(shape, suggested_calc=True, verbose=False, debug=False)[source]#

Bases: object

This is a class to handle all of the voxels in KOSMA-tau^3. It contains a specified arrangement of voxels, and must coordinate with the Dimensions class to make the Shape class functional.

Initialise all attributes.

Methods

allVoxels

Just in case all of the Voxel() instances need to be retrieved

calculateEmission

This will initialise the grid of voxels and calculate their emission.

getDimensions

Return dimensions of Shape object.

printVoxels

Print each voxel.

shdu_header

method to setup the header used for a StreamingHDU instance.

voxelproperties

Print the parameters passed to a particular voxel instance depending on x, y, z.

writeEmission

NO LONGER USED: writing of data is coupled to calculating the emission! This will stream the model parameters and emission to FITS files in the corresponding directory for the model.

allVoxels()[source]#

Just in case all of the Voxel() instances need to be retrieved

calculateEmission(index=0, dilled=False, kind='linear', timed=False, verbose=False, debug=False, multiprocessing=0)[source]#

This will initialise the grid of voxels and calculate their emission. This has to be done in succession for each voxel since the calculations are modular (the temporary voxel terms are changed when calculating different voxels). This can be rerun and it will reinitialise the grid.

getDimensions()[source]#

Return dimensions of Shape object.

printVoxels()[source]#

Print each voxel.

shdu_header(name='', units='', molecules=False, hi=False, dust=False, abundance=False, velocity=False, dim=None, kw=25, cw=50, filename=None)[source]#

method to setup the header used for a StreamingHDU instance.

voxelproperties(x, y, z)[source]#

Print the parameters passed to a particular voxel instance depending on x, y, z.

writeEmission(verbose=False, debug=False)[source]#

NO LONGER USED: writing of data is coupled to calculating the emission! This will stream the model parameters and emission to FITS files in the corresponding directory for the model.