Class FileAfni
- java.lang.Object
-
- gov.nih.mipav.model.file.FileBase
-
- gov.nih.mipav.model.file.FileAfni
-
public class FileAfni extends FileBase
Afni file format.In Afni 3 .HEAD files may be present with just 1 .BRIK file containing the original Data. The +orig.BRIK file will contain the data, the +orig.HEAD file will describe transformation to create the original image, the +acpc.HEAD file will describe the transformation needed to create the acpc image, and the +tlrc.HEAD file will describe the transformation needed to create the Talairach image.
Special notes:
The document README.attributes specifies DICOM order for MARKS_XYZ, but the sample file anat+orig.HEAD has dataset order. The sample file anat+ACPC.HEAD has DICOM order.
The original data must be resampled to cubic voxels for +acpc and +tlrc space. In FAQ 67, How can I compare 'small' and 'big' in Talairach box datasets, the text states:
If you have used the default 1 mm. voxel size in +tlrc coordinates(as almost everyone does)...The function THD_3dmm_to_dicomm does changes the ordering of x, y, and z, but never inverts them. That is either R-L or L-R could be present in AFNI's Dicom ordering, either S-I or I-S could be present in AFNI's dicom ordering, and either A-P or P-A could be present in AFNI's dicom ordering. I perform inversions in my code so that I always have x = R-L, Y = A-P, and Z = I-S, the standard dicom ordering.
To obtain the afni rr, bvec, and svec values, I must not invert axes in dicom ordering, and I must not adjust the marker coordinates for resolution and origin.
The function of the SKIP fields is not defined in the AFNI documentation.
Note that AFNI code uses mfor for forward transformation and mbac for backward transformation. Our interpolation routines perform a output to input mapping so since I am skipping the transform() section of AlgorithmTransform which has the line xfrm = matrixtoInverseArray(transMatrix);
I wish to use mbac in FileAfni and ViewJFrameTriImage.
For +orig to +acpc mapping mbac is simply the transpose(also the inverse) of mfor.
For +acpc to +tlrc use 1 over the scale factors in mbac as opposed to the scale factors in mfor.
Note that in the sample files func+orig.head and anat+orig.head the origin location in millimeters is chosen so that 0,0,0 in millimeters is at the center of the image. In anat+acpc.head and anat+tlrc.head the origin location in millimeters ensures that the Talairach center is at 0,0,0.
AFNI:Software for Analysis and Visualization of Functional Magnetic Resonance Neuroimages by Robert W. Cox states: "In some applications, gaps are present between the functional slices. For example, some investigators using sagittal functional images do not collect data that spans the longitudinal fissure, but instead leave a 3-5 mm gap there. The auxiliary program abut can provide zero-filled images to fill in the gaps, and can resample the nonzero slices to a finer mesh if needed(e.g., to fill a 2 mm gap in a series of 4 mm functional slices). Resampling in the slice select direction between contiguous input slices can be done using nearest- neighbor, linear, or cubic interpolation, at the user's discretion. Interpolation is not done across the boundaries between the gap-filling zero images and the nonzero user-supplied images; that is, interpolation is only done inside spatially contiguous blocks of actual input data."
A second special consideration exists in the interpolation of functional data. The MCW AFNI - User Manual states: "In this version of AFNI, the threshold data (e.g., correlation coefficient) is always resampled using the nearest neighbor method. This is because thresholding with an interpolated nonlinear statistic is a somewhat dubious procedure." At another point the manual states: "Threshold data in functional datasets is always resampled using the nearest neighbor mode. This is becasue it is somewhat unreasonable to interpolate a nonlinear statistic (such as correlation coefficient) between voxels, and then to interpret this statistic using probabilistic models that assume independence."
v1:time+orig.HEAD has 1 = ORI_L2R_TYPE for the third ORIENT_SPECIFIC value, -53 for the third ORIGIN value, and 7 for the third delta value. However, delta should be negative for ORI_L2R_TYPE. I changed the values to those found in v2:time+orig.HEAD, namely 1 for the third ORIENT_SPECIFIC value, 52 for the third ORIGIN value, and -7 for the third delta value. The observed overlap was then excellent for v1_time+orig.HEAD and anat+orig.HEAD, anat+ACPC.HEAD, and anat+TLRC.HEAD.
- Author:
- William Gandler
- See Also:
FileIO
-
-
Field Summary
Fields Modifier and Type Field Description private WildMagic.LibFoundation.Mathematics.Vector3facpcACAnterior Comissure in acpc space.private WildMagic.LibFoundation.Mathematics.Vector3facpcMaxPtDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3facpcMinPtDOCUMENT ME!private java.lang.StringacpcNameDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3facpcPCDOCUMENT ME!private floatacpcResDOCUMENT ME!private floatacquisitionDurationDOCUMENT ME!private booleanalsoAcpcDOCUMENT ME!private booleanalsoOrigDOCUMENT ME!static intANAT_BMAP_TYPEDOCUMENT ME!static intANAT_BUCK_TYPEDOCUMENT ME!static intANAT_CT_TYPEDOCUMENT ME!static intANAT_DIFF_TYPEDOCUMENT ME!static intANAT_EPI_TYPEDOCUMENT ME!static intANAT_FSE_TYPEDOCUMENT ME!static intANAT_MRA_TYPEDOCUMENT ME!static intANAT_MRAN_TYPEDOCUMENT ME!static intANAT_OMRI_TYPEDOCUMENT ME!static intANAT_PET_TYPEDOCUMENT ME!static intANAT_SPECT_TYPEDOCUMENT ME!static intANAT_SPGR_TYPEfuncType for anatType == true.private java.lang.StringanatomyParentnameStringDOCUMENT ME!private booleananatTypeDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fanotherPtDicomDOCUMENT ME!private static floatATLAS_AC_TO_LATDOCUMENT ME!private static floatATLAS_AC_TO_TOPDOCUMENT ME!private static floatATLAS_BOT_TO_ACDOCUMENT ME!private static floatATLAS_FRONT_TO_ACDOCUMENT ME!private static floatATLAS_PC_TO_BACKDOCUMENT ME!private float[]brickFloatFacsDOCUMENT ME!private java.lang.StringbrickKeywordsStringDOCUMENT ME!private java.lang.String[]brickLabsStringSub-brick namesprivate float[]brickStatAuxEach BLT is defined by a struct that contains two 3x3 matrices and four 3-vectors (2*3*3 + 4*3 = the 30 numbers).private float[]brickStatsDOCUMENT ME!private intbrickTypeDOCUMENT ME!private intbrickTypeNumberDOCUMENT ME!private intbrikDataTypeDOCUMENT ME!private java.lang.StringbrikFileNameDOCUMENT ME!private intbufferSizeDOCUMENT ME!private int[]dataExtentsDOCUMENT ME!private int[]dataOrientDOCUMENT ME!private java.lang.StringdatasetKeywordsStringDOCUMENT ME!private java.lang.StringdatasetNameStringDOCUMENT ME!private intddofDOCUMENT ME!private float[]deltaDOCUMENT ME!private float[]dicomDeltaDOCUMENT ME!private floatdicomHighestXDOCUMENT ME!private floatdicomHighestYDOCUMENT ME!private floatdicomHighestZDOCUMENT ME!private floatdicomLowestXDicom ordered bounding box in mm.private floatdicomLowestYDicom ordered bounding box in mm.private floatdicomLowestZDicom ordered bounding box in mm.private int[]dicomOrientationDOCUMENT ME!private float[]dicomOriginDOCUMENT ME!private intdicomSliceSizeDOCUMENT ME!private intdicomXDimDOCUMENT ME!private intdicomYDimDOCUMENT ME!private intdicomZDimDOCUMENT ME!private floatdist_antDOCUMENT ME!private floatdist_infDOCUMENT ME!private floatdist_lefDOCUMENT ME!private floatdist_medDOCUMENT ME!private floatdist_posDOCUMENT ME!private floatdist_rigDOCUMENT ME!private floatdist_supDOCUMENT ME!private booleandoDicomDOCUMENT ME!private intdofFUNC_TT_TYPE Student t Degrees-of-Freedom (DOF).private booleanendianessDOCUMENT ME!private java.io.FilefileDOCUMENT ME!private java.lang.StringfileDirDOCUMENT ME!private FileInfoAfnifileInfoDOCUMENT ME!private FileInfoAfnifileInfoCopyprivate longfileLengthDOCUMENT ME!private java.lang.StringfileNameDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3ffirstPtDicomDOCUMENT ME!static intFLOAT_ATTRIBUTEDOCUMENT ME!private intfloatsPerTagDOCUMENT ME!static floatFUNC_BN_SCALE_SHORTDOCUMENT ME!static intFUNC_BN_TYPEDOCUMENT ME!static floatFUNC_BT_SCALE_BYTEDOCUMENT ME!static floatFUNC_BT_SCALE_SHORTDOCUMENT ME!static intFUNC_BT_TYPEDOCUMENT ME!static intFUNC_BUCK_TYPEDOCUMENT ME!static floatFUNC_COR_SCALE_BYTEDOCUMENT ME!static floatFUNC_COR_SCALE_SHORTDOCUMENT ME!static intFUNC_COR_TYPEDOCUMENT ME!static floatFUNC_CT_SCALE_SHORTDOCUMENT ME!static intFUNC_CT_TYPEDOCUMENT ME!static intFUNC_FIM_TYPEfuncType for anatType == false.static floatFUNC_FT_SCALE_SHORTDOCUMENT ME!static intFUNC_FT_TYPEDOCUMENT ME!static floatFUNC_GT_SCALE_BYTEDOCUMENT ME!static floatFUNC_GT_SCALE_SHORTDOCUMENT ME!static intFUNC_GT_TYPEDOCUMENT ME!static floatFUNC_PT_SCALE_SHORTDOCUMENT ME!static intFUNC_PT_TYPEDOCUMENT ME!static floatFUNC_THR_SCALE_BYTE6 funcType of functional data have default scaling for byte data.static floatFUNC_THR_SCALE_SHORTUnfortunately, the func type codes overlap for Func and Anat datasets.static intFUNC_THR_TYPEDOCUMENT ME!static floatFUNC_TT_SCALE_BYTEDOCUMENT ME!static floatFUNC_TT_SCALE_SHORTDOCUMENT ME!static intFUNC_TT_TYPEDOCUMENT ME!static floatFUNC_ZT_SCALE_BYTEDOCUMENT ME!static floatFUNC_ZT_SCALE_SHORTDOCUMENT ME!static intFUNC_ZT_TYPEDOCUMENT ME!private intfuncTypeDOCUMENT ME!private booleanhaveReadACPCDOCUMENT ME!private booleanhaveReadOrigDOCUMENT ME!private floathighestXDataset ordered bounding box in mm.private floathighestYDataset ordered bounding box in mm.private floathighestZDataset ordered bounding box in mm.private java.lang.StringhistoryNoteStringDOCUMENT ME!private java.lang.StringidcodeAnatParentStringDOCUMENT ME!private java.lang.StringidcodeDateStringDOCUMENT ME!private java.lang.StringidcodeStringDOCUMENT ME!private java.lang.StringidcodeWarpParentStringDOCUMENT ME!private ModelImageimageDOCUMENT ME!private float[]img2BufferDOCUMENT ME!private float[]imgBufferDOCUMENT ME!private int[]imgExtentsDOCUMENT ME!private float[]imgResolsDOCUMENT ME!static intINTEGER_ATTRIBUTEattribute types.private booleaninvertXDOCUMENT ME!private booleaninvertYDOCUMENT ME!private booleaninvertZDOCUMENT ME!private java.lang.Stringlabel1StringDOCUMENT ME!private java.lang.Stringlabel2StringDOCUMENT ME!private booleanloadBDOCUMENT ME!private floatlowestXDataset ordered bounding box in mm.private floatlowestYDataset ordered bounding box in mm.private floatlowestZDataset ordered bounding box in mm.static intMARKSET_ALIGNmarker types.static intMARKSET_BOUNDINGDOCUMENT ME!private intmarksFlagDOCUMENT ME!private intmarksFlagsDOCUMENT ME!private java.lang.String[]marksHelpStringDOCUMENT ME!private java.lang.String[]marksLabStringDOCUMENT ME!private float[]marksXYZDOCUMENT ME!private intndofFUNC_FT_TYPE F ratio Numerator DOF, Denominator DOF.private java.lang.StringnoteDate001StringDOCUMENT ME!private java.lang.StringnoteDate002StringDOCUMENT ME!private java.lang.StringnoteDate003StringDOCUMENT ME!private java.lang.StringnoteDate004StringDOCUMENT ME!private java.lang.StringnoteDate005StringDOCUMENT ME!private java.lang.StringnoteNumber001StringDOCUMENT ME!private java.lang.StringnoteNumber002StringDOCUMENT ME!private java.lang.StringnoteNumber003StringDOCUMENT ME!private java.lang.StringnoteNumber004StringDOCUMENT ME!private java.lang.StringnoteNumber005StringDOCUMENT ME!private intnotesCountDOCUMENT ME!private intnumberDicomSlicesDOCUMENT ME!private intnumberSlicesDOCUMENT ME!private intnumFitParamDOCUMENT ME!private intnumNuisanceParamDOCUMENT ME!private intnumSamplesDOCUMENT ME!private intnumTrialsFUNC_BN_TYPE Binomial # Trials, Probability per trial.private int[]orientSpecificDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3forigACDOCUMENT ME!private float[]origDeltaDOCUMENT ME!private booleanorigDicomDOCUMENT ME!private int[]origExtentsDOCUMENT ME!private float[]originDOCUMENT ME!private java.lang.StringoriginalFileNameDOCUMENT ME!private java.lang.StringorigNameDOCUMENT ME!private float[]origOriginDOCUMENT ME!private intorigXDimDOCUMENT ME!private intorigYDimDOCUMENT ME!private intorigZDimDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fpcDicomDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fpointMarkerDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fposteriorMarginDicomDOCUMENT ME!private intpresentViewTypeDOCUMENT ME!private booleanreadACPCDOCUMENT ME!private booleanreadTLRCDOCUMENT ME!private floatscale_ADOCUMENT ME!private floatscale_IDOCUMENT ME!private floatscale_LDOCUMENT ME!private floatscale_MDOCUMENT ME!private floatscale_PDOCUMENT ME!private floatscale_RDOCUMENT ME!private floatscale_SDOCUMENT ME!private float[]skipDOCUMENT ME!private intsliceSizeDOCUMENT ME!private intslicesWithTimeOffsetsDOCUMENT ME!private float[]statAux# orts are nuisance parameters whose number is >= 1.private intstatCodeDOCUMENT ME!static intSTRING_ATTRIBUTEDOCUMENT ME!private intsubBrickIndexDOCUMENT ME!private intsubBrickNumberDOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fsuperiorEdgeDicomDOCUMENT ME!private float[]tagAlignMatvecThe "p-values" for fico, fitt, and fizt datasets are 2-sided: that is, the value displayed by AFNI (below the slider) is the probability that the absolute value of such a deviate will exceed the threshold value on the slider.private inttagNumberDOCUMENT ME!private float[]tagsetFloatsDOCUMENT ME!private java.lang.StringtagsetLabelsString2560 characters giving the help strings for the markers (256 chars per marker, EXACTLY, including the NULS).private float[]tAxisOffsetsDOCUMENT ME!private inttDimDOCUMENT ME!private floattimeOriginDOCUMENT ME!private floattimeStepDOCUMENT ME!private inttimeStepUnitDOCUMENT ME!private TalairachTransformInfotInfoDOCUMENT ME!private float[]tlrcResDOCUMENT ME!private java.lang.StringtypeStringDOCUMENT ME!private inttypeStringTypeDOCUMENT ME!private ViewUserInterfaceUIDOCUMENT ME!static intUNITS_HZ_TYPEDOCUMENT ME!static intUNITS_MSEC_TYPEtime step units.static intUNITS_SEC_TYPEDOCUMENT ME!private intviewTypeDOCUMENT ME!private java.lang.StringvolregBaseIdcodeStringDOCUMENT ME!private java.lang.StringvolregBaseNameStringDOCUMENT ME!private float[]volregCenterBaseDOCUMENT ME!private float[]volregCenterOldFor sub-brick #xxxxxx (so a max of 999,999 sub-bricks can be used), this stores 12 numbers for the matrix-vector of transformation from 3dvolreg.private java.lang.StringvolregGridparentIdcodeStringDOCUMENT ME!private java.lang.StringvolregGridparentNameStringDOCUMENT ME!private java.lang.StringvolregInputIdcodeStringDOCUMENT ME!private java.lang.StringvolregInputNameStringDOCUMENT ME!private float[]volregMatvec000000DOCUMENT ME!private float[]volregMatvec000001DOCUMENT ME!private float[]volregMatvec000002DOCUMENT ME!private float[]volregMatvec000003DOCUMENT ME!private float[]volregMatvec000004DOCUMENT ME!private float[]volregMatvec000005DOCUMENT ME!private float[]volregMatvec000006DOCUMENT ME!private float[]volregMatvec000007DOCUMENT ME!private float[]volregMatvec000008DOCUMENT ME!private float[]volregMatvec000009DOCUMENT ME!private intvolregRotcomNumDOCUMENT ME!private java.lang.StringvolregRotparentIdcodeStringDOCUMENT ME!private java.lang.StringvolregRotparentNameStringDOCUMENT ME!static intWARP_AFFINE_TYPEwarp types.static intWARP_TALAIRACH_12_TYPEDOCUMENT ME!private float[]warpDataDOCUMENT ME!private java.lang.StringwarpParentnameStringDOCUMENT ME!private intwarpTypeDOCUMENT ME!private intxDimDOCUMENT ME!private intyDimDOCUMENT ME!private floatzAxisOffsetDOCUMENT ME!private floatzAxisStepDOCUMENT ME!private intzDimDOCUMENT ME!private int[]zeroPadDOCUMENT ME!-
Fields inherited from class gov.nih.mipav.model.file.FileBase
BIG_ENDIAN, bitsPerPixel, fileNames, LITTLE_ENDIAN, pBarVisible, raFile, READ, READ_WRITE
-
-
Constructor Summary
Constructors Constructor Description FileAfni(java.lang.String fileName, java.lang.String fileDir, boolean loadB, boolean doRead)Afni reader constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private voidcalcOriginalMarker(int markerNumber)DOCUMENT ME!private voidcreateOrderDialog()DOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fcrossProduct(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2)Finds crossproduct of two vectors.private WildMagic.LibFoundation.Mathematics.Vector3fdicomMarker(WildMagic.LibFoundation.Mathematics.Vector3f pMarker)DOCUMENT ME!private floatdist(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2, float[] resol)DOCUMENT ME!private floatdotProduct(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2)DOCUMENT ME!voidfinalize()Prepares this class for cleanup.FileInfoBasegetFileInfo()getFileInfo - accessor that returns the file info.float[]getImageBuffer()getImageBuffer - accessor that returns the image buffer.ModelLUTgetModelLUT()private WildMagic.LibFoundation.Mathematics.Vector3fmakemmVector3f(WildMagic.LibFoundation.Mathematics.Vector3f pt, float[] resol)DOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fmakeVoxelCoord3Df(WildMagic.LibFoundation.Mathematics.Vector3f pt, float[] resol)DOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fnorm(WildMagic.LibFoundation.Mathematics.Vector3f pt)Finds the normal to the vector.voidreadBuffer(int slice, float[] buffer, float scaleFact, int numRead)Reads a slice of data at a time and stores the results in the buffer.booleanreadHeader()Reads AFNI header (.HEAD file)ModelImagereadImage()readImage.private ModelImagereadImage2()Reads AFNI image (.BRIK file)private java.lang.StringreadLine()readLine() - reads a line of the file and strips comments indicated by the # symbol.voidreadXYZBuffer(int slice, float[] buffer, float[] dicomBuffer, float scaleFact)Reads a slice of data at a time and stores the results in the buffer.private java.lang.StringremoveWhiteSpace(java.lang.String inString)DOCUMENT ME!private voidreposMarker(int markerNumber)DOCUMENT ME!private WildMagic.LibFoundation.Mathematics.Vector3fsclAdd(float fa, WildMagic.LibFoundation.Mathematics.Vector3f a, float fb, WildMagic.LibFoundation.Mathematics.Vector3f b)scale and add two vectors.voidsetFileName(java.lang.String fName)setFileName - accessor to set the file name (used when reading TIFF multiFile).private WildMagic.LibFoundation.Mathematics.Vector3fsub(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2)DOCUMENT ME!private voidtransformACPCTrilinear(float[] imgBuffer, TransMatrix xfrm, float iXres, float iYres, float iZres, int iXdim, int iYdim, int iZdim, float oXres, float oYres, float oZres, int oXdim, int oYdim, int oZdim)transformACPCTrilinear - transforms and resamples volume using trilinear interpolation.private voidtransformTalairachTrilinear(float[] imgBuffer, TransMatrix xfrm, float iXres, float iYres, float iZres, int iXdim, int iYdim, int iZdim, float oXres, float oYres, float oZres, int oXdim, int botX, int botY, int botZ, int topX, int topY, int topZ)transformTalairachTrilinear - transforms and resamples volume using trilinear interpolation.voidwriteImage(ModelImage image, FileWriteOptions options)Writes a AFNI format type image.-
Methods inherited from class gov.nih.mipav.model.file.FileBase
addProgressChangeListener, bytesToDouble, bytesToFloat, bytesToInt, bytesToShort, doubleToBytes, fireProgressStateChanged, fireProgressStateChanged, fireProgressStateChanged, floatToBytes, getBufferDouble, getBufferFloat, getBufferInt, getBufferLong, getBufferShort, getBufferUShort, getDataType, getDouble, getFloat, getInt, getLong, getProgressChangeListeners, getRaFile, getSignedShort, getString, getUInt, getUnsignedByte, getUnsignedShort, intToBytes, isBigEndian, isProgressBarVisible, linkProgress, longToBytes, readDouble, readFloat, readInt, readLong, readShort, readString, readUnsignedShort, removeProgressChangeListener, setBigEndian, setBufferFloat, setBufferInt, setBufferLong, setBufferShort, setBufferString, setDataType, setEndianess, shortToBytes, writeBytes, writeDouble, writeFloat, writeInt, writeLong, writeShort
-
-
-
-
Field Detail
-
INTEGER_ATTRIBUTE
public static final int INTEGER_ATTRIBUTE
attribute types.- See Also:
- Constant Field Values
-
FLOAT_ATTRIBUTE
public static final int FLOAT_ATTRIBUTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
STRING_ATTRIBUTE
public static final int STRING_ATTRIBUTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_SPGR_TYPE
public static final int ANAT_SPGR_TYPE
funcType for anatType == true.- See Also:
- Constant Field Values
-
ANAT_FSE_TYPE
public static final int ANAT_FSE_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_EPI_TYPE
public static final int ANAT_EPI_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_MRAN_TYPE
public static final int ANAT_MRAN_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_CT_TYPE
public static final int ANAT_CT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_SPECT_TYPE
public static final int ANAT_SPECT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_PET_TYPE
public static final int ANAT_PET_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_MRA_TYPE
public static final int ANAT_MRA_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_BMAP_TYPE
public static final int ANAT_BMAP_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_DIFF_TYPE
public static final int ANAT_DIFF_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_OMRI_TYPE
public static final int ANAT_OMRI_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ANAT_BUCK_TYPE
public static final int ANAT_BUCK_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_FIM_TYPE
public static final int FUNC_FIM_TYPE
funcType for anatType == false.- See Also:
- Constant Field Values
-
FUNC_THR_TYPE
public static final int FUNC_THR_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_COR_TYPE
public static final int FUNC_COR_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_TT_TYPE
public static final int FUNC_TT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_FT_TYPE
public static final int FUNC_FT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_ZT_TYPE
public static final int FUNC_ZT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_CT_TYPE
public static final int FUNC_CT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_BT_TYPE
public static final int FUNC_BT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_BN_TYPE
public static final int FUNC_BN_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_GT_TYPE
public static final int FUNC_GT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_PT_TYPE
public static final int FUNC_PT_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_BUCK_TYPE
public static final int FUNC_BUCK_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_THR_SCALE_SHORT
public static final float FUNC_THR_SCALE_SHORT
Unfortunately, the func type codes overlap for Func and Anat datasets. This means that one cannot tell the contents of a dataset from a single attribute. Default scale factors for functional data threshold values stored as shorts If BRICK_FLOAT_FACS is not supplied and the threshold functional data is stored as shorts, then AFNI will apply a default scale factor unless the data is FUNC_FIM_TYPE with only an intensity value and no threshold value or FUNC_BUCK_TYPE which has a default scale factor of 1.- See Also:
- Constant Field Values
-
FUNC_COR_SCALE_SHORT
public static final float FUNC_COR_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_TT_SCALE_SHORT
public static final float FUNC_TT_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_FT_SCALE_SHORT
public static final float FUNC_FT_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_ZT_SCALE_SHORT
public static final float FUNC_ZT_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_CT_SCALE_SHORT
public static final float FUNC_CT_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_BT_SCALE_SHORT
public static final float FUNC_BT_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_BN_SCALE_SHORT
public static final float FUNC_BN_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_GT_SCALE_SHORT
public static final float FUNC_GT_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_PT_SCALE_SHORT
public static final float FUNC_PT_SCALE_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_THR_SCALE_BYTE
public static final float FUNC_THR_SCALE_BYTE
6 funcType of functional data have default scaling for byte data.- See Also:
- Constant Field Values
-
FUNC_COR_SCALE_BYTE
public static final float FUNC_COR_SCALE_BYTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_TT_SCALE_BYTE
public static final float FUNC_TT_SCALE_BYTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_ZT_SCALE_BYTE
public static final float FUNC_ZT_SCALE_BYTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_BT_SCALE_BYTE
public static final float FUNC_BT_SCALE_BYTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
FUNC_GT_SCALE_BYTE
public static final float FUNC_GT_SCALE_BYTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
MARKSET_ALIGN
public static final int MARKSET_ALIGN
marker types.- See Also:
- Constant Field Values
-
MARKSET_BOUNDING
public static final int MARKSET_BOUNDING
DOCUMENT ME!- See Also:
- Constant Field Values
-
WARP_AFFINE_TYPE
public static final int WARP_AFFINE_TYPE
warp types.- See Also:
- Constant Field Values
-
WARP_TALAIRACH_12_TYPE
public static final int WARP_TALAIRACH_12_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
UNITS_MSEC_TYPE
public static final int UNITS_MSEC_TYPE
time step units.- See Also:
- Constant Field Values
-
UNITS_SEC_TYPE
public static final int UNITS_SEC_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
UNITS_HZ_TYPE
public static final int UNITS_HZ_TYPE
DOCUMENT ME!- See Also:
- Constant Field Values
-
ATLAS_FRONT_TO_AC
private static final float ATLAS_FRONT_TO_AC
DOCUMENT ME!- See Also:
- Constant Field Values
-
ATLAS_PC_TO_BACK
private static final float ATLAS_PC_TO_BACK
DOCUMENT ME!- See Also:
- Constant Field Values
-
ATLAS_BOT_TO_AC
private static final float ATLAS_BOT_TO_AC
DOCUMENT ME!- See Also:
- Constant Field Values
-
ATLAS_AC_TO_TOP
private static final float ATLAS_AC_TO_TOP
DOCUMENT ME!- See Also:
- Constant Field Values
-
ATLAS_AC_TO_LAT
private static final float ATLAS_AC_TO_LAT
DOCUMENT ME!- See Also:
- Constant Field Values
-
acpcAC
private WildMagic.LibFoundation.Mathematics.Vector3f acpcAC
Anterior Comissure in acpc space.
-
acpcMaxPt
private WildMagic.LibFoundation.Mathematics.Vector3f acpcMaxPt
DOCUMENT ME!
-
acpcMinPt
private WildMagic.LibFoundation.Mathematics.Vector3f acpcMinPt
DOCUMENT ME!
-
acpcName
private java.lang.String acpcName
DOCUMENT ME!
-
acpcPC
private WildMagic.LibFoundation.Mathematics.Vector3f acpcPC
DOCUMENT ME!
-
acpcRes
private float acpcRes
DOCUMENT ME!
-
acquisitionDuration
private float acquisitionDuration
DOCUMENT ME!
-
alsoAcpc
private boolean alsoAcpc
DOCUMENT ME!
-
alsoOrig
private boolean alsoOrig
DOCUMENT ME!
-
anatomyParentnameString
private java.lang.String anatomyParentnameString
DOCUMENT ME!
-
anatType
private boolean anatType
DOCUMENT ME!
-
anotherPtDicom
private WildMagic.LibFoundation.Mathematics.Vector3f anotherPtDicom
DOCUMENT ME!
-
brickFloatFacs
private float[] brickFloatFacs
DOCUMENT ME!
-
brickKeywordsString
private java.lang.String brickKeywordsString
DOCUMENT ME!
-
brickLabsString
private java.lang.String[] brickLabsString
Sub-brick names
-
brickStatAux
private float[] brickStatAux
Each BLT is defined by a struct that contains two 3x3 matrices and four 3-vectors (2*3*3 + 4*3 = the 30 numbers). These values are: [mfor] = 3x3 forward transformation matrix [0..8] 0,1,2 correspond to alpha.X, alpha.Y, alpha.Z 3,4,5 correspond to beta.X, beta.Y, beta.Z 6,7,8 correspond to gamma.X, gamma.Y, gamma.Z [mbac] = 3x3 backward transformation matrix [0..17] [bvec] = 3-vector for forward transformation [18..20] [svec] = 3-vector for backward transformation [21..23] [bot] [24..26] [top] [27..29] The matrices are stored in row major order; e.g., [ 0 1 2] [mfor] = [ 3 4 5] [ 6 7 8] the indices of the [mfor] matrix The forward transformation is [x_map] = [mfor][x_in] - [bvec] The backward transformation is [x_in] = [mbac][x_map] - [svec] which implies [svec] = -[mbac][bvec] and [mbac] = Inverse{[mfor]} The forward transformation is the transformation of Dicom order coordinates from the warp parent dataset (usually in the +orig view) to the warped dataset (usually +acpc or +tlrc). The backward transformation is just the inverse of the forward transformation, and is stored for convenience. It could be recomputed from the forward transformation whenever it was needed. The identity BLT would be stored as these 30 numbers: 1 0 0 0 1 0 [mfor] = I 0 0 1 1 0 0 0 1 0 [mbac] = I 0 0 1 0 0 0 [bvec] = 0 0 0 0 [svec] = 0 botx boty botz topx topy topz bot and top numbers depend on the application. If the transformation is WARP_TALAIRACH_TYPE, then each BLT type only applies to a bounded region of 3-space. The [bot] and [top] vectors define the limits for each BLT, in the warped [x_map] coordinates. These values are used in the function AFNI_transform_vector() to compute the transformation of a 3-vector between +orig and +tlrc coordinates. For example, to compute the transformation from +tlrc back to +orig of a vector [x_tlrc], the code must scan all 12 [bot]..[top] regions to see which BLT to use. Similarly, to transform [x_orig] from +orig to +tlrc, the vector must be transformed with each BLT and the result tested to see if it lies within the BLT's [bot]..[top] region. (if a lower bound is supposed to be -infinity, then that element of [bot] is -9999; if an upper bound is supposed to be +infinity then that element of [top] is +9999. For the +orig to +acpc transformation (of WARP_AFFINE_TYPE), the [bot] and [top] vectors store the bounding box of the transformed dataset. However, this fact isn't used much.
-
brickStats
private float[] brickStats
DOCUMENT ME!
-
brickType
private int brickType
DOCUMENT ME!
-
brickTypeNumber
private int brickTypeNumber
DOCUMENT ME!
-
brikDataType
private int brikDataType
DOCUMENT ME!
-
brikFileName
private java.lang.String brikFileName
DOCUMENT ME!
-
bufferSize
private int bufferSize
DOCUMENT ME!
-
dataExtents
private int[] dataExtents
DOCUMENT ME!
-
dataOrient
private int[] dataOrient
DOCUMENT ME!
-
datasetKeywordsString
private java.lang.String datasetKeywordsString
DOCUMENT ME!
-
datasetNameString
private java.lang.String datasetNameString
DOCUMENT ME!
-
ddof
private int ddof
DOCUMENT ME!
-
delta
private float[] delta
DOCUMENT ME!
-
dicomDelta
private float[] dicomDelta
DOCUMENT ME!
-
dicomHighestX
private float dicomHighestX
DOCUMENT ME!
-
dicomHighestY
private float dicomHighestY
DOCUMENT ME!
-
dicomHighestZ
private float dicomHighestZ
DOCUMENT ME!
-
dicomLowestX
private float dicomLowestX
Dicom ordered bounding box in mm.
-
dicomLowestY
private float dicomLowestY
Dicom ordered bounding box in mm.
-
dicomLowestZ
private float dicomLowestZ
Dicom ordered bounding box in mm.
-
dicomOrientation
private int[] dicomOrientation
DOCUMENT ME!
-
dicomOrigin
private float[] dicomOrigin
DOCUMENT ME!
-
dicomSliceSize
private int dicomSliceSize
DOCUMENT ME!
-
dicomXDim
private int dicomXDim
DOCUMENT ME!
-
dicomYDim
private int dicomYDim
DOCUMENT ME!
-
dicomZDim
private int dicomZDim
DOCUMENT ME!
-
dist_ant
private float dist_ant
DOCUMENT ME!
-
dist_med
private float dist_med
DOCUMENT ME!
-
dist_pos
private float dist_pos
DOCUMENT ME!
-
dist_sup
private float dist_sup
DOCUMENT ME!
-
dist_inf
private float dist_inf
DOCUMENT ME!
-
dist_lef
private float dist_lef
DOCUMENT ME!
-
dist_rig
private float dist_rig
DOCUMENT ME!
-
doDicom
private boolean doDicom
DOCUMENT ME!
-
dof
private int dof
FUNC_TT_TYPE Student t Degrees-of-Freedom (DOF).
-
endianess
private boolean endianess
DOCUMENT ME!
-
file
private java.io.File file
DOCUMENT ME!
-
fileDir
private java.lang.String fileDir
DOCUMENT ME!
-
fileInfo
private FileInfoAfni fileInfo
DOCUMENT ME!
-
fileInfoCopy
private FileInfoAfni fileInfoCopy
-
fileLength
private long fileLength
DOCUMENT ME!
-
fileName
private java.lang.String fileName
DOCUMENT ME!
-
firstPtDicom
private WildMagic.LibFoundation.Mathematics.Vector3f firstPtDicom
DOCUMENT ME!
-
floatsPerTag
private int floatsPerTag
DOCUMENT ME!
-
funcType
private int funcType
DOCUMENT ME!
-
haveReadACPC
private boolean haveReadACPC
DOCUMENT ME!
-
haveReadOrig
private boolean haveReadOrig
DOCUMENT ME!
-
historyNoteString
private java.lang.String historyNoteString
DOCUMENT ME!
-
idcodeAnatParentString
private java.lang.String idcodeAnatParentString
DOCUMENT ME!
-
idcodeDateString
private java.lang.String idcodeDateString
DOCUMENT ME!
-
idcodeString
private java.lang.String idcodeString
DOCUMENT ME!
-
idcodeWarpParentString
private java.lang.String idcodeWarpParentString
DOCUMENT ME!
-
image
private ModelImage image
DOCUMENT ME!
-
img2Buffer
private float[] img2Buffer
DOCUMENT ME!
-
imgBuffer
private float[] imgBuffer
DOCUMENT ME!
-
imgExtents
private int[] imgExtents
DOCUMENT ME!
-
imgResols
private float[] imgResols
DOCUMENT ME!
-
invertX
private boolean invertX
DOCUMENT ME!
-
invertY
private boolean invertY
DOCUMENT ME!
-
invertZ
private boolean invertZ
DOCUMENT ME!
-
label1String
private java.lang.String label1String
DOCUMENT ME!
-
label2String
private java.lang.String label2String
DOCUMENT ME!
-
loadB
private boolean loadB
DOCUMENT ME!
-
lowestX
private float lowestX
Dataset ordered bounding box in mm.
-
lowestY
private float lowestY
Dataset ordered bounding box in mm.
-
lowestZ
private float lowestZ
Dataset ordered bounding box in mm.
-
highestX
private float highestX
Dataset ordered bounding box in mm.
-
highestY
private float highestY
Dataset ordered bounding box in mm.
-
highestZ
private float highestZ
Dataset ordered bounding box in mm.
-
marksFlag
private int marksFlag
DOCUMENT ME!
-
marksFlags
private int marksFlags
DOCUMENT ME!
-
marksHelpString
private java.lang.String[] marksHelpString
DOCUMENT ME!
-
marksLabString
private java.lang.String[] marksLabString
DOCUMENT ME!
-
marksXYZ
private float[] marksXYZ
DOCUMENT ME!
-
ndof
private int ndof
FUNC_FT_TYPE F ratio Numerator DOF, Denominator DOF.
-
noteDate001String
private java.lang.String noteDate001String
DOCUMENT ME!
-
noteDate002String
private java.lang.String noteDate002String
DOCUMENT ME!
-
noteDate003String
private java.lang.String noteDate003String
DOCUMENT ME!
-
noteDate004String
private java.lang.String noteDate004String
DOCUMENT ME!
-
noteDate005String
private java.lang.String noteDate005String
DOCUMENT ME!
-
noteNumber001String
private java.lang.String noteNumber001String
DOCUMENT ME!
-
noteNumber002String
private java.lang.String noteNumber002String
DOCUMENT ME!
-
noteNumber003String
private java.lang.String noteNumber003String
DOCUMENT ME!
-
noteNumber004String
private java.lang.String noteNumber004String
DOCUMENT ME!
-
noteNumber005String
private java.lang.String noteNumber005String
DOCUMENT ME!
-
notesCount
private int notesCount
DOCUMENT ME!
-
numberDicomSlices
private int numberDicomSlices
DOCUMENT ME!
-
numberSlices
private int numberSlices
DOCUMENT ME!
-
numFitParam
private int numFitParam
DOCUMENT ME!
-
numNuisanceParam
private int numNuisanceParam
DOCUMENT ME!
-
numSamples
private int numSamples
DOCUMENT ME!
-
numTrials
private int numTrials
FUNC_BN_TYPE Binomial # Trials, Probability per trial.
-
orientSpecific
private int[] orientSpecific
DOCUMENT ME!
-
origAC
private WildMagic.LibFoundation.Mathematics.Vector3f origAC
DOCUMENT ME!
-
origDelta
private float[] origDelta
DOCUMENT ME!
-
origDicom
private boolean origDicom
DOCUMENT ME!
-
origExtents
private int[] origExtents
DOCUMENT ME!
-
origin
private float[] origin
DOCUMENT ME!
-
originalFileName
private java.lang.String originalFileName
DOCUMENT ME!
-
origName
private java.lang.String origName
DOCUMENT ME!
-
origOrigin
private float[] origOrigin
DOCUMENT ME!
-
origXDim
private int origXDim
DOCUMENT ME!
-
origYDim
private int origYDim
DOCUMENT ME!
-
origZDim
private int origZDim
DOCUMENT ME!
-
pcDicom
private WildMagic.LibFoundation.Mathematics.Vector3f pcDicom
DOCUMENT ME!
-
pointMarker
private WildMagic.LibFoundation.Mathematics.Vector3f pointMarker
DOCUMENT ME!
-
posteriorMarginDicom
private WildMagic.LibFoundation.Mathematics.Vector3f posteriorMarginDicom
DOCUMENT ME!
-
presentViewType
private int presentViewType
DOCUMENT ME!
-
readACPC
private boolean readACPC
DOCUMENT ME!
-
readTLRC
private boolean readTLRC
DOCUMENT ME!
-
scale_A
private float scale_A
DOCUMENT ME!
-
scale_M
private float scale_M
DOCUMENT ME!
-
scale_P
private float scale_P
DOCUMENT ME!
-
scale_S
private float scale_S
DOCUMENT ME!
-
scale_I
private float scale_I
DOCUMENT ME!
-
scale_L
private float scale_L
DOCUMENT ME!
-
scale_R
private float scale_R
DOCUMENT ME!
-
skip
private float[] skip
DOCUMENT ME!
-
sliceSize
private int sliceSize
DOCUMENT ME!
-
slicesWithTimeOffsets
private int slicesWithTimeOffsets
DOCUMENT ME!
-
statAux
private float[] statAux
# orts are nuisance parameters whose number is >= 1.
-
statCode
private int statCode
DOCUMENT ME!
-
subBrickIndex
private int subBrickIndex
DOCUMENT ME!
-
subBrickNumber
private int subBrickNumber
DOCUMENT ME!
-
superiorEdgeDicom
private WildMagic.LibFoundation.Mathematics.Vector3f superiorEdgeDicom
DOCUMENT ME!
-
tagAlignMatvec
private float[] tagAlignMatvec
The "p-values" for fico, fitt, and fizt datasets are 2-sided: that is, the value displayed by AFNI (below the slider) is the probability that the absolute value of such a deviate will exceed the threshold value on the slider. The "p-values" for the other types are 1-sided: that is, the value displayed by AFNI is the probability that the value of the deviate will exceed the threshold value. (Of course, these probabilities are computed under the appropriate null hypothesis, and assuming that the distributional model holds exactly. The latter assumption, in particular, is fairly dubious.) Registration attributes Note that the MATVEC attributes are transformations of Dicom-ordered coordinates, and so have to be permuted to transform dataset-ordered xyz-coordinates. The MATVEC attributes describe the transformation of coordinates from the input dataset to the output dataset in the form [xyz_out] = [mat] ([xyz_in] - [xyz_cen]) + [vec] + [xyz_cen] where [mat] is a 3x3 orthogonal matrix [vec] is a 3-vector [xyz_in] is the input vector [xyz_cen] is the center of rotation (usually the center of the dataset) [xyz_out] is the output vector Dicom coordinate order is used for these matrices and vectors, which means that they need to be permuted to dataset order for application
-
tagNumber
private int tagNumber
DOCUMENT ME!
-
tagsetFloats
private float[] tagsetFloats
DOCUMENT ME!
-
tagsetLabelsString
private java.lang.String tagsetLabelsString
2560 characters giving the help strings for the markers (256 chars per marker, EXACTLY, including the NULS).
-
tAxisOffsets
private float[] tAxisOffsets
DOCUMENT ME!
-
tDim
private int tDim
DOCUMENT ME!
-
timeOrigin
private float timeOrigin
DOCUMENT ME!
-
timeStep
private float timeStep
DOCUMENT ME!
-
timeStepUnit
private int timeStepUnit
DOCUMENT ME!
-
tInfo
private TalairachTransformInfo tInfo
DOCUMENT ME!
-
tlrcRes
private float[] tlrcRes
DOCUMENT ME!
-
typeString
private java.lang.String typeString
DOCUMENT ME!
-
typeStringType
private int typeStringType
DOCUMENT ME!
-
UI
private ViewUserInterface UI
DOCUMENT ME!
-
viewType
private int viewType
DOCUMENT ME!
-
volregBaseIdcodeString
private java.lang.String volregBaseIdcodeString
DOCUMENT ME!
-
volregBaseNameString
private java.lang.String volregBaseNameString
DOCUMENT ME!
-
volregCenterBase
private float[] volregCenterBase
DOCUMENT ME!
-
volregCenterOld
private float[] volregCenterOld
For sub-brick #xxxxxx (so a max of 999,999 sub-bricks can be used), this stores 12 numbers for the matrix-vector of transformation from 3dvolreg.
-
volregGridparentIdcodeString
private java.lang.String volregGridparentIdcodeString
DOCUMENT ME!
-
volregGridparentNameString
private java.lang.String volregGridparentNameString
DOCUMENT ME!
-
volregInputIdcodeString
private java.lang.String volregInputIdcodeString
DOCUMENT ME!
-
volregInputNameString
private java.lang.String volregInputNameString
DOCUMENT ME!
-
volregMatvec000000
private float[] volregMatvec000000
DOCUMENT ME!
-
volregMatvec000001
private float[] volregMatvec000001
DOCUMENT ME!
-
volregMatvec000002
private float[] volregMatvec000002
DOCUMENT ME!
-
volregMatvec000003
private float[] volregMatvec000003
DOCUMENT ME!
-
volregMatvec000004
private float[] volregMatvec000004
DOCUMENT ME!
-
volregMatvec000005
private float[] volregMatvec000005
DOCUMENT ME!
-
volregMatvec000006
private float[] volregMatvec000006
DOCUMENT ME!
-
volregMatvec000007
private float[] volregMatvec000007
DOCUMENT ME!
-
volregMatvec000008
private float[] volregMatvec000008
DOCUMENT ME!
-
volregMatvec000009
private float[] volregMatvec000009
DOCUMENT ME!
-
volregRotcomNum
private int volregRotcomNum
DOCUMENT ME!
-
volregRotparentIdcodeString
private java.lang.String volregRotparentIdcodeString
DOCUMENT ME!
-
volregRotparentNameString
private java.lang.String volregRotparentNameString
DOCUMENT ME!
-
warpData
private float[] warpData
DOCUMENT ME!
-
warpParentnameString
private java.lang.String warpParentnameString
DOCUMENT ME!
-
warpType
private int warpType
DOCUMENT ME!
-
xDim
private int xDim
DOCUMENT ME!
-
yDim
private int yDim
DOCUMENT ME!
-
zAxisOffset
private float zAxisOffset
DOCUMENT ME!
-
zAxisStep
private float zAxisStep
DOCUMENT ME!
-
zDim
private int zDim
DOCUMENT ME!
-
zeroPad
private int[] zeroPad
DOCUMENT ME!
-
-
Constructor Detail
-
FileAfni
public FileAfni(java.lang.String fileName, java.lang.String fileDir, boolean loadB, boolean doRead) throws java.io.IOExceptionAfni reader constructor.- Parameters:
fileName- file namefileDir- file directoryloadB- flag indicating if this is a B imagedoRead- whether class is created for reading afni file, or for writing- Throws:
java.io.IOException- if there is an error making the file
-
-
Method Detail
-
finalize
public void finalize()
Prepares this class for cleanup. Calls thefinalizemethod for existing elements, closes any open files and sets other elements tonull.
-
getFileInfo
public FileInfoBase getFileInfo()
getFileInfo - accessor that returns the file info.- Returns:
- FileInfoBase containing the file info
-
getImageBuffer
public float[] getImageBuffer()
getImageBuffer - accessor that returns the image buffer.- Returns:
- buffer of image.
-
readImage
public ModelImage readImage() throws java.io.IOException
readImage.- Returns:
- returns the image
- Throws:
java.io.IOException- if there is an error reading the file
-
setFileName
public void setFileName(java.lang.String fName)
setFileName - accessor to set the file name (used when reading TIFF multiFile).- Parameters:
fName- file name of image to read.
-
getModelLUT
public ModelLUT getModelLUT()
-
writeImage
public void writeImage(ModelImage image, FileWriteOptions options) throws java.io.IOException
Writes a AFNI format type image.- Parameters:
image- Image model of data to write.options- options such as starting and ending slices and times- Throws:
java.io.IOException- if there is an error writing the file
-
calcOriginalMarker
private void calcOriginalMarker(int markerNumber)
DOCUMENT ME!- Parameters:
markerNumber- DOCUMENT ME!
-
createOrderDialog
private void createOrderDialog()
DOCUMENT ME!
-
crossProduct
private WildMagic.LibFoundation.Mathematics.Vector3f crossProduct(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2)Finds crossproduct of two vectors.- Parameters:
pt1- First vector.pt2- Second vector- Returns:
- Cross product of pt1 and pt2.
-
dicomMarker
private WildMagic.LibFoundation.Mathematics.Vector3f dicomMarker(WildMagic.LibFoundation.Mathematics.Vector3f pMarker)
DOCUMENT ME!- Parameters:
pMarker- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
dist
private float dist(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2, float[] resol)DOCUMENT ME!- Parameters:
pt1- DOCUMENT ME!pt2- DOCUMENT ME!resol- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
dotProduct
private float dotProduct(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2)DOCUMENT ME!- Parameters:
pt1- DOCUMENT ME!pt2- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
makemmVector3f
private WildMagic.LibFoundation.Mathematics.Vector3f makemmVector3f(WildMagic.LibFoundation.Mathematics.Vector3f pt, float[] resol)DOCUMENT ME!- Parameters:
pt- DOCUMENT ME!resol- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
makeVoxelCoord3Df
private WildMagic.LibFoundation.Mathematics.Vector3f makeVoxelCoord3Df(WildMagic.LibFoundation.Mathematics.Vector3f pt, float[] resol)DOCUMENT ME!- Parameters:
pt- DOCUMENT ME!resol- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
norm
private WildMagic.LibFoundation.Mathematics.Vector3f norm(WildMagic.LibFoundation.Mathematics.Vector3f pt)
Finds the normal to the vector.- Parameters:
pt- Vector to find normal to.- Returns:
- Normal of pt.
-
readBuffer
public void readBuffer(int slice, float[] buffer, float scaleFact, int numRead) throws java.io.IOExceptionReads a slice of data at a time and stores the results in the buffer.- Parameters:
slice- offset into the file stored in the dataOffset arraybuffer- buffer where the info is storedscaleFact- if zero data unscaled, if > 0 data is scaled by scaleFactnumRead- DOCUMENT ME!- Throws:
java.io.IOException- if there is an error reading the file
-
readHeader
public boolean readHeader() throws java.io.IOExceptionReads AFNI header (.HEAD file)- Throws:
java.io.IOException- if there is an error reading the file
-
readImage2
private ModelImage readImage2() throws java.io.IOException
Reads AFNI image (.BRIK file)- Returns:
- Generated modelImage
- Throws:
java.io.IOException- data reading problem occured
-
readLine
private java.lang.String readLine() throws java.io.IOExceptionreadLine() - reads a line of the file and strips comments indicated by the # symbol.- Returns:
- the line read in
- Throws:
java.io.IOException- if there is an error reading the file
-
readXYZBuffer
public void readXYZBuffer(int slice, float[] buffer, float[] dicomBuffer, float scaleFact) throws java.io.IOExceptionReads a slice of data at a time and stores the results in the buffer.- Parameters:
slice- offset into the file stored in the dataOffset arraybuffer- buffer where the info is read intodicomBuffer- buffer into which the data is reorderedscaleFact- if zero data unscaled, if > 0 data is scaled by scaleFact- Throws:
java.io.IOException- if there is an error reading the file
-
removeWhiteSpace
private java.lang.String removeWhiteSpace(java.lang.String inString)
DOCUMENT ME!- Parameters:
inString- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
reposMarker
private void reposMarker(int markerNumber)
DOCUMENT ME!- Parameters:
markerNumber- DOCUMENT ME!
-
sclAdd
private WildMagic.LibFoundation.Mathematics.Vector3f sclAdd(float fa, WildMagic.LibFoundation.Mathematics.Vector3f a, float fb, WildMagic.LibFoundation.Mathematics.Vector3f b)scale and add two vectors.- Parameters:
fa- DOCUMENT ME!a- DOCUMENT ME!fb- DOCUMENT ME!b- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
sub
private WildMagic.LibFoundation.Mathematics.Vector3f sub(WildMagic.LibFoundation.Mathematics.Vector3f pt1, WildMagic.LibFoundation.Mathematics.Vector3f pt2)DOCUMENT ME!- Parameters:
pt1- DOCUMENT ME!pt2- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
transformACPCTrilinear
private void transformACPCTrilinear(float[] imgBuffer, TransMatrix xfrm, float iXres, float iYres, float iZres, int iXdim, int iYdim, int iZdim, float oXres, float oYres, float oZres, int oXdim, int oYdim, int oZdim)transformACPCTrilinear - transforms and resamples volume using trilinear interpolation.- Parameters:
imgBuffer- image arrayxfrm- transformation matrix to be appliediXres- DOCUMENT ME!iYres- DOCUMENT ME!iZres- DOCUMENT ME!iXdim- DOCUMENT ME!iYdim- DOCUMENT ME!iZdim- DOCUMENT ME!oXres- DOCUMENT ME!oYres- DOCUMENT ME!oZres- DOCUMENT ME!oXdim- DOCUMENT ME!oYdim- DOCUMENT ME!oZdim- DOCUMENT ME!
-
transformTalairachTrilinear
private void transformTalairachTrilinear(float[] imgBuffer, TransMatrix xfrm, float iXres, float iYres, float iZres, int iXdim, int iYdim, int iZdim, float oXres, float oYres, float oZres, int oXdim, int botX, int botY, int botZ, int topX, int topY, int topZ)transformTalairachTrilinear - transforms and resamples volume using trilinear interpolation.- Parameters:
imgBuffer- image arrayxfrm- transformation matrix to be appliediXres- DOCUMENT ME!iYres- DOCUMENT ME!iZres- DOCUMENT ME!iXdim- DOCUMENT ME!iYdim- DOCUMENT ME!iZdim- DOCUMENT ME!oXres- DOCUMENT ME!oYres- DOCUMENT ME!oZres- DOCUMENT ME!oXdim- DOCUMENT ME!botX- DOCUMENT ME!botY- DOCUMENT ME!botZ- DOCUMENT ME!topX- DOCUMENT ME!topY- DOCUMENT ME!topZ- DOCUMENT ME!
-
-