help > Tissue Segmentation Input/Tissue Segmentation Atlas directory
Showing 1-25 of 30 posts
Display:
Results per page:

1   2   Next >
Jun 18, 2020  04:06 PM | Alex Brown
Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi,

Could you provide clarity as to what input is needed for:


the tissue segmentation atlas directory?
If I use Auto_EACSF for segmentation, what files do I need to include in the tissue segmentation atlas? (I am using adult brains so will need to provide my own files).



tissue segmentation (optional) input?
I have run my subject through SPM12 tissue segmentation, but am not sure which file to choose as the input.


Thanks!
Alex
Jun 18, 2020  06:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hello, 

Here is a resource with different type of atlas you could use https://www.nitrc.org/projects/unc_brain...

The latest version is UNC_Adult_Brain_Atlas_2 rev1 



Best,
Jun 18, 2020  07:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Thank you, Juan.

I registered my brainmask to my T1 and utilized the UNC adult atlas as my tissue segmentation directory. Everything ran smoothly until this error:


"Failed opening /home/bic/Desktop/UNC_atlas_trial/ABC_Segmentation/T1_to_template_EMS.affine

terminate called after throwing an instance of 'itk::ImageFileReaderException'
what(): /work/jprieto/source/auto_EACSF-build/ITKv4-install/include/ITK-4.13/itkImageFileReader.hxx:143:
Could not create IO object for reading file /home/bic/Desktop/UNC_atlas_trial/FinalMasking/Partial_conComp_dil.nrrd
The file doesn't exist...."

attached is the error log. any help is greatly appreciated!

Thanks!
Alex
Attachment: errors_log.txt
Jun 18, 2020  08:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
The tissue segmentation step should be using the image in the SkullStripping directory. Which it should generate using the T1 input and the brain mask you provide. However, it seems that is using the T1 image to run the tissue segmentation. 

What outputs do you have in the 'ABC_Segmentation' directory, if you have any?

Thanks,
Jun 18, 2020  09:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Juan,

the outputs in my ABC_Segmentation directory are the following:
  • ABCparam.xml
  • EMS.log
  • EMS.xml
  • TissueSegmentationAtlas which has the following files in it
  • 1.mha
  • 2.mha
  • 3.mha
  • 4.mha
  • output_affine_transform.txt
  • output_affine_transform_inverse.h5
  • template.mha
  • template_affine.nrrd
  • template_to_T1_Affine.txt
  • template_to_T1_InverseWarp.nii.gz
  • template_to_T1_Warp.nii.gz



The T1_stripped.nrrd file is the lone file in the SkullStripping directory




Thanks!
Alex
Jun 18, 2020  09:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
It seems the tissue seg did not run.
Could you please take a peak at the ABCparam.xml file and the tissue_seg.py script? This one should be in the PythonScripts directory.
Jun 19, 2020  02:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Juan,

Attached is the ABCparam.xml

I am attaching the tissue_seg.py script in the following message.

Thanks!
Alex
Attachment: ABCparam.xml
Jun 19, 2020  02:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
tissue_seg.py script attached
Attachment: tissue_seg.py
Jun 19, 2020  05:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Thanks for all the feedback. 
The TissueSeg step should be using the "T1_stripped" image. I will release a new version with this fix. I'll let you know when it's ready.
Jun 19, 2020  05:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Awesome. Thank you for being so responsive & helpful!

-Alex
Jun 22, 2020  07:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Alex, 
Version 1.7.6 should fix this issue. 
Best,
Jun 23, 2020  02:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Juan,

After running the 1.7.6 version I got the same output files and same errors as in my previous post. However, in the ABCparam.xml the image used was the T1_stripped.nrrd instead of the original T1.nii.

Attached is the tissue_seg py script. It seems the T1_stripped_to_template_EMS.affine file isn't being generated.
Let me know If you need any additonal scripts/logs.

Thanks,
Alex
Attachment: tissue_seg.py
Jun 23, 2020  02:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
output log attached
Attachment: output_log.txt
Jun 23, 2020  02:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
error log
Attachment: errors_log.txt
Jun 23, 2020  03:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
It seems that ABCSegmentation is not running to completion for some reason. 
Could you try deleting the ABCSegmentation directory and running the tissue_seg.py script by itself?
Jun 23, 2020  03:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Yes I can try that.

Sorry, but I am not too familiar with executing python scripts. What would be the best way to run the tissue_seg.py script by itself?

