Search This Blog

Friday, February 28, 2014

Liver DCDI model:  Obtained a very good fit, with all parameter values are now in the allowd physiological ranges.  However, the question remains why the Arterial Fraction is essentially a 0?  Does it have an explanation?
ROI to model, was made very small with the effort to exclude possible blood vessels.


Thursday, February 27, 2014

Rewriting the Liver DCDI fit procedure, so the Amoeba optimization is performed many times from various starts in the grid, instead of a single start.
Implemented variant of Amoeba-local optimization that is guaranteed to stay within User-specified parameter bounds.  Applied it to the problematic liver case from Hersh. However, the obtained fit is not as good as for other cases, so continue the work on more efficient optimization procedure.  Here is current best result:


Further investigation of the fitting problems on Hersh's example:  very good fit is found by Amoeba,  but the best value is found is outside the acceptable physical range of parameters (f.e. the Arterial fraction is negative).  So clearly the Optimization procedure has to change in some way.  Investigations to continue.


Wednesday, February 26, 2014

Investigating and fixing what most likely a defect in the fitting of the DCDI model.  Issue is that two curves below, one with obviously worse fit is presently returned with the smaller residual.

Tuesday, February 25, 2014

Further optimized the search of the required precision of variables before Amoeba optimization.  This is relevant to all optimizations using Amoeba.  It was initiated in the context of Liver registration which was sped up by another 5%.

Monday, February 24, 2014

Re-engineered the Reslicing linear interpolation function for Undirected gradients.  This is in all registrations, 3D and 4D, that use the URAL measure.

Wednesday, February 19, 2014

Constructing the QuickStart manual for Liver Dual Compartment Dual Input workflow.

FireVoxel Build 131 is released.

1. AutoFocus 3D\4D registrations: parallelization was removed from Finetune, in non-MI measures. This led to a 18% speed up on 4D liver registration on Hersh's data.
2. Reimplemented the principal  gradient matching procedure of Registration, using the AVX2 latest INTEL 256-bit instructions.
3. Achieved further improvement of speed in URAL-Registration core procedure (affects 3D\4D).  This was done by further usage INTEL AVX intrinsics (128-bit vectorization commands).
4. Modified the Run-length representation of  Gradient fields used in 3D\4D registration to make more efficient use of memory and allocating and individual buffer for each image line  instead of one large buffer for the whole image.  
5. Liver DCDI:  Added the quick reference menu item for "Applications>Liver DCDI>Modelling".  This brings up the parametric modelling dialog box with the appropriate model active.
6.  Raised the "Optimization depth" Model control parameter to 10.
7.  Corrected the output units of the Liver DCDI model.  This does not change the fit, but outputs correct numbers consistent with the Sourbron's paper
8. Parametric Models:  when the "Process ROI as a single TAC" mode is used, before the  fitting curve is displayed,  all the requested parameters are displayed in a separate dialog with the appropriate units.
Parametric Models:  when the "Process ROI as a single TAC" mode is used, before the  fitting curve is displayed,  all the requested parameters are displayed in a separate dialog with the appropriate units.

Corrected the output units of the Liver DCDI model.  This does not change the fit, but outputs correct numbers consistent with the Sourbron's paper.
Liver DCDI:  Added the quick reference menu item for "MainMenu>Applications>Liver DCDI>Modelling".  This brings up the parametric modelling dialog box with the appropriate model active.

Raised the "Optimization depth" Model control parameter to 10.

Monday, February 17, 2014

Modifying the Run-length representation of  Gradient fields used in 3D\4D registration to make more efficient use of memory and allocating and individual buffer for each image line  instead of one large buffer for the whole image.  This should substantially reduce stress on the memory allocation system.
Achieved further improvement of speed in URAL-Registration core procedure (affects 3D\4D).  This was done by further employin INTEL AVX intrinsics (128-bit vectorization commands).

Sunday, February 16, 2014

Reimplemented the principal  gradient matching procedure of Registration, using the AVX2 latest INTEL
256-bit instructions.   Intel C++ compiler was used.  However, the timings are exactly the same as for AVX (128-bit) implementations.

Friday, February 14, 2014

AutoFocus 3D\4D registrations:   in the Finetune part of the registrations, there were several parallelization levels built in, f.e a Parallel Amoeba.  However, running each thread in some scenarios, like liver registration, requires a lot of memory.  Also, except for Mutual Information, all other measures (incl URAL) are highly parallelized on the level of evaluating a single transform about the matching cost.

So parallelization was removed from Finetune, in non-MI measures. This led to a 18% speed up on 4D liver registration on Hersh's data.
FireVoxel Build 130A is released:

