public class CL_Initializer
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static double |
BACKGROUNDTHRESHOLD
Threshold on the q=0 measurements to detect background.
|
static int |
BALLSTICKVALSPERVOXEL
The number of values per voxel for the ball and stick model.
|
static int |
basisType
The type of basis function used for linear reconstructions.
|
static DataSource |
bgMask
The background mask.
|
static java.lang.String |
bgMaskFile
Name of the background mask file.
|
static java.lang.String |
bgMaskType
The type of the background mask
|
static int |
bootstrap
The number of bootstraps used in bootstrapping.
|
static boolean |
brownianSimulation
Indicates whether to synthesise data using simulation
|
static java.lang.String[] |
bsDataFiles
List of files containing repeated measurements of the same data for use
in bootstrapping.
|
static int |
burnInTime
Burn-in period of Markov Chain Monte Carlo algorithm .
|
static double |
bValue
Fixed b-value for schemes created at run time.
|
static double |
centreDist
distance of centre of circle from centre of voxel grid
|
static ModelIndex[][] |
classifiedModelIndices
Array of indices of the models in classified model fitting.
|
static boolean |
compartmentModel
Indicates whether to synthesise data using a compartment model
|
static java.lang.String[] |
compartmentNames
list of names for each compartment in compartment model
|
static double[] |
compParams
list of parsed parameters for compartmentModel
|
static double |
CSFTHRESHOLD
Threshold on the q=0 measurements to detect CSF.
|
static DataSource |
data
The data source to process.
|
static int[] |
dataDims
Dimensions of voxel grid
|
static double |
DIFF_CONST
simulation diffusivity
|
static double |
dt2mix
Specifies the mixing parameter for StandardTestFunctions.dt2.
|
static double |
dt2rotangle
Specifies the angle of rotation for StandardTestFunctions.dt2.
|
static double |
f1
The f-test thresholds.
|
static double |
f2 |
static double |
f3 |
static java.lang.String |
fitAlgorithm
type of fitting algorithm
|
static java.lang.String |
fitModel
type of tissue model for fitting
|
static boolean |
fixedStartPoint
Start point for compartment model fitting from commandline
|
static double |
gamma_beta
scale parameter for gamma distribution
|
static double |
gamma_k
shape parameter for gamma distributed random numbers
|
static DW_Scheme |
imPars
The parameters of the imaging sequence corresponding to the input data.
|
static java.lang.String |
inputDataType
The type of the input data
|
static java.lang.String |
inputFile
Name of the input data file.
|
static java.lang.String |
inputModel
The type of model represented by the input data.
|
static int |
interval
Number of steps between samples in Markov Chain Monte Carlo algorithm .
|
static ModelIndex[] |
inversionIndices
Index specifying the inversion.
|
static double[] |
kernelParams
Specification of the maximum entropy deconvolution filter.
|
static double |
lambda1
Alternative setting for lambda1 in the standard test functions.
|
static boolean |
lrLog
Specifies whether or not the linear reconstruction should use the log
measurements.
|
static boolean |
lrNormalize
Specifies whether or not the data should be normalized before linear
reconstruction.
|
static int |
M
The number of zero measurements.
|
static java.lang.String |
matrixFile
Name of the matrix file for linear reconstructions.
|
static int |
maxOrder
The maximum order in the fitted spherical harmonic series.
|
static int |
maxTensorComponents
Maximum number of components in classified model fitting.
|
static java.lang.String |
mcmcStatsFile
Name of a file to output MCMC statistics.
|
static int |
mePointSet
Specifies the set of reconstruction directions for maximum entropy
deconvolution if it is different from the direction set specified in the
scheme file.
|
static double |
mmwmddiff
Intrinsic diffusivity in the MMWMD models.
|
static boolean |
modelfitting
indicates if we are using our compartment model for fitting or not
|
static int |
N
The number of non-zero measurements.
|
static java.lang.String |
noiseModel
type of noise model for fitting
|
static java.lang.String |
noiseType
Specifies the type of noise to add.
|
static java.lang.String |
noiseVarianceMapFile
Name of the noise variance map file for inversions that compute it.
|
static boolean |
nonStandardTestFunction
Indicates whether or not the user specified a non-standard test function.
|
static int |
numElements
number of elements in a voxel
|
static int |
numPDsIO
Number of principal directions in the input or output stream.
|
static int |
numVoxels
The number of voxels to process.
|
static int |
ONETENVALSPERVOXEL
The number of values per voxel in single tensor data.
|
static java.lang.String |
outlierMapFile
Name of the outlier map for RESTORE.
|
static ModelPDF |
p
The test function to use for simulations.
|
static int |
pointSetInd
Index of the ISCodes point set to use for computing spherical integrals.
|
static boolean |
pointSetIndSet
Flag indicating that the IS codes point set index was set.
|
static java.lang.String |
reorientation
Name of the reorientation strategy to use.
|
static java.lang.String |
residualVectorMapFile
Name of the residual vector map file for inversions that compute it.
|
static int |
rotationIndex
Index of the random rotation index to apply to the test function.
|
static int |
samples
Number of samples produced by Markov Chain Monte Carlo algorithm .
|
static double |
scale
Alternative setting for scaling the standard test functions.
|
static java.lang.String |
schemeFile
Name of the imaging scheme file.
|
static int |
seed
Random number generator seed.
|
static double |
sigma
The expected standard deviation of the noise in the data.
|
static SimulationParams |
simParams
diffusion simulation parameters object
|
static double |
SNR
The signal to noise ratio in synthetic data.
|
static int |
testFunction
Standard test function index.
|
static double[] |
testFunctionData
If a non-standard test function was specified, the parameters are read
from the command line into this array.
|
static int |
THREETENVALSPERVOXEL
The number of values per voxel in three-tensor data.
|
static java.lang.String |
transformFile
Name of a file containing an affine image transformation.
|
static java.lang.String |
transformFileX
Names of files containing an image warp.
|
static java.lang.String |
transformFileY |
static java.lang.String |
transformFileZ |
static int |
TWOTENVALSPERVOXEL
The number of values per voxel in two-tensor data.
|
static double |
volFrac
volume fraction
|
static java.lang.String |
voxelClassMap
Name of file containing voxel classification.
|
static double[] |
voxelDims
Voxel size in millimeters
|
static java.lang.String |
wildBootstrapModel
Model used in wild bootstrapping.
|
Modifier and Type | Method and Description |
---|---|
static java.lang.String[] |
augmentArgs(java.lang.String[] args,
java.lang.String filename)
Augments the command-line arguments array with arguments read from a
config file.
|
static void |
checkParsing(java.lang.String[] args)
Checks the arguments and logs any args that have not been marked as
parsed.
|
static void |
CL_init(java.lang.String[] args)
The constructor requires only the array of command line arguments.
|
static ModelPDF |
constructTestFunction(double[] testFunctionData)
Constructs a test function from an array of values given on the command
line.
|
static void |
exceptionTest()
routine that throws an exeption, to test exception handling.
|
static DataSource |
getDataSynthesizer(ModelPDF p,
DW_Scheme imPars,
double SNR,
int numVoxels,
int seed,
int bootstrap)
Creates the source of data from options specified on the command line.
|
static void |
initDataSynthesizer()
Initializes the synthetic data source.
|
static void |
initImagingScheme()
Initializes the DW_Scheme object containing the acqusition information.
|
static void |
initMaskSource()
Initializes the data source for the background mask.
|
static void |
initMaxEnt()
Initializes the reconstruction direction set for maximum entropy
deconvolution.
|
static void |
initSphFuncDataSource()
Initializes an external data source for spherical function parameters.
|
static void |
initTensorDataSource()
Initializes an external data source for tensor data
|
static void |
main(java.lang.String[] args) |
static void |
markAsParsed(int i)
Mark a single argument
i as parsed. |
static void |
markAsParsed(int i,
int numArgs)
Mark sequential arguments as parsed, from
i to
i + numArgs - 1 . |
static void |
setDataSource(DataSource newDataSource)
Specifies a specific data source object.
|
static void |
setMaskSource(DataSource newMaskSource)
Specifies a specific data source object for the background mask.
|
static void |
testCompartmetnParsing() |
public static final int BALLSTICKVALSPERVOXEL
public static final int ONETENVALSPERVOXEL
public static final int TWOTENVALSPERVOXEL
public static final int THREETENVALSPERVOXEL
public static int testFunction
public static boolean nonStandardTestFunction
public static boolean brownianSimulation
public static boolean compartmentModel
public static boolean modelfitting
public static java.lang.String fitModel
public static boolean fixedStartPoint
public static java.lang.String noiseModel
public static java.lang.String fitAlgorithm
public static SimulationParams simParams
public static double DIFF_CONST
public static double volFrac
public static int[] dataDims
public static double[] voxelDims
public static double centreDist
public static double[] testFunctionData
public static ModelIndex[] inversionIndices
public static int rotationIndex
public static int numVoxels
public static double lambda1
public static double dt2rotangle
public static double dt2mix
public static double scale
public static int numElements
public static int M
public static int N
public static double bValue
public static double SNR
public static int bootstrap
public static java.lang.String wildBootstrapModel
public static java.lang.String[] bsDataFiles
public static int seed
public static java.lang.String voxelClassMap
public static int maxTensorComponents
public static double gamma_k
public static double gamma_beta
public static double mmwmddiff
public static ModelIndex[][] classifiedModelIndices
public static java.lang.String inputFile
public static java.lang.String bgMaskFile
public static java.lang.String schemeFile
public static double sigma
public static java.lang.String noiseType
public static java.lang.String outlierMapFile
public static java.lang.String noiseVarianceMapFile
public static java.lang.String residualVectorMapFile
public static java.lang.String matrixFile
public static boolean lrNormalize
public static boolean lrLog
public static java.lang.String inputDataType
public static java.lang.String bgMaskType
public static java.lang.String inputModel
public static java.lang.String[] compartmentNames
public static double[] compParams
public static int basisType
public static int pointSetInd
public static boolean pointSetIndSet
public static int numPDsIO
public static int maxOrder
public static double f1
public static double f2
public static double f3
public static double[] kernelParams
public static int mePointSet
public static double BACKGROUNDTHRESHOLD
public static double CSFTHRESHOLD
public static DW_Scheme imPars
public static ModelPDF p
public static DataSource data
public static DataSource bgMask
public static java.lang.String transformFile
public static java.lang.String transformFileX
public static java.lang.String transformFileY
public static java.lang.String transformFileZ
public static java.lang.String reorientation
public static int burnInTime
public static int samples
public static int interval
public static java.lang.String mcmcStatsFile
public static void CL_init(java.lang.String[] args)
args
- The array of command line arguments to a DiffusionInversions
application.public static final void checkParsing(java.lang.String[] args)
public static java.lang.String[] augmentArgs(java.lang.String[] args, java.lang.String filename) throws java.io.FileNotFoundException
args
- The current args arrayfilename
- The name of the config file.java.io.FileNotFoundException
public static void initImagingScheme()
public static void initMaxEnt()
public static void setDataSource(DataSource newDataSource)
newDataSource
- The data source.public static void setMaskSource(DataSource newMaskSource)
newMaskSource
- The data source.public static void initSphFuncDataSource()
public static void initTensorDataSource()
public static void initMaskSource()
public static void initDataSynthesizer()
public static ModelPDF constructTestFunction(double[] testFunctionData)
testFunctionData
- The array of parameters given on the command line.ModelPDF
object encapsulating the test
function.public static DataSource getDataSynthesizer(ModelPDF p, DW_Scheme imPars, double SNR, int numVoxels, int seed, int bootstrap)
p
- The model for the spin displacement density to use in a
synthetic data source.imPars
- The details of the imaging sequence.SNR
- The signal to noise ratio for synthetic data.numVoxels
- The number of voxels the data source should produce.seed
- Random number generator seed.bootstrap
- If zero or less, this function returns a
DataSynthesizer
object. If greater than zero,
it returns a SyntheticBootstrapper
with
bootstrap
repeats.public static final void markAsParsed(int i)
i
as parsed.public static final void markAsParsed(int i, int numArgs)
i
to
i + numArgs - 1
.i
- the index of the first argument to mark as parsed.numArgs
- the number of arguments to mark as parsed.public static void exceptionTest() throws java.lang.Exception
java.lang.Exception
public static void testCompartmetnParsing()
public static void main(java.lang.String[] args)