[Gate-users] analyze image using the error.!!

Javier Ors Anía Javier.Ors at ific.uv.es
Thu Sep 23 15:32:27 CEST 2010


Hi, I haven't tested this, but I think that your problem *maybe* could
be solved by making the following small changes in the code: in the file
source/geometry/src/GateVImageVolume.cc, locate the following lines:

    pImage->SetOutsideValue(  tmp->GetMinValue() - 1 );
...
    pImage->SetOutsideValue(  pImage->GetMinValue() - 1 );
...
  mHounsfieldMaterialTable.AddMaterial(pImage->GetOutsideValue(),
pImage->GetOutsideValue()+1,"worldDefaultAir");

And change them, respectively, to:

    pImage->SetOutsideValue(  tmp->GetMinValue() - 1.0 );
...
    pImage->SetOutsideValue(  pImage->GetMinValue() - 1.0 );
...
  mHounsfieldMaterialTable.AddMaterial(pImage->GetOutsideValue(),
pImage->GetOutsideValue()+1.0,"worldDefaultAir");

(Just adding .0 to the +1 -1 operands)

Then re-compile and try again. Please tell us if it works.

El jue, 23-09-2010 a las 20:03 +0900, jongskull escribió:
> Hello all,
> 
> I would like to insert a CT image for radiotherapie
> Another way to use 3D images is available in GATE.
> To insert an image you may use the following commands:
> 
> /gate/world/daughters/name                      patient
> /gate/world/daughters/insert                    ImageNestedParametrisedVolume
> /gate/patient/geometry/SetImage                 data/patient1.hdr
> /gate/geometry/setMaterialDatabase              data/Humaterials.db
> /gate/patient/geometry/SetHUToMaterialFile      data/Hu2mat.txt
> 
> To generate a correspondence between HU (voxel values) and material, you may use the following commands:
> 
> /gate/HounsfieldMaterialGenerator/SetMaterialTable                  data/Schneider2000MaterialsTable.txt 
> /gate/HounsfieldMaterialGenerator/SetDensityTable                   data/mySchneider2000DensitiesTable.txt
> /gate/HounsfieldMaterialGenerator/SetDensityTolerance               0.1 g/cm3
> /gate/HounsfieldMaterialGenerator/SetOutputMaterialDatabaseFilename data/HUmaterials.db
> /gate/HounsfieldMaterialGenerator/SetOutputHUMaterialFilename       data/HU2mat.txt
> /gate/HounsfieldMaterialGenerator/Generate
> 
> Moreover I've check up that the format of my image was well in "analyze 7.5" (I make imageJ ).
> 
> However, when I run GATE, I've got this kind of error 
> src/GateHounsfieldMaterialTable.cc (l.129): Current H1=-1050 is different from previous H2=-32768. Abort.
> 
> I already have the patch_2107.tar.... and Example1 is a well rum....
> It's seems this error comes from to CT calibration test file " Schneider2000MaterialTable.txt, Schneider2000DensitiesTable.txt"
> 
> Have you got any idea to solve this problem ?
> Thanks.
> 
> Best regards,
> 
> ------------------------------------------
> Jongwon  Kim
> Plan Room. Dept. Proton Therapy Center
> National Cancer Center.
> Office  : 82)+31-920-0132
> Mobile : 82)+11-9017-3889
> E-mail : jongskull at gmail.com
> ------------------------------------------
> 
> _______________________________________________
> Gate-users mailing list
> Gate-users at lists.opengatecollaboration.org
> http://lists.opengatecollaboration.org/mailman/listinfo/gate-users




More information about the Gate-users mailing list