GGEMS  1.1
GPU GEant4-based Monte Carlo Simulations
GGEMSDosimetryCalculator Class Reference

Class providing tools storing and computing dose in phantom. More...

#include "GGEMSDosimetryCalculator.hh"

Collaboration diagram for GGEMSDosimetryCalculator:
Collaboration graph

Public Member Functions

 GGEMSDosimetryCalculator (void)
 GGEMSDosimetryCalculator constructor. More...
 
 ~GGEMSDosimetryCalculator (void)
 GGEMSDosimetryCalculator destructor. More...
 
 GGEMSDosimetryCalculator (GGEMSDosimetryCalculator const &dose_calculator)=delete
 Avoid copy by reference. More...
 
GGEMSDosimetryCalculatoroperator= (GGEMSDosimetryCalculator const &dose_calculator)=delete
 Avoid assignement by reference. More...
 
 GGEMSDosimetryCalculator (GGEMSDosimetryCalculator const &&dose_calculator)=delete
 Avoid copy by rvalue reference. More...
 
GGEMSDosimetryCalculatoroperator= (GGEMSDosimetryCalculator const &&dose_calculator)=delete
 Avoid copy by rvalue reference. More...
 
void AttachToNavigator (std::string const &navigator_name)
 attach a navigator to dosimetry module More...
 
void Initialize (void)
 Initialize dosimetry calculator class. More...
 
void SetDoselSizes (GGfloat const &dosel_x, GGfloat const &dosel_y, GGfloat const &dosel_z, std::string const &unit="mm")
 set size of dosels More...
 
void SetOutputDosimetryBasename (std::string const &output_filename)
 set output basename storing dosimetry More...
 
void SetScaleFactor (GGfloat const &scale_factor)
 set the scale factor applied to dose value More...
 
void SetPhotonTracking (bool const &is_activated)
 activating photon tracking during dosimetry mode More...
 
void SetEdep (bool const &is_activated)
 activating energy deposit registration during dosimetry mode More...
 
void SetHitTracking (bool const &is_activated)
 activating hit tracking during dosimetry mode More...
 
void SetEdepSquared (bool const &is_activated)
 activating energy squared deposit registration during dosimetry mode More...
 
void SetUncertainty (bool const &is_activated)
 activating uncertainty registration during dosimetry mode More...
 
void SetWaterReference (bool const &is_activated)
 activating water reference during dose computation More...
 
void SetMinimumDensity (GGfloat const &minimum_density, std::string const &unit="g/cm3")
 set minimum of density for dose computation More...
 
cl::Buffer * GetPhotonTrackingBuffer (GGsize const &thread_index) const
 get the buffer for photon tracking in dosimetry mode More...
 
cl::Buffer * GetHitTrackingBuffer (GGsize const &thread_index) const
 get the buffer for hit tracking in dosimetry mode More...
 
cl::Buffer * GetEdepBuffer (GGsize const &thread_index) const
 get the buffer for edep in dosimetry mode More...
 
cl::Buffer * GetEdepSquaredBuffer (GGsize const &thread_index) const
 get the buffer for edep squared in dosimetry mode More...
 
cl::Buffer * GetDoseParams (GGsize const &thread_index) const
 get the buffer storing dosimetry params More...
 
void ComputeDose (GGsize const &thread_index)
 computing dose More...
 
void SaveResults (void) const
 save results (dose images) More...
 

Private Member Functions

void CheckParameters (void) const
 
void InitializeKernel (void)
 Initialize kernel for dose computation. More...
 
void SavePhotonTracking (void) const
 save photon tracking More...
 
void SaveHit (void) const
 save hits in dose map More...
 
void SaveEdep (void) const
 save energy deposit More...
 
void SaveDose (void) const
 save dose More...
 
void SaveEdepSquared (void) const
 save energy squared deposit More...
 
void SaveUncertainty (void) const
 save uncertainty values More...
 

Private Attributes

GGfloat3 dosel_sizes_
 
GGsize total_number_of_dosels_
 
std::string dosimetry_output_filename_
 
GGEMSNavigatornavigator_
 
cl::Buffer ** dose_params_
 
GGEMSDoseRecording dose_recording_
 
bool is_photon_tracking_
 
bool is_edep_
 
bool is_hit_tracking_
 
bool is_edep_squared_
 
bool is_uncertainty_
 
GGfloat scale_factor_
 
GGchar is_water_reference_
 
GGfloat minimum_density_
 
