External Email - Use Caution
Hi Freesurfer team
I am trying to convert parcellation (cortical) volumes that I acquired through another platform into surface labels using freesurfer. I tried following code to convert the volume with ID 20 from the parcellationvolumes.nii.gz file into a label
mri_cor2label --i dir/parcellationvolumes.nii.gz --id 20 --l dir/20.label
Although the code runs fine and finishes successfully, whenever I try to open the created label in freeview, it says that the label is empty.
Any idea what I am doing wrong? Do you have an easier way to project all ROI volumes onto the surface?
A second related question: I have run the recon-all for T1 of the subject and it creates rh.pial and lh.pial. I was wondering whether the transformation to go from T1 volume to the surface is saved somewhere and whether I can apply this transformation to convert my cortical volume parcellations into surface parcellations?
Thank you for your help! Best regards Julie
That will create a volume label, not a surface label (but it should not have been empty -- look in the label (it is just a text file)). To get a surface label, first map the volume to the surface with something like mri_vol2surf --mov parcellationvolumes.nii.gz --projfrac-max -.5 1 .1 --hemi lh --o lh.parcellationvolumes.mgz --regheader subject mri_cor2label --i lh.parcellationvolumes.mgz --id 20 --surf subject lh --l lh.20.label
On 7/10/2020 3:46 PM, Julie Ottoy wrote:
External Email - Use Caution
Hi Freesurfer team
I am trying to convert parcellation (cortical) volumes that I acquired through another platform into surface labels using freesurfer. I tried following code to convert the volume with ID 20 from the parcellationvolumes.nii.gz file into a label
mri_cor2label --i dir/parcellationvolumes.nii.gz --id 20 --l dir/20.label
Although the code runs fine and finishes successfully, whenever I try to open the created label in freeview, it says that the label is empty.
Any idea what I am doing wrong? Do you have an easier way to project all ROI volumes onto the surface?
A second related question: I have run the recon-all for T1 of the subject and it creates rh.pial and lh.pial. I was wondering whether the transformation to go from T1 volume to the surface is saved somewhere and whether I can apply this transformation to convert my cortical volume parcellations into surface parcellations?
Thank you for your help! Best regards Julie
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
External Email - Use Caution
Thank you for your reply. It worked to convert to surface label :) When i overlay the surface labels on the pial surface, I can view a histogram showing the number of vertices versus the numbers of labels i have. As a follow-up question, do you know how I could extract a txt file that gives me the vertices with their corresponding label number. For example, for 10,000 vertices and 100 labels, I'd like to get a txt file with 10,000 rows and each row has a label value between 1 and 100.
Thank you for your help!
On Fri, 10 Jul 2020 at 16:28, Douglas N. Greve dgreve@mgh.harvard.edu wrote:
That will create a volume label, not a surface label (but it should not have been empty -- look in the label (it is just a text file)). To get a surface label, first map the volume to the surface with something like mri_vol2surf --mov parcellationvolumes.nii.gz --projfrac-max -.5 1 .1 --hemi lh --o lh.parcellationvolumes.mgz --regheader subject mri_cor2label --i lh.parcellationvolumes.mgz --id 20 --surf subject lh --l lh.20.label
On 7/10/2020 3:46 PM, Julie Ottoy wrote:
External Email - Use CautionHi Freesurfer team
I am trying to convert parcellation (cortical) volumes that I acquired through another platform into surface labels using freesurfer. I tried following code to convert the volume with ID 20 from the parcellationvolumes.nii.gz file into a label
mri_cor2label --i dir/parcellationvolumes.nii.gz --id 20 --l dir/20.label
Although the code runs fine and finishes successfully, whenever I try to open the created label in freeview, it says that the label is empty.
Any idea what I am doing wrong? Do you have an easier way to project all ROI volumes onto the surface?
A second related question: I have run the recon-all for T1 of the subject and it creates rh.pial and lh.pial. I was wondering whether the transformation to go from T1 volume to the surface is saved somewhere and whether I can apply this transformation to convert my cortical volume parcellations into surface parcellations?
Thank you for your help! Best regards Julie
Freesurfer mailing listFreesurfer@nmr.mgh.harvard.eduhttps://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
External Email - Use Caution
Hi FS team,
I was wondering if you could take a look at the question below. Thanks!
---------- Forwarded message --------- From: Julie Ottoy julie.jj.ottoy@gmail.com Date: Fri, 10 Jul 2020 at 20:49 Subject: Re: [Freesurfer] Fwd: question regarding mri_vol2label To: Freesurfer support list freesurfer@nmr.mgh.harvard.edu
Thank you for your reply. It worked to convert to surface label :) When i overlay the surface labels on the pial surface, I can view a histogram showing the number of vertices versus the numbers of labels i have. As a follow-up question, do you know how I could extract a txt file that gives me the vertices with their corresponding label number. For example, for 10,000 vertices and 100 labels, I'd like to get a txt file with 10,000 rows and each row has a label value between 1 and 100.
Thank you for your help!
On Fri, 10 Jul 2020 at 16:28, Douglas N. Greve dgreve@mgh.harvard.edu wrote:
That will create a volume label, not a surface label (but it should not have been empty -- look in the label (it is just a text file)). To get a surface label, first map the volume to the surface with something like mri_vol2surf --mov parcellationvolumes.nii.gz --projfrac-max -.5 1 .1 --hemi lh --o lh.parcellationvolumes.mgz --regheader subject mri_cor2label --i lh.parcellationvolumes.mgz --id 20 --surf subject lh --l lh.20.label
On 7/10/2020 3:46 PM, Julie Ottoy wrote:
External Email - Use CautionHi Freesurfer team
I am trying to convert parcellation (cortical) volumes that I acquired through another platform into surface labels using freesurfer. I tried following code to convert the volume with ID 20 from the parcellationvolumes.nii.gz file into a label
mri_cor2label --i dir/parcellationvolumes.nii.gz --id 20 --l dir/20.label
Although the code runs fine and finishes successfully, whenever I try to open the created label in freeview, it says that the label is empty.
Any idea what I am doing wrong? Do you have an easier way to project all ROI volumes onto the surface?
A second related question: I have run the recon-all for T1 of the subject and it creates rh.pial and lh.pial. I was wondering whether the transformation to go from T1 volume to the surface is saved somewhere and whether I can apply this transformation to convert my cortical volume parcellations into surface parcellations?
Thank you for your help! Best regards Julie
Freesurfer mailing listFreesurfer@nmr.mgh.harvard.eduhttps://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
External Email - Use Caution
There is no tool (I know of) which does exactly what you want, but it should be easy in Matlab or R.
So if I understand correctly you have several label files for one subject, and you want to apply all of them and get a single text file that should have one label per vertex of the subjects's surface. (Basically a text version of an anottation file, without the color lookup table.)
Two questions: 1) What value for vertices which were not matched by any label? 2) What should happen to vertices matched by more than one label?
Best,
Tim
-- Dr. Tim Schäfer Postdoc Computational Neuroimaging Department of Child and Adolescent Psychiatry, Psychosomatics and Psychotherapy University Hospital Frankfurt, Goethe University Frankfurt am Main, Germany
On July 17, 2020 at 4:59 PM Julie Ottoy julie.jj.ottoy@gmail.com wrote:
External Email - Use CautionHi FS team,
I was wondering if you could take a look at the question below. Thanks!
---------- Forwarded message --------- From: Julie Ottoy julie.jj.ottoy@gmail.com Date: Fri, 10 Jul 2020 at 20:49 Subject: Re: [Freesurfer] Fwd: question regarding mri_vol2label To: Freesurfer support list freesurfer@nmr.mgh.harvard.edu
Thank you for your reply. It worked to convert to surface label :) When i overlay the surface labels on the pial surface, I can view a histogram showing the number of vertices versus the numbers of labels i have. As a follow-up question, do you know how I could extract a txt file that gives me the vertices with their corresponding label number. For example, for 10,000 vertices and 100 labels, I'd like to get a txt file with 10,000 rows and each row has a label value between 1 and 100.
Thank you for your help!
On Fri, 10 Jul 2020 at 16:28, Douglas N. Greve dgreve@mgh.harvard.edu wrote:
That will create a volume label, not a surface label (but it should not have been empty -- look in the label (it is just a text file)). To get a surface label, first map the volume to the surface with something like mri_vol2surf --mov parcellationvolumes.nii.gz --projfrac-max -.5 1 .1 --hemi lh --o lh.parcellationvolumes.mgz --regheader subject mri_cor2label --i lh.parcellationvolumes.mgz --id 20 --surf subject lh --l lh.20.label
On 7/10/2020 3:46 PM, Julie Ottoy wrote:
External Email - Use CautionHi Freesurfer team
I am trying to convert parcellation (cortical) volumes that I acquired through another platform into surface labels using freesurfer. I tried following code to convert the volume with ID 20 from the parcellationvolumes.nii.gz file into a label
mri_cor2label --i dir/parcellationvolumes.nii.gz --id 20 --l dir/20.label
Although the code runs fine and finishes successfully, whenever I try to open the created label in freeview, it says that the label is empty.
Any idea what I am doing wrong? Do you have an easier way to project all ROI volumes onto the surface?
A second related question: I have run the recon-all for T1 of the subject and it creates rh.pial and lh.pial. I was wondering whether the transformation to go from T1 volume to the surface is saved somewhere and whether I can apply this transformation to convert my cortical volume parcellations into surface parcellations?
Thank you for your help! Best regards Julie
Freesurfer mailing listFreesurfer@nmr.mgh.harvard.eduhttps://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Hi Julie
I don’t think we have anything that will do this out-of-the-box, but it should be easy enough to do in matlab or python. The label files are a text format and we provide .m and .py files to read them. Alternatively you could combine all the labels into a single parcellation file /subject/hemi and read that in (but it is not a text format)
Cheers Bruce
From: freesurfer-bounces@nmr.mgh.harvard.edu freesurfer-bounces@nmr.mgh.harvard.edu On Behalf Of Julie Ottoy Sent: Friday, July 17, 2020 10:59 AM To: Freesurfer support list freesurfer@nmr.mgh.harvard.edu Subject: [Freesurfer] Fwd: Fwd: question regarding mri_vol2label
External Email - Use Caution Hi FS team,
I was wondering if you could take a look at the question below. Thanks!
---------- Forwarded message --------- From: Julie Ottoy <julie.jj.ottoy@gmail.commailto:julie.jj.ottoy@gmail.com> Date: Fri, 10 Jul 2020 at 20:49 Subject: Re: [Freesurfer] Fwd: question regarding mri_vol2label To: Freesurfer support list <freesurfer@nmr.mgh.harvard.edumailto:freesurfer@nmr.mgh.harvard.edu>
Thank you for your reply. It worked to convert to surface label :) When i overlay the surface labels on the pial surface, I can view a histogram showing the number of vertices versus the numbers of labels i have. As a follow-up question, do you know how I could extract a txt file that gives me the vertices with their corresponding label number. For example, for 10,000 vertices and 100 labels, I'd like to get a txt file with 10,000 rows and each row has a label value between 1 and 100.
Thank you for your help!
On Fri, 10 Jul 2020 at 16:28, Douglas N. Greve <dgreve@mgh.harvard.edumailto:dgreve@mgh.harvard.edu> wrote: That will create a volume label, not a surface label (but it should not have been empty -- look in the label (it is just a text file)). To get a surface label, first map the volume to the surface with something like mri_vol2surf --mov parcellationvolumes.nii.gz --projfrac-max -.5 1 .1 --hemi lh --o lh.parcellationvolumes.mgz --regheader subject mri_cor2label --i lh.parcellationvolumes.mgz --id 20 --surf subject lh --l lh.20.label
On 7/10/2020 3:46 PM, Julie Ottoy wrote:
External Email - Use Caution Hi Freesurfer team
I am trying to convert parcellation (cortical) volumes that I acquired through another platform into surface labels using freesurfer. I tried following code to convert the volume with ID 20 from the parcellationvolumes.nii.gz file into a label
mri_cor2label --i dir/parcellationvolumes.nii.gz --id 20 --l dir/20.label
Although the code runs fine and finishes successfully, whenever I try to open the created label in freeview, it says that the label is empty.
Any idea what I am doing wrong? Do you have an easier way to project all ROI volumes onto the surface?
A second related question: I have run the recon-all for T1 of the subject and it creates rh.pial and lh.pial. I was wondering whether the transformation to go from T1 volume to the surface is saved somewhere and whether I can apply this transformation to convert my cortical volume parcellations into surface parcellations?
Thank you for your help! Best regards Julie
_______________________________________________
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edumailto:Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
_______________________________________________ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edumailto:Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Try mri_convert parcellationvolumes.mgz --ascii parcellationvolumes.txt
On 7/10/2020 8:49 PM, Julie Ottoy wrote:
External Email - Use Caution
Thank you for your reply. It worked to convert to surface label :) When i overlay the surface labels on the pial surface, I can view a histogram showing the number of vertices versus the numbers of labels i have. As a follow-up question, do you know how I could extract a txt file that gives me the vertices with their corresponding label number. For example, for 10,000 vertices and 100 labels, I'd like to get a txt file with 10,000 rows and each row has a label value between 1 and 100.
Thank you for your help!
On Fri, 10 Jul 2020 at 16:28, Douglas N. Greve <dgreve@mgh.harvard.edu mailto:dgreve@mgh.harvard.edu> wrote:
That will create a volume label, not a surface label (but it should not have been empty -- look in the label (it is just a text file)). To get a surface label, first map the volume to the surface with something like mri_vol2surf --mov parcellationvolumes.nii.gz --projfrac-max -.5 1 .1 --hemi lh --o lh.parcellationvolumes.mgz --regheader subject mri_cor2label --i lh.parcellationvolumes.mgz --id 20 --surf subject lh --l lh.20.label On 7/10/2020 3:46 PM, Julie Ottoy wrote:External Email - Use Caution Hi Freesurfer team I am trying to convert parcellation (cortical) volumes that I acquired through another platform into surface labels using freesurfer. I tried following code to convert the volume with ID 20 from the parcellationvolumes.nii.gz file into a label mri_cor2label --i dir/parcellationvolumes.nii.gz --id 20 --l dir/20.label Although the code runs fine and finishes successfully, whenever I try to open the created label in freeview, it says that the label is empty. Any idea what I am doing wrong? Do you have an easier way to project all ROI volumes onto the surface? A second related question: I have run the recon-all for T1 of the subject and it creates rh.pial and lh.pial. I was wondering whether the transformation to go from T1 volume to the surface is saved somewhere and whether I can apply this transformation to convert my cortical volume parcellations into surface parcellations? Thank you for your help! Best regards Julie _______________________________________________ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu <mailto:Freesurfer@nmr.mgh.harvard.edu> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer_______________________________________________ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu <mailto:Freesurfer@nmr.mgh.harvard.edu> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
freesurfer@nmr.mgh.harvard.edu