1. Fixed the crash, reported by Hersh: when Liver dataset is loaded, without ROI,   "Liver DCIDI>Register 4D" command crashes the application.
2. 4D Registration (Basic Candidate Construction stage):  Added the "time remaining" info displayed in real time in   min:sec format.
3. AutoFocus 4D Registration:  Re-engineered previous design that was creating a copy of the original 4D volume in memory, so it uses precisely half of the memory of the previous design.
4. Improved User Interface of the "Blood Vessel Segmenter" function specific for DCE.  User is NOT required any longer to scroll in time to the timepoint of the desired vessel peak.
5. Implemented function to find the Peak timepoint of the volume over the specified Vector ROI.  Exposed this function under "MainMenu>Volume>AdvanceTo" submenu.

Thursday, February 13, 2014

Implemented function to find the Peak timepoint of the volume over the specified Vector ROI.  Exposed this function under "MainMenu>Volume>AdvanceTo" submenu.
Improved User Interface of the "Blood Vessel Segmenter" function specific for DCE.  User is NOT required any longer to scroll in time to the timepoint of the desired vessel peak.
Updating the Vessel Finder dialog box.
AutoFocus 4D Registration:  Re-engineered previous design that was creating a copy of the original 4D volume in memory, so it uses precisely half of the memory of the previous design.

Wednesday, February 12, 2014

4D Registration (Basic Candidate Construction stage):  Added the "time remaining" info displayed
in real time in   min:sec format.

Tuesday, February 11, 2014

Fixed the crash, reported by Hersh: when Liver dataset is loaded, without ROI,   "Liver DCIDI>Register 4D" command crashes the application.

Monday, February 10, 2014

FireVoxel Build 130 is released.



1. Corrected defect:   after IDIF is segmented, the TAC dialog pops up and now correctly displays the size of the vessel in (mm3) and appends it to the name of the vessel correctly.
2. Specifically for calculating distance of the fit of 2 curves that are sampled at highly uneven intervals:  Implemented the function for L2 integration based distance for two functions F(t) and G(t).  Perform exact integration of 2 piecewise linear functions.
3. Finalizing the parameter Dialog Box for the latest   Anatomy Constrained Input Function segmenter.
4. When a single seed is required and several seeds are present, Fvx requires a single seed to be selected and warns otherwise.
5. In all registrations, 3D and 4D,  implemented mechanism of tolerating the memory allocation failure. Now fully parallel version is ran,  the threads which failed are recorded into "Failed" thread array and then ran in serial mode.
6. Optimizing interface and performance of basic VolumeGetBox and VolumeSetBox procedures.  
7.Modifying User Interface objects due to a change of volume data primitives from 2D to 3D.

8. Updating the FVX file format.
9. Integrated  DCMTK-based DICOM header as a parallel structure to the existing TREE header design. 
10. Defect corrected: when drawing with the paintbrush  on ROIs, when paintbrush crosses the right border of the image the drawn voxels would appear sometimes at the top border.
11. Updated and restored .FVX format Load\Save due to a change in the basic volumetric entity data structure.
12. Finalized the Gamma Variate fit of the arbitrary function.  Introduced the "Fit" operation of the TAC inside the RoiStats4D dialog.
13.  Re-implementing the frequent {VolumeCropSlice, VolumeCropTimepoint} operations which are frequently used in processing.  Idea is to perform it through copying compressed blocks, 
14. Developed a function, when given a 4D volume and an ROI (3D or 4D),   FVX advances to timepoint where amount of information (or entropy) over the given ROI is maximum. 
15. Dialog "Split ROI by Threshold": Implemented a feature, so user is able to enter the desired threshold manually.
16. In preparation to release Build 130:  Restoring several parts of the Automatic Build Test that use the .FVX file format.
17. Implemented a support function, that in Play4D -  ALL the documents that have a compatible dynamic information will be played simultaneously
18. Implemented first fitting result for the Liver DCDI model (Sourbron).
19.  Liver DCDI model:
a) Fully parallelized the "Grid search" preceding the iterative Amoeba  (Simplex) optimization
b) Integrated the Parallel Amoeba variant
20.  Implemented derived parameters as per Sourbron's paper.
21.  Performing rearrangement of Sourbron's DCDI equation, moving to new
optimization variables:
22.  Updated the layout of the Dynamic Experiment\Parametric Map calculation dialog.  Added new relevant buttons.
23.  Defect Corrected:  When saving the TAC such as Input Function from ROIStats4D dialog box, the TAC name was improperly formatted and later incorrectly displayed inside the Parametric Models dialog.
24.  Converted all timing timing information to "Absolute times"  (starting Jan 1, 1900) for consistency and correctness.
25.  Layer Control Dialog\Load RAW.  Added the function so that the *.time files can be loaded.
26.  Layer Control Dialog\Load RAW.  Added the function so that the *.time files can be loaded.
27.  There is a substantial change in FireVoxel document format in Build 130.  Added the handling of cases when user tries to load an older version of the format and an appropriate message.
28.  Liver DCDI:  added automatic Build Test.
29.  AutoFocus 4D dialog box:  fixed the Slice Mode combo (drop down) box.