cl::Kernel ** kernel_compute_dose_
 
GGsize number_activated_devices_
 

Detailed Description

Class providing tools storing and computing dose in phantom.

Definition at line 47 of file GGEMSDosimetryCalculator.hh.

Constructor & Destructor Documentation

◆ GGEMSDosimetryCalculator() [1/3]

GGEMSDosimetryCalculator::GGEMSDosimetryCalculator ( void  )

GGEMSDosimetryCalculator constructor.

Definition at line 40 of file GGEMSDosimetryCalculator.cc.

◆ ~GGEMSDosimetryCalculator()

GGEMSDosimetryCalculator::~GGEMSDosimetryCalculator ( void  )

GGEMSDosimetryCalculator destructor.

Definition at line 93 of file GGEMSDosimetryCalculator.cc.

◆ GGEMSDosimetryCalculator() [2/3]

GGEMSDosimetryCalculator::GGEMSDosimetryCalculator ( GGEMSDosimetryCalculator const &  dose_calculator)
delete

Avoid copy by reference.

Parameters
dose_calculator- reference on the GGEMS dose calculator

◆ GGEMSDosimetryCalculator() [3/3]

GGEMSDosimetryCalculator::GGEMSDosimetryCalculator ( GGEMSDosimetryCalculator const &&  dose_calculator)
delete

Avoid copy by rvalue reference.

Parameters
dose_calculator- rvalue reference on the GGEMS dose calculator

Member Function Documentation

◆ AttachToNavigator()

void GGEMSDosimetryCalculator::AttachToNavigator ( std::string const &  navigator_name)

attach a navigator to dosimetry module

Parameters
navigator_name- name of the navigator to attach

Definition at line 175 of file GGEMSDosimetryCalculator.cc.

◆ CheckParameters()

void GGEMSDosimetryCalculator::CheckParameters ( void  ) const
private
Returns
no returned value

Definition at line 281 of file GGEMSDosimetryCalculator.cc.

◆ ComputeDose()

void GGEMSDosimetryCalculator::ComputeDose ( GGsize const &  thread_index)

computing dose

Parameters
thread_index- index of activated device (thread index)

Definition at line 316 of file GGEMSDosimetryCalculator.cc.

◆ GetDoseParams()

cl::Buffer * GGEMSDosimetryCalculator::GetDoseParams ( GGsize const &  thread_index) const
inline

get the buffer storing dosimetry params

Parameters
thread_index- index of activated device (thread index)
Returns
OpenCL buffer storing dosimetry params

Definition at line 213 of file GGEMSDosimetryCalculator.hh.

◆ GetEdepBuffer()

cl::Buffer * GGEMSDosimetryCalculator::GetEdepBuffer ( GGsize const &  thread_index) const
inline

get the buffer for edep in dosimetry mode

Parameters
thread_index- index of activated device (thread index)
Returns
OpenCL buffer for edep in dosimetry mode

Definition at line 197 of file GGEMSDosimetryCalculator.hh.

◆ GetEdepSquaredBuffer()

cl::Buffer * GGEMSDosimetryCalculator::GetEdepSquaredBuffer ( GGsize const &  thread_index) const
inline

get the buffer for edep squared in dosimetry mode

Parameters
thread_index- index of activated device (thread index)
Returns
OpenCL buffer for edep squared in dosimetry mode

Definition at line 205 of file GGEMSDosimetryCalculator.hh.

◆ GetHitTrackingBuffer()

cl::Buffer * GGEMSDosimetryCalculator::GetHitTrackingBuffer ( GGsize const &  thread_index) const
inline

get the buffer for hit tracking in dosimetry mode

Parameters
thread_index- index of activated device (thread index)
Returns
OpenCL buffer for hit tracking in dosimetry mode

Definition at line 189 of file GGEMSDosimetryCalculator.hh.

◆ GetPhotonTrackingBuffer()

cl::Buffer * GGEMSDosimetryCalculator::GetPhotonTrackingBuffer ( GGsize const &  thread_index) const
inline

get the buffer for photon tracking in dosimetry mode

Parameters
thread_index- index of activated device (thread index)
Returns
OpenCL buffer for photon tracking in dosimetry mode

Definition at line 181 of file GGEMSDosimetryCalculator.hh.

◆ Initialize()

void GGEMSDosimetryCalculator::Initialize ( void  )

Initialize dosimetry calculator class.

Definition at line 374 of file GGEMSDosimetryCalculator.cc.

