External Email - Use Caution        

Thank you for looking into this, Yujing!  here's my stats dir:

$ ls -l /work/long/freesurfer_v5.3_DBIS/sub-0223_mprage/stats
total 77
-rwxrwxrwx. 1 ark19 root   972 Jun  3 17:03 lh.aparc.stats
-rwxrwxrwx. 1 ark19 root 49236 Jun  3 16:22 lh.curv.stats
-rw-rw-r--. 1 ark19 root  6606 Jun  3 17:03 lh.w-g.pct.stats

 FWIW I confirmed that I'm running the original version of recon-all 
(freesurfer-Linux-centos6_x86_64-stable-pub-v5.3.0 from 2013)
________________________________
From: freesurfer-boun...@nmr.mgh.harvard.edu 
<freesurfer-boun...@nmr.mgh.harvard.edu> on behalf of Huang, Yujing 
<yhuan...@mgh.harvard.edu>
Sent: Friday, June 2, 2023 4:23 PM
To: Freesurfer support list <freesurfer@nmr.mgh.harvard.edu>
Subject: Re: [Freesurfer] Troubleshooting "could not open file" errors in FS 5.3


        External Email - Use Caution

I followed 5.3 recon-all a little bit. rh will be processed after lh. Your 
recon-all stopped while it was still processing lh.



The error 
‘MRISread(/work/long/freesurfer_v5.3_DBIS/sub-0223_mprage/surf/rh.white): could 
not open file’ happened when recon-all was doing Parcellation Stats lh:



mris_anatomical_stats -mgz -cortex ../label/lh.cortex.label -f 
../stats/lh.aparc.stats -b -a ../label/lh.aparc.annot -c 
../label/aparc.annot.ctab sub-0223_mprage lh white



I don’t understand why it tried to read rh.white while it was doing lh white.



I’m wondering maybe it was actually complaining about ../stats/lh.aparc.stats.  
Can you do ‘ls -l’ of your stats directory?



Yujing







From: freesurfer-boun...@nmr.mgh.harvard.edu 
<freesurfer-boun...@nmr.mgh.harvard.edu> On Behalf Of Huang, Yujing
Sent: Friday, June 2, 2023 3:31 PM
To: Freesurfer support list <freesurfer@nmr.mgh.harvard.edu>
Subject: Re: [Freesurfer] Troubleshooting "could not open file" errors in FS 5.3



        External Email - Use Caution

Hi Annchen,



It seems that recon-all only processed lh. By default, it should process both 
lh and rh. Original recon-all have this line ‘set hemilist = (lh rh);’ at the 
beginning of the script. Can you make sure the one you are running is the 
original?



Best,



Yujing



From: 
freesurfer-boun...@nmr.mgh.harvard.edu<mailto:freesurfer-boun...@nmr.mgh.harvard.edu>
 
<freesurfer-boun...@nmr.mgh.harvard.edu<mailto:freesurfer-boun...@nmr.mgh.harvard.edu>>
 On Behalf Of Annchen Knodt
Sent: Friday, June 2, 2023 2:53 PM
To: Freesurfer support list 
<freesurfer@nmr.mgh.harvard.edu<mailto:freesurfer@nmr.mgh.harvard.edu>>
Subject: Re: [Freesurfer] Troubleshooting "could not open file" errors in FS 5.3



        External Email - Use Caution

Hi Yujing,



Thanks so much for your response!  I tried copying 
$FREESURFER_HOME/subjects/fsaverage and 
$FREESURFER_HOME/subjects/${hemi}.EC_average to $SUBJECTS dir before running, 
and this time I ran with the original recon-all instead of the one that had 
been edited to remove links (recon-all_noLink).  I was sure this would solve 
the problem, but I ended up getting the same error:



Command:



/cifs/hariri-long/Scripts/Tools/FreeSurfer_v5.3/freesurfer/bin/recon-all -all 
-s sub-0223_mprage -openmp 1 -i 
/cifs/hariri-long/Studies/DBIS_P52/Imaging/sourcedata/sub-0223/anat/sub-0223_T1w.nii.gz



Error:



      MRISread(/work/long/freesurfer_v5.3_DBIS/sub-0223_mprage/surf/rh.white): 
could not open file



Did I need to copy them somewhere besides $SUBJECTS_DIR ?  I’m not seeing any 
“failed to create symbolic link” messages which I interpret as the script 
having found the files and not need to run the ‘ln -s’ commands.



Attaching the log file from this latest run.



Thanks!



Annchen





From: 
freesurfer-boun...@nmr.mgh.harvard.edu<mailto:freesurfer-boun...@nmr.mgh.harvard.edu>
 
<freesurfer-boun...@nmr.mgh.harvard.edu<mailto:freesurfer-boun...@nmr.mgh.harvard.edu>>
 on behalf of Huang, Yujing 
