Monte Carlo eXtreme (MCX)
|
#include <mcx_utils.h>
Data structure for MCX simulation settings
char MCXConfig::autopilot |
1 optimal setting for dedicated card, 2, for non dedicated card
char MCXConfig::bc[12] |
boundary condition flag for [-x,-y,-z,+x,+y,+z, det(-x,-y,-z,+x,+y,+z)]
uint3 MCXConfig::crop0 |
sub-volume for cache
uint3 MCXConfig::crop1 |
the other end of the caching box
unsigned int MCXConfig::debugdatalen |
max number of photon trajectory position length
unsigned int MCXConfig::debuglevel |
a flag to control the printing of the debug information
unsigned long int MCXConfig::detectedcount |
total number of detected photons
unsigned int MCXConfig::detnum |
total detector numbers
float4* MCXConfig::detpos |
detector positions and radius, overwrite detradius
float MCXConfig::detradius |
default detector radius
char MCXConfig::deviceid[MAX_DEVICE] |
a 0-1 mask for all the GPUs, a mask of 1 means this GPU will be used
uint3 MCXConfig::dim |
domain size
float* MCXConfig::dx |
anisotropic voxel spacing for x-axis
float* MCXConfig::dy |
anisotropic voxel spacing for y-axis
float* MCXConfig::dz |
anisotropic voxel spacing for z-axis
double MCXConfig::energyabs |
total absorbed photon packet weights
double MCXConfig::energyesc |
total escaped photon packet weights
double MCXConfig::energytot |
total launched photon packet weights
float* MCXConfig::exportdebugdata |
pointer to the buffer where the photon trajectory data are stored
float* MCXConfig::exportdetected |
memory buffer when returning the partial length info to external programs such as matlab
float* MCXConfig::exportfield |
memory buffer when returning the flux to external programs such as matlab
char* MCXConfig::extrajson |
a pointer points to a string defining the extra JSON input data
char MCXConfig::faststep |
1 use tMCimg-like approximated photon stepping (obsolete)
FILE* MCXConfig::flog |
stream handle to print log information
int MCXConfig::gpuid |
the ID of the GPU to use, starting from 1, 0 for auto
unsigned int MCXConfig::gscatter |
after how many scattering events that we can use mus' instead of mus
History MCXConfig::his |
header info of the history file
char MCXConfig::internalsrc |
1 all photons launch positions are inside non-zero voxels, 0 let mcx search entry point
float* MCXConfig::invcdf |
equal-space sampled inversion of CDF(cos(theta)) for the phase function of the zenith angle
char MCXConfig::isdumpjson |
1 to save json
char MCXConfig::isdumpmask |
1 dump detector mask; 0 not
char MCXConfig::isgpuinfo |
1 to print gpu info when attach, 0 do not print
char MCXConfig::ismomentum |
1 to save momentum transfer for detected photons, implies issavedet=1
char MCXConfig::isnormalized |
1 to normalize the fluence, 0 for raw fluence
char MCXConfig::isref3 |
1 considering maximum 3 ref. interfaces; 0 max 2 ref
char MCXConfig::isrefint |
1 to consider reflections at internal boundaries; 0 do not
char MCXConfig::isreflect |
1 for reflecting photons at boundary,0 for exiting
char MCXConfig::isrowmajor |
1 for C-styled array in vol, 0 for matlab-styled array
char MCXConfig::issave2pt |
1 to save the 2-point distribution, 0 do not save
char MCXConfig::issavedet |
1 to count all photons hits the detectors
char MCXConfig::issaveexit |
1 save the exit position and dir of a detected photon, 0 do not save
char MCXConfig::issaveref |
1 save diffuse reflectance at the boundary voxels, 0 do not save
char MCXConfig::issaveseed |
1 save the seed for a detected photon, 0 do not save
char MCXConfig::isspecular |
1 calculate the initial specular ref if outside the mesh, 0 do not calculate
char MCXConfig::issrcfrom0 |
1 do not subtract 1 from src/det positions, 0 subtract 1
char MCXConfig::jsonfile[MAX_PATH_LENGTH] |
if the seed is specified as a file (mch), mcx will replay the photons
float MCXConfig::lambda |
light wavelength (in nm), for polarized light simulation
unsigned int MCXConfig::maxdetphoton |
anticipated maximum detected photons
unsigned int MCXConfig::maxgate |
simultaneous recording gates
unsigned int MCXConfig::maxjumpdebug |
num of photon scattering events to save when saving photon trajectory is enabled
int MCXConfig::maxvoidstep |
max number of steps that a photon can advance before reaching a non-zero voxel
uint MCXConfig::mediabyte |
how many bytes per media index, mcx supports 1, 2 and 4, 4 is the default
unsigned int MCXConfig::medianum |
total types of media
float MCXConfig::minenergy |
minimum energy to propagate photon
unsigned int MCXConfig::nblocksize |
thread block size
float MCXConfig::normalizer |
normalization factor
unsigned int MCXConfig::nphase |
number of samples for inverse-cdf, will be added by 2 to include -1 and 1 on the two ends
size_t MCXConfig::nphoton |
total simulated photon number
unsigned int MCXConfig::nthread |
num of total threads, multiple of 128
float MCXConfig::omega |
modulation angular frequency (2*pi*f), in rad/s, for FD/RF replay
char MCXConfig::outputformat |
'mc2' output is text, 'nii': binary, 'img': regular json, 'ubj': universal binary json
char MCXConfig::outputtype |
'X' output is flux, 'F' output is fluence, 'E' energy deposit
int MCXConfig::parentid |
flag for testing if mcx is executed inside matlab
unsigned int MCXConfig::polmedianum |
total types of media for polarized photon simulation
POLMedium* MCXConfig::polprop |
absorption and scatterer mapping table for polarized photon simulation
unsigned int MCXConfig::printnum |
number of printed threads (for debugging)
Medium* MCXConfig::prop |
optical property mapping table
Replay MCXConfig::replay |
a structure to prepare for photon replay
int MCXConfig::replaydet |
the detector id for which to replay the detected photons, start from 1
int MCXConfig::respin |
number of repeatitions (if positive), or number of divisions (if negative)
char MCXConfig::rootpath[MAX_PATH_LENGTH] |
sets the input and output root folder
unsigned int MCXConfig::runtime |
variable to store the total kernel simulation time in ms
unsigned int MCXConfig::savedetflag |
a flag to control the output fields of detected photon data
int MCXConfig::seed |
random number generator seed
void* MCXConfig::seeddata |
poiinter to a buffer where detected photon seeds are stored
char MCXConfig::seedfile[MAX_PATH_LENGTH] |
if the seed is specified as a file (mch), mcx will replay the photons
char MCXConfig::session[MAX_SESSION_LENGTH] |
session id, a string
char* MCXConfig::shapedata |
a pointer points to a string defining the JSON-formatted shape data
float4* MCXConfig::smatrix |
scattering Mueller matrix
float MCXConfig::sradius |
source region radius, if set to non-zero, accumulation will not perform for dist<sradius
float4 MCXConfig::srcdir |
src normal direction
float4 MCXConfig::srciquv |
initial stokes parameter
unsigned int MCXConfig::srcnum |
total number of pattern sources
float4 MCXConfig::srcparam1 |
a quadruplet {x,y,z,w} for additional source parameters
float4 MCXConfig::srcparam2 |
a quadruplet {x,y,z,w} for additional source parameters
float* MCXConfig::srcpattern |
a string for the source form, options include "pencil","isotropic", etc
float4 MCXConfig::srcpos |
src position in mm
char MCXConfig::srctype |
0:pencil,1:isotropic,2:cone,3:gaussian,4:planar,5:pattern,\ 6:fourier,7:arcsine,8:disk,9:fourierx,10:fourierx2d,11:zgaussian,\ 12:line,13:slit,14:pencilarray,15:pattern3d,16:hyperboloid,17:ring
float3 MCXConfig::steps |
voxel sizes along x/y/z in mm
float MCXConfig::tend |
end time in second
float MCXConfig::tstart |
start time in second
float MCXConfig::tstep |
time step in second
float MCXConfig::unitinmm |
defines the length unit in mm for grid
int MCXConfig::voidtime |
1 start counting photon time when moves inside 0 voxels; 0: count time only after enters non-zero voxel
unsigned int* MCXConfig::vol |
pointer to the volume
float MCXConfig::workload[MAX_DEVICE] |
an array storing the relative weight when distributing photons between multiple GPUs
int MCXConfig::zipid |
data zip method "zlib","gzip","base64","lzip","lzma","lz4","lz4hc"