◆ InitializeKernel()

void GGEMSDosimetryCalculator::InitializeKernel ( void  )
private

Initialize kernel for dose computation.

Definition at line 294 of file GGEMSDosimetryCalculator.cc.

◆ operator=() [1/2]

GGEMSDosimetryCalculator & GGEMSDosimetryCalculator::operator= ( GGEMSDosimetryCalculator const &&  dose_calculator)
delete

Avoid copy by rvalue reference.

Parameters
dose_calculator- rvalue reference on the GGEMS dose calculator

◆ operator=() [2/2]

GGEMSDosimetryCalculator & GGEMSDosimetryCalculator::operator= ( GGEMSDosimetryCalculator const &  dose_calculator)
delete

Avoid assignement by reference.

Parameters
dose_calculator- reference on the GGEMS dose calculator

◆ SaveDose()

void GGEMSDosimetryCalculator::SaveDose ( void  ) const
private

save dose

Definition at line 663 of file GGEMSDosimetryCalculator.cc.

◆ SaveEdep()

void GGEMSDosimetryCalculator::SaveEdep ( void  ) const
private

save energy deposit

Definition at line 573 of file GGEMSDosimetryCalculator.cc.

◆ SaveEdepSquared()

void GGEMSDosimetryCalculator::SaveEdepSquared ( void  ) const
private

save energy squared deposit

Definition at line 618 of file GGEMSDosimetryCalculator.cc.

◆ SaveHit()

void GGEMSDosimetryCalculator::SaveHit ( void  ) const
private

save hits in dose map

Definition at line 529 of file GGEMSDosimetryCalculator.cc.

◆ SavePhotonTracking()

void GGEMSDosimetryCalculator::SavePhotonTracking ( void  ) const
private

save photon tracking

Definition at line 486 of file GGEMSDosimetryCalculator.cc.

◆ SaveResults()

void GGEMSDosimetryCalculator::SaveResults ( void  ) const

save results (dose images)

Definition at line 472 of file GGEMSDosimetryCalculator.cc.

◆ SaveUncertainty()

void GGEMSDosimetryCalculator::SaveUncertainty ( void  ) const
private

save uncertainty values

Definition at line 707 of file GGEMSDosimetryCalculator.cc.

◆ SetDoselSizes()

void GGEMSDosimetryCalculator::SetDoselSizes ( GGfloat const &  dosel_x,
GGfloat const &  dosel_y,
GGfloat const &  dosel_z,
std::string const &  unit = "mm" 
)

set size of dosels

Parameters
dosel_x- size of dosel in X global axis
dosel_y- size of dosel in Y global axis
dosel_z- size of dosel in Z global axis
unit- unit of the distance

Definition at line 188 of file GGEMSDosimetryCalculator.cc.

◆ SetEdep()

void GGEMSDosimetryCalculator::SetEdep ( bool const &  is_activated)

activating energy deposit registration during dosimetry mode

Parameters
is_activated- boolean activating energy deposit registration

Definition at line 226 of file GGEMSDosimetryCalculator.cc.

◆ SetEdepSquared()

void GGEMSDosimetryCalculator::SetEdepSquared ( bool const &  is_activated)

activating energy squared deposit registration during dosimetry mode

Parameters
is_activated- boolean activating energy squared deposit registration

Definition at line 244 of file GGEMSDosimetryCalculator.cc.

◆ SetHitTracking()

void GGEMSDosimetryCalculator::SetHitTracking ( bool const &  is_activated)

activating hit tracking during dosimetry mode

Parameters
is_activated- boolean activating hit tracking

Definition at line 235 of file GGEMSDosimetryCalculator.cc.

◆ SetMinimumDensity()

void GGEMSDosimetryCalculator::SetMinimumDensity ( GGfloat const &  minimum_density,
std::string const &  unit = "g/cm3" 
)

set minimum of density for dose computation

Parameters
minimum_density- minimum of density
unit- unit of the density

Definition at line 272 of file GGEMSDosimetryCalculator.cc.

◆ SetOutputDosimetryBasename()

void GGEMSDosimetryCalculator::SetOutputDosimetryBasename ( std::string const &  output_filename)

set output basename storing dosimetry

Parameters
output_filename- name of output dosimetry basename storing dosimetry results

Definition at line 199 of file GGEMSDosimetryCalculator.cc.

◆ SetPhotonTracking()

void GGEMSDosimetryCalculator::SetPhotonTracking ( bool const &  is_activated)