<yhuan...@mgh.harvard.edu<mailto:yhuan...@mgh.harvard.edu>>
Date: Thursday, June 1, 2023 at 3:06 PM
To: Freesurfer support list 
<freesurfer@nmr.mgh.harvard.edu<mailto:freesurfer@nmr.mgh.harvard.edu>>
Subject: Re: [Freesurfer] Troubleshooting "could not open file" errors in FS 5.3

        External Email - Use Caution

Hi Annchen,



Your cp commands are missing destination file operands, see the errors in 
recon-all.log.



ln -s $FREESURFER_HOME/subjects/fsaverage and ln -s 
$FREESURFER_HOME/subjects/${hemi}.EC_average create symbolic links to 
directory. You will have to copy those two directories for your subject. I 
think if you copy them before recon-all, it won’t go through the codes to 
create the link.



Best,



Yujing





From: 
freesurfer-boun...@nmr.mgh.harvard.edu<mailto:freesurfer-boun...@nmr.mgh.harvard.edu>
 
<freesurfer-boun...@nmr.mgh.harvard.edu<mailto:freesurfer-boun...@nmr.mgh.harvard.edu>>
 On Behalf Of Annchen Knodt
Sent: Thursday, June 1, 2023 2:10 PM
To: freesurfer@nmr.mgh.harvard.edu<mailto:freesurfer@nmr.mgh.harvard.edu>
Subject: [Freesurfer] Troubleshooting "could not open file" errors in FS 5.3



        External Email - Use Caution

Hello,



I'm trying to run freesurfer v5.3 recon-all and running into an error I'm not 
sure how to troubleshoot.  I'm using essentially the same commands that i've 
successfully used to run version 6.0 recently, and that i've also successfully 
run 5.3 with in the past.



On my first pass, I attempted to run this full recon-all command:



/cifs/hariri-long/Scripts/Tools/FreeSurfer_v5.3/freesurfer/bin/recon-all_noLink 
-all -s sub-0223_mprage -openmp 1 -i 
/cifs/hariri-long/Studies/DBIS_P52/Imaging/sourcedata/sub-0223/anat/sub-0223_T1w.nii.gz



And eventually got the error:



      MRISread(/work/long/freesurfer_v5.3_DBIS/sub-0223_mprage/surf/rh.white): 
could not open file



Lots of lh surf files were produced as well as 3 of the lh stats files (aparc, 
curv, w-g), but nothing for rh, and I could not find the rh.white file.  I then 
tried running rh using:



/cifs/hariri-long/Scripts/Tools/FreeSurfer_v5.3/freesurfer/bin/recon-all_noLink 
-all -s sub-0223_mprage -openmp 1 -hemi rh



And eventually got the error:



      
MRISread(/work/long/freesurfer_v5.3_DBIS/rh.EC_average/surf/rh.sphere.reg): 
could not open file



One thing that seems weird about the second error is that it is looking in 
$SUBJECTS_DIR instead of $SUBJECTS_DIR/<subject> for the rh.sphere file, when 
the file does exist in $SUBJECTS_DIR/<subject>/surf (but not the top dir where 
it's looking)



Also wanted to note that i'm running this a slightly tweaked version to remove 
symlinks which aren't allowed on the cluster i'm working on (which is running 
CentOS 8):



$ diff 
/cifs/hariri-long/Scripts/Tools/FreeSurfer_v5.3/freesurfer/bin/recon-all_noLink 
/cifs/hariri-long/Scripts/Tools/FreeSurfer_v5.3/freesurfer/bin/recon-all

3447c3447

<           cp $subj1 ${diffsubj}_tmp

---

>           ln -s $subj1 ${diffsubj}_tmp

3753c3753

<     cp $subj1 ${diffsubj}_tmp

---

>     ln -s $subj1 ${diffsubj}_tmp

3911c3911

<         set cmd=(cp $FREESURFER_HOME/subjects/fsaverage)

---

>         set cmd=(ln -s $FREESURFER_HOME/subjects/fsaverage)

4028c4028

<       set cmd=(cp $FREESURFER_HOME/subjects/fsaverage)

---

>       set cmd=(ln -s $FREESURFER_HOME/subjects/fsaverage)

4157c4157

<       set cmd=(cp $FREESURFER_HOME/subjects/${hemi}.EC_average)

---

>       set cmd=(ln -s $FREESURFER_HOME/subjects/${hemi}.EC_average)



Any tips on how I can troubleshoot this?  Attaching recon-all.log file.  
Thanks!!



Annchen






_______________________________________________
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
The information in this e-mail is intended only for the person to whom it is 
addressed.  If you believe this e-mail was sent to you in error and the e-mail 
contains patient information, please contact the Mass General Brigham 
Compliance HelpLine at https://www.massgeneralbrigham.org/complianceline 
<https://www.massgeneralbrigham.org/complianceline> .
Please note that this e-mail is not secure (encrypted).  If you do not wish to 
continue communication over unencrypted e-mail, please notify the sender of 
this message immediately.  Continuing to send or respond to e-mail after 
receiving this message means you understand and accept this risk and wish to 
continue to communicate over unencrypted e-mail. 

Reply via email to