30.  Implemented a dedicated submenu with preset parameters for the "Liver DCDI" workflow.
Implemented a dedicated submenu with preset parameters for the "Liver DCDI" workflow.

Sunday, February 9, 2014

AutoFocus 4D dialog box:  fixed the Slice Mode combo (drop down) box.
Liver DCDI:  added automatic Build Test.
There is a substantial change in FireVoxel document format in Build 130.  Added the handling of cases when user tries to load an older version of the format and an appropriate message.
Layer Control Dialog\Load RAW.  Added the function so that the *.time files can be loaded.

Saturday, February 8, 2014

Fixing the design: In various part of the FireVoxel there is an inconsistent treatment of time values.  Certain structure hold time in "Absolute format" (i.e. seconds since Jan 1, 1900), other structures keeps them in seconds since the start of acquisitions.  This causes several glitches, f.e. during transfer of the Input function, from Automatic IDIF finder into Parametric Model calculation model.
Presently converting all the internal structure into the "Absolute format".  Relative times would only be constructed temporarily for specific purposes such as Display and during the Parametric Model calculations.

Friday, February 7, 2014

Defect Corrected:  When saving the TAC such as Input Function from ROIStats4D dialog box, the TAC name was improperly formatted and later incorrectly displayed inside the Parametric Models dialog.
Updated the layout of the Dynamic Experiment\Parametric Map calculation dialog.  Added new relevant buttons.


DCDI Liver mode: Performing yet another rearrangement of the variables.  Principal part is to have the S= ETS (extracellular transit speed) = 1/EMTT= (Fa+Fv+Ki)/Ve

Goal is the 100x times speed improvement during the Grid-search part of the optimization.  This can be achieved by using the ETS as the top variable of the nested loop. In that case all the exponential tables can
be precalculated once for each value of ETS.  Exponent calculations take about 99% of calculation time.

This is very relevant to plans to calculate the maps for the whole liver.

Thursday, February 6, 2014

Performing rearrangement of Sourbron's DCDI equation, moving to new
optimization variables:


1. ETR = Ve/(Fa+Fv),
2. F = (Fa+Fv) ,
3.  fa = Fa/(Fa+Fv),
4. H = Ki/(Fa+Fv)

This might have definite advantages, due to simplified parameter ranges.
ETR is closely related to EMTT (extracellular mean transit time) and is in [0,100] sec interval.
F  is the total Inflow.

fa and H are just coefficients and should be in [0,1] range.

This seems to be a definite improvement over the {Ve,Fa,Fv,Ki }  variable set where all 4 nontrivial
intervals are required.

Wednesday, February 5, 2014

Calculated the Hepatic Uptake rate (Ki) for 2 patients. This is a very early and preliminary result.  Both maps use the same color scale. The units of measurement are "1/100/min" as per Sourbron's paper.


Implemented derived parameters as per Sourbron's paper.
Primary optimization parameters are Fa,Fv,Ve,Ki.
So far there was no need for the "Arterial Delay" as Henry had foreseen.


Performed DCDI calculation for two patients LP and KA.  Below are the "Total Inflow" maps (=Fa+Fv).  Color mapping is using the same color scale (see color bar on the right)


Liver DCDI modelling function is fast enough to process large ROIs on the voxel-wise basis
Below is the parametric map Arterial Flow (Fa) in  "ml/min/100ml" units as in Sourbron's paper.
Total calculation time is about 3 sec.


Liver DCDI model: 
a) Fully parallelized the "Grid search" preceding the iterative Amoeba  (Simplex) optimization
b) Integrated the Parallel Amoeba variant
Obtained first fitting result for the Liver DCDI model (Sourbron).
In this example 2 input functions are shown in Signal intensity units.
The target ROI is in red.
Fitted Concentration Curve (black) is overlaid on top of the Data Concentration Curve.
Optimal parameter values are shown at the bottom of the diagram. They are normalized
to Sourbron's unit from the paper and on a quick comparison are of the same order of magnitude.
Note:  Arterial delay of "0" was used.



Running tests of the Liver DCDI model, debugging and targeting the visualization of the model fit as the next waypoint.

Monday, February 3, 2014

DCDI (Dual Compartment Dual Input) model:  Implementing a fitting model, within the FireVoxel Dynamic Framework...

Sunday, February 2, 2014

Implemented a support function, that in Play4D -  ALL the documents that have a compatible dynamic information will be played simultaneously.  This is very helpful for the displaying results of 4D registration,