activating photon tracking during dosimetry mode

Parameters
is_activated- boolean activating photon tracking

Definition at line 217 of file GGEMSDosimetryCalculator.cc.

◆ SetScaleFactor()

void GGEMSDosimetryCalculator::SetScaleFactor ( GGfloat const &  scale_factor)

set the scale factor applied to dose value

Parameters
scale_factor- scale factor applied to dose value

Definition at line 208 of file GGEMSDosimetryCalculator.cc.

◆ SetUncertainty()

void GGEMSDosimetryCalculator::SetUncertainty ( bool const &  is_activated)

activating uncertainty registration during dosimetry mode

Parameters
is_activated- boolean activating uncertainty registration

Definition at line 253 of file GGEMSDosimetryCalculator.cc.

◆ SetWaterReference()

void GGEMSDosimetryCalculator::SetWaterReference ( bool const &  is_activated)

activating water reference during dose computation

Parameters
is_activated- boolean activating water reference

Definition at line 262 of file GGEMSDosimetryCalculator.cc.

Member Data Documentation

◆ dose_params_

cl::Buffer** GGEMSDosimetryCalculator::dose_params_
private

Buffer storing dose parameters in OpenCL device

Definition at line 284 of file GGEMSDosimetryCalculator.hh.

◆ dose_recording_

GGEMSDoseRecording GGEMSDosimetryCalculator::dose_recording_
private

Structure storing dose data on OpenCL device

Definition at line 285 of file GGEMSDosimetryCalculator.hh.

◆ dosel_sizes_

GGfloat3 GGEMSDosimetryCalculator::dosel_sizes_
private

Sizes of dosel

Definition at line 278 of file GGEMSDosimetryCalculator.hh.

◆ dosimetry_output_filename_

std::string GGEMSDosimetryCalculator::dosimetry_output_filename_
private

Output filename for dosimetry results

Definition at line 280 of file GGEMSDosimetryCalculator.hh.

◆ is_edep_

bool GGEMSDosimetryCalculator::is_edep_
private

Boolean for energy deposit

Definition at line 287 of file GGEMSDosimetryCalculator.hh.

◆ is_edep_squared_

bool GGEMSDosimetryCalculator::is_edep_squared_
private

Boolean for energy squared deposit

Definition at line 289 of file GGEMSDosimetryCalculator.hh.

◆ is_hit_tracking_

bool GGEMSDosimetryCalculator::is_hit_tracking_
private

Boolean for hit tracking

Definition at line 288 of file GGEMSDosimetryCalculator.hh.

◆ is_photon_tracking_

bool GGEMSDosimetryCalculator::is_photon_tracking_
private

Boolean for photon tracking

Definition at line 286 of file GGEMSDosimetryCalculator.hh.

◆ is_uncertainty_

bool GGEMSDosimetryCalculator::is_uncertainty_
private

Boolean for uncertainty computation

Definition at line 290 of file GGEMSDosimetryCalculator.hh.

◆ is_water_reference_

GGchar GGEMSDosimetryCalculator::is_water_reference_
private

Water reference for dose computation

Definition at line 292 of file GGEMSDosimetryCalculator.hh.

◆ kernel_compute_dose_

cl::Kernel** GGEMSDosimetryCalculator::kernel_compute_dose_
private

OpenCL kernel computing dose in voxelized solid

Definition at line 295 of file GGEMSDosimetryCalculator.hh.

◆ minimum_density_

GGfloat GGEMSDosimetryCalculator::minimum_density_
private

Minimum density value for dose computation

Definition at line 293 of file GGEMSDosimetryCalculator.hh.

◆ navigator_

GGEMSNavigator* GGEMSDosimetryCalculator::navigator_
private

Navigator pointer associated to dosimetry object

Definition at line 281 of file GGEMSDosimetryCalculator.hh.

◆ number_activated_devices_

GGsize GGEMSDosimetryCalculator::number_activated_devices_
private

Number of activated device

Definition at line 296 of file GGEMSDosimetryCalculator.hh.

◆ scale_factor_

GGfloat GGEMSDosimetryCalculator::scale_factor_
private

Scale factor

Definition at line 291 of file GGEMSDosimetryCalculator.hh.

◆ total_number_of_dosels_

GGsize GGEMSDosimetryCalculator::total_number_of_dosels_
private

Total number of dosels in image

Definition at line 279 of file GGEMSDosimetryCalculator.hh.


The documentation for this class was generated from the following files: