Medical Imaging Interaction Toolkit
2018.4.99-389bf124
Medical Imaging Interaction Toolkit
|
#include <math.h>
#include <stdio.h>
#include <string.h>
#include <sstream>
#include <stdlib.h>
#include <time.h>
#include <thread>
#include <chrono>
#include <vector>
#include <iostream>
#include "mitkCommandLineParser.h"
#include "mitkIOUtil.h"
#include "mitkImageCast.h"
#include <mitkImage.h>
#include <mitkImageReadAccessor.h>
#include <mitkCoreServices.h>
#include <mitkPropertyPersistence.h>
#include <mitkPropertyPersistenceInfo.h>
#include <mitkPAProbe.h>
#include <mitkPALightSource.h>
#include <mitkPAMonteCarloThreadHandler.h>
#include <sys/types.h>
#include <sys/stat.h>
Go to the source code of this file.
Macros | |
#define | ls |
#define | PI |
#define | ALIVE |
#define | DEAD |
#define | THRESHOLD |
#define | CHANCE |
#define | SQR(x) |
#define | SIGN(x) |
#define | ONE_MINUS_COSZERO |
#define | MBIG |
#define | MSEED |
#define | MZ |
#define | FAC |
Functions | |
struct Location | initLocation (int x, int y, int z, double absorb) |
bool | verbose (false) |
void | runMonteCarlo (InputValues *inputValues, ReturnValues *returnValue, int thread, mitk::pa::MonteCarloThreadHandler::Pointer threadHandler) |
int | main (int argc, char *argv[]) |
Variables | |
int | detector_x |
int | detector_z |
bool | interpretAsTime |
bool | simulatePVFC |
int | requestedNumberOfPhotons |
float | requestedSimulationTime |
int | concurentThreadsSupported |
float | yOffset |
bool | saveLegacy |
std::string | normalizationFilename |
std::string | inputFilename |
std::string | outputFilename |
mitk::pa::Probe::Pointer | m_PhotoacousticProbe |
#define ALIVE |
Definition at line 59 of file MitkMCxyz.cpp.
Referenced by runMonteCarlo().
#define CHANCE |
Definition at line 62 of file MitkMCxyz.cpp.
Referenced by runMonteCarlo().
#define DEAD |
Definition at line 60 of file MitkMCxyz.cpp.
Referenced by runMonteCarlo().
#define FAC |
Definition at line 288 of file MitkMCxyz.cpp.
#define ls |
Definition at line 57 of file MitkMCxyz.cpp.
Referenced by mitk::LabelSetImage::AddLayer(), mitk::PlaneGeometryDataMapper2D::ApplyAllProperties(), mitk::SurfaceVtkMapper3D::ApplyAllProperties(), mitk::WeightedPointTransform::CalculateConfigChange(), mitk::SurfaceVtkMapper3D::CheckForClippingProperty(), mitk::TubeGraphVtkMapper3D::ClipPolyData(), mitk::LabelSetImage::Concatenate(), mitk::PlaneGeometryDataMapper2D::CreateVtkCrosshair(), mitk::PointSetVtkMapper2D::CreateVTKRenderObjects(), mitk::GPUVolumeMapper3D::DeinitCPU(), mitk::GPUVolumeMapper3D::DeinitRAY(), mitk::GPUVolumeMapper3D::GenerateDataCPU(), mitk::VtkGLMapperWrapper::GenerateDataForRenderer(), mitk::TubeGraphVtkMapper3D::GenerateDataForRenderer(), mitk::UnstructuredGridVtkMapper3D::GenerateDataForRenderer(), mitk::UnstructuredGridMapper2D::GenerateDataForRenderer(), mitk::SplineVtkMapper3D::GenerateDataForRenderer(), mitk::MeshVtkMapper3D::GenerateDataForRenderer(), mitk::EnhancedPointSetVtkMapper3D::GenerateDataForRenderer(), mitk::GPUVolumeMapper3D::GenerateDataForRenderer(), mitk::PlaneGeometryDataMapper2D::GenerateDataForRenderer(), mitk::SurfaceVtkMapper3D::GenerateDataForRenderer(), mitk::PointSetVtkMapper3D::GenerateDataForRenderer(), mitk::PointSetVtkMapper2D::GenerateDataForRenderer(), mitk::GPUVolumeMapper3D::GenerateDataRAY(), mitk::TubeGraphVtkMapper3D::GeneratePolyDataForFurcation(), mitk::TubeGraphVtkMapper3D::GeneratePolyDataForTube(), mitk::TubeGraphVtkMapper3D::GenerateTubeGraphData(), mitk::TextAnnotation2D::GetBoundsOnDisplay(), mitk::TextAnnotation2D::GetVtkActor2D(), mitk::GizmoMapper2D::GetVtkPolyData(), mitk::VtkGLMapperWrapper::GetVtkProp(), mitk::PlaneGeometryDataMapper2D::GetVtkProp(), mitk::GPUVolumeMapper3D::GetVtkProp(), mitk::TextAnnotation3D::GetVtkProp(), mitk::TextAnnotation2D::GetVtkProp(), mitk::SurfaceVtkMapper2D::GetVtkProp(), mitk::ColorBarAnnotation::GetVtkProp(), mitk::LabelAnnotation3D::GetVtkProp(), mitk::LogoAnnotation::GetVtkProp(), mitk::ScaleLegendAnnotation::GetVtkProp(), mitk::SurfaceVtkMapper3D::GetVtkProp(), mitk::PointSetVtkMapper2D::GetVtkProp(), mitk::GPUVolumeMapper3D::InitCPU(), mitk::GPUVolumeMapper3D::InitRAY(), mitk::GPUVolumeMapper3D::IsGPUEnabled(), mitk::GPUVolumeMapper3D::IsRAYEnabled(), mitk::ContourModelGLMapper2D::MitkRender(), mitk::ContourModelSetGLMapper2D::MitkRender(), mitk::TubeGraphVtkMapper3D::RenderTubeGraphPropertyInformation(), mitk::GizmoMapper2D::ResetMapper(), mitk::SurfaceVtkMapper3D::ResetMapper(), mitk::SurfaceVtkMapper2D::ResetMapper(), mitk::PointSetVtkMapper2D::ResetMapper(), runMonteCarlo(), mitk::TextAnnotation2D::SetBoundsOnDisplay(), mitk::GPUVolumeMapper3D::UpdateTransferFunctions(), mitk::TextAnnotation3D::UpdateVtkAnnotation(), mitk::ColorBarAnnotation::UpdateVtkAnnotation(), mitk::LogoAnnotation::UpdateVtkAnnotation(), mitk::LabelAnnotation3D::UpdateVtkAnnotation(), mitk::ScaleLegendAnnotation::UpdateVtkAnnotation(), and mitk::TextAnnotation2D::UpdateVtkAnnotation2D().
#define MBIG |
Definition at line 285 of file MitkMCxyz.cpp.
#define MSEED |
Definition at line 286 of file MitkMCxyz.cpp.
#define MZ |
Definition at line 287 of file MitkMCxyz.cpp.
#define ONE_MINUS_COSZERO |
Definition at line 65 of file MitkMCxyz.cpp.
Referenced by runMonteCarlo().
#define PI |
Definition at line 58 of file MitkMCxyz.cpp.
Referenced by runMonteCarlo().
#define SIGN | ( | x | ) |
Definition at line 64 of file MitkMCxyz.cpp.
Referenced by runMonteCarlo().
#define SQR | ( | x | ) |
Definition at line 63 of file MitkMCxyz.cpp.
#define THRESHOLD |
Definition at line 61 of file MitkMCxyz.cpp.
Referenced by runMonteCarlo().
struct Location initLocation | ( | int | x, |
int | y, | ||
int | z, | ||
double | absorb | ||
) |
Definition at line 75 of file MitkMCxyz.cpp.
References mitk::ImageAccessorBase::GetData(), inputFilename, mitkThrow, normalizationFilename, simulatePVFC, verbose(), and yOffset.
Referenced by runMonteCarlo().
int main | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 630 of file MitkMCxyz.cpp.
References mitkCommandLineParser::addArgument(), mitk::IPropertyPersistence::AddInfo(), us::any_cast(), mitkCommandLineParser::beginGroup(), mitkCommandLineParser::Bool, concurentThreadsSupported, mitk::Image::CopyMemory, detector_x, detector_z, mitkCommandLineParser::endGroup(), mitk::eps, mitkCommandLineParser::File, mitkCommandLineParser::Float, mitk::CoreServices::GetPropertyPersistence(), mitkCommandLineParser::Input, inputFilename, mitkCommandLineParser::Int, interpretAsTime, m_PhotoacousticProbe, mitk::PropertyPersistenceInfo::New(), mitk::Image::New(), normalizationFilename, mitkCommandLineParser::Output, outputFilename, mitkCommandLineParser::parseArguments(), requestedNumberOfPhotons, requestedSimulationTime, runMonteCarlo(), mitk::IOUtil::Save(), mitkCommandLineParser::setArgumentPrefix(), mitkCommandLineParser::setCategory(), mitkCommandLineParser::setContributor(), mitkCommandLineParser::setDescription(), mitkCommandLineParser::setTitle(), simulatePVFC, verbose(), and yOffset.
void runMonteCarlo | ( | InputValues * | inputValues, |
ReturnValues * | returnValue, | ||
int | thread, | ||
mitk::pa::MonteCarloThreadHandler::Pointer | threadHandler | ||
) |
Definition at line 988 of file MitkMCxyz.cpp.
References ALIVE, CHANCE, DEAD, detector_x, detector_z, info(), initLocation(), ls, m_PhotoacousticProbe, MITK_INFO, ONE_MINUS_COSZERO, PI, SIGN, THRESHOLD, verbose(), mitk::pa::LightSource::PhotonInformation::xAngle, mitk::pa::LightSource::PhotonInformation::xPosition, mitk::pa::LightSource::PhotonInformation::yAngle, yOffset, mitk::pa::LightSource::PhotonInformation::yPosition, mitk::pa::LightSource::PhotonInformation::zAngle, and mitk::pa::LightSource::PhotonInformation::zPosition.
Referenced by main().
bool verbose | ( | false | ) |
Referenced by initLocation(), main(), and runMonteCarlo().
int concurentThreadsSupported |
Definition at line 621 of file MitkMCxyz.cpp.
Referenced by main().
int detector_x |
Definition at line 615 of file MitkMCxyz.cpp.
Referenced by main(), and runMonteCarlo().
int detector_z |
Definition at line 616 of file MitkMCxyz.cpp.
Referenced by main(), and runMonteCarlo().
std::string inputFilename |
Definition at line 625 of file MitkMCxyz.cpp.
Referenced by initLocation(), and main().
bool interpretAsTime |
Definition at line 617 of file MitkMCxyz.cpp.
Referenced by main().
mitk::pa::Probe::Pointer m_PhotoacousticProbe |
Definition at line 628 of file MitkMCxyz.cpp.
Referenced by main(), and runMonteCarlo().
std::string normalizationFilename |
Definition at line 624 of file MitkMCxyz.cpp.
Referenced by initLocation(), and main().
std::string outputFilename |
Definition at line 626 of file MitkMCxyz.cpp.
Referenced by main().
int requestedNumberOfPhotons |
Definition at line 619 of file MitkMCxyz.cpp.
Referenced by main().
float requestedSimulationTime |
Definition at line 620 of file MitkMCxyz.cpp.
Referenced by main().
bool saveLegacy |
Definition at line 623 of file MitkMCxyz.cpp.
bool simulatePVFC |
Definition at line 618 of file MitkMCxyz.cpp.
Referenced by initLocation(), and main().
float yOffset |
Definition at line 622 of file MitkMCxyz.cpp.
Referenced by mitk::CorrectorAlgorithm::ImprovedHeimannCorrectionAlgorithm(), initLocation(), mitk::pa::IOUtil::LoadFluenceSimulation(), main(), mitk::pa::FluenceYOffsetPair::operator=(), and runMonteCarlo().