open-discussion > clut file appears limited to only 255 regions
Showing 1-2 of 2 posts
Apr 7, 2023 11:04 PM | Oren Poliva
clut file appears limited to only 255 regions
Hello, I'm trying to create an atlas with 369 regions. However,
when I create a clut file with more than 256 regions, the regions
shift to different grey values (no color). When I use only 255
regions, the colors are presented correctly (with regions value
higher than 255 getting the final color). Is there a way around
this problem?
Thank you very much for your incredible program
Oren Poliva, PhD
Thank you very much for your incredible program
Oren Poliva, PhD
Apr 9, 2023 03:04 PM | Chris Rorden
RE: clut file appears limited to only 255 regions
Hello
Here is an example of the inia19 template with 1004 regions:
https://drive.google.com/file/d/1gszmKmx...
Make sure your datatype is INT16: regions should be discrete integers, not continuous floating point. You can use fslmaths to change your datatype. Make sure the Intention is "Label" (with MRIcroGL, Options -> ShowHeader, statistics tab) and Image Intensity Slope and intercept are 1 and 0 respectively (Image Intensity tab).
data_type INT16
scl_slope 1.000000
scl_inter 0.000000
intent Label index
intent_code 1002
Make sure you have one line for each region in your text file, with the first value being the voxel intensity and the second being the region name
1 l_occipital_gyrus_(macaque) 47 129 147 255
2 l_occipital_white_matter 155 241 247 255
3 l_lingual_gyrus 243 105 83 255
4 l_cuneus 204 202 52 255
5 l_inferior_occipital_gyrus 90 247 83 255
6 l_annectant_gyrus_(macaque) 191 196 209 255
....
Here is an example of the inia19 template with 1004 regions:
https://drive.google.com/file/d/1gszmKmx...
Make sure your datatype is INT16: regions should be discrete integers, not continuous floating point. You can use fslmaths to change your datatype. Make sure the Intention is "Label" (with MRIcroGL, Options -> ShowHeader, statistics tab) and Image Intensity Slope and intercept are 1 and 0 respectively (Image Intensity tab).
data_type INT16
scl_slope 1.000000
scl_inter 0.000000
intent Label index
intent_code 1002
Make sure you have one line for each region in your text file, with the first value being the voxel intensity and the second being the region name
1 l_occipital_gyrus_(macaque) 47 129 147 255
2 l_occipital_white_matter 155 241 247 255
3 l_lingual_gyrus 243 105 83 255
4 l_cuneus 204 202 52 255
5 l_inferior_occipital_gyrus 90 247 83 255
6 l_annectant_gyrus_(macaque) 191 196 209 255
....