Thanks,
Alex
Jun 23, 2020  03:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
In a terminal window, go to your output directory, go into the PythonScripts directory and type
python3 tissue_seg.py

Otherwise, in your output directory delete the 'ABC_Segmentation' directory and launch Auto_EACSF again. 

It will run start the execution and run the tissue_seg.py script for you. 

The tissue segmentation should use the skull stripped image, perform a registration with the adult atlas template and run the EMS algorithm.
Jun 23, 2020  05:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Juan,

attached is the terminal output from the executed tissue_seg script. Please let me know if you need any additonal information.

Thanks!
Alex
Jun 23, 2020  05:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Sorry my first attachment didn't work.
Jun 23, 2020  07:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Alex, 
Since you are providing only a T1 image, the ABC tissue segmentation should only run with that input, however, the current implementation expects a T2. I'll fix this and publish a new version shortly. 
Best,
Jun 23, 2020  08:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Version 1.7.7 is published now and fixes the issue when running ABC tissue segmentation algorithm with only T1 image as input.
Jun 25, 2020  03:06 PM | Alex Brown
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Juan,

The scripts ran to completion and produced output files! However, the coronal mask, and all the EMSPartial_Masking files are empty when I attempt to view them in Slicer. the MID0 files do have viewable output, but the mask is not cut at the ACPC (whole brainmask segmentation). Also, my volume summary value is "29".

The only error in the error log is the following:

 < Failed opening /home/bic/Desktop/1.7.7_output/ABC_Segmentation/T1_stripped_to_template_EMS.affine>


A few questions:

If I provide a brainmask, does it need to binary? the brainmask i provided was from freesurfer, which is not a binary mask.

If I do provide a brainmask, do I need to register/transform the brainmask to ACPC space first?

If I do not provide a brainmask I will need an adult skullstripping atlas. Does your team have any adult skullstripping atlases?

Thanks!
Alex
Jun 29, 2020  02:06 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Alex, 

The brain mask does not have to be binary, the algorithm takes non-zero values to perform the masking. However, since you are providing the mask, you need to make sure that it is registered to the ACPC space. This may be the source of error to the EMSPartial_masking being empty. 
As for the adult skull stripping atlas, we currently don't have one, you could still try with the 1yr old but I recommend to use T2 image as well. 

Best,
Jul 6, 2020  02:07 PM | Juan Prieto - NIRAL
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hi Alex, 

One more update. There is an adult atlas available for the reference alignment. You could try with it. To download it follow this link https://www.nitrc.org/docman/view.php/1322/156615/AdultAtlas_ICBM_152_2009a_sym.tar.gz
Or go to the documents section and you will see it listed in atlases.
Dec 28, 2020  10:12 PM | Chieh-En Tseng
RE: Tissue Segmentation Input/Tissue Segmentation Atlas directory
Hello,

I think I have a similar issue. The MID0 files have viewable outputs but not the EMS_withoutVent_Partial_CSF file or FINAL_QCistern file. The volume summary value is "28". I registered the images to be aligned to the ACPC line and the origin is at the AC (is this what ACPC space means?), I am using my own brainmask, the adult tissue segmentation atlas, and to remove the ventricles I'm using the one year old ventricle mask and T1 template. Is there anything that I should be doing differently to get a viewable output in FINAL_QCistern? I have also tried with my own ventricle mask and looked at the uploaded example as a reference but I still haven't been able to get the correct final output, I would really appreciate any guidance.

Here is a link to the FinalMasking folder and FINAL_QCistern files if you could have a look. https://drive.google.com/file/d/1CRu7RxD...

Thank you for your help!

Best wishes,
Jane

Originally posted by Alex Brown:
Hi Juan,

The scripts ran to completion and produced output files! However, the coronal mask, and all the EMSPartial_Masking files are empty when I attempt to view them in Slicer. the MID0 files do have viewable output, but the mask is not cut at the ACPC (whole brainmask segmentation). Also, my volume summary value is "29".

The only error in the error log is the following:

 < Failed opening /home/bic/Desktop/1.7.7_output/ABC_Segmentation/T1_stripped_to_template_EMS.affine>


A few questions:

If I provide a brainmask, does it need to binary? the brainmask i provided was from freesurfer, which is not a binary mask.

If I do provide a brainmask, do I need to register/transform the brainmask to ACPC space first?

If I do not provide a brainmask I will need an adult skullstripping atlas. Does your team have any adult skullstripping atlases?

Thanks!
Alex

1   2   Next >