Re: [HCP-Users] errors with HCP_Pipelines structural processing

2016-10-14 Thread Harms, Michael

The Freesurfer ‘recon-all’ script writes that message to ‘stdout’, not 
‘stderr’, thus it shows up in the *.o* file from your cluster management 
software, not the *.e* file.  i.e., you need to look at both to debug problems.

cheers,
-MH

--
Michael Harms, Ph.D.
---
Conte Center for the Neuroscience of Mental Disorders
Washington University School of Medicine
Department of Psychiatry, Box 8134
660 South Euclid Ave. Tel: 314-747-6173
St. Louis, MO  63110 Email: mha...@wustl.edu

From: YC Yao mailto:yao_yongch...@icloud.com>>
Date: Friday, October 14, 2016 at 10:57 AM
To: Michael Harms mailto:mha...@wustl.edu>>
Cc: "hcp-users@humanconnectome.org<mailto:hcp-users@humanconnectome.org>" 
mailto:hcp-users@humanconnectome.org>>
Subject: Re: [HCP-Users] errors with HCP_Pipelines structural processing

Thank you for your prompt replay!

I noticed that “error” message before, but it resides  in 
FreeSurferPipeline.sh.o23511 which is the output logging file but not in 
FreeSurferPipeline.sh.e23511 which is the error message file. Therefore, I 
assume that it will not do harm to the result.

I believe I have deleted all files except the unprocessed directory where the 
example data resided. I will try again later.

Thanks again!

Best regards,
YC Yao


The materials in this message are private and may contain Protected Healthcare 
Information or other information of a sensitive nature. If you are not the 
intended recipient, be advised that any unauthorized use, disclosure, copying 
or the taking of any action in reliance on the contents of this information is 
strictly prohibited. If you have received this email in error, please 
immediately notify the sender via telephone or return mail.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] errors with HCP_Pipelines structural processing

2016-10-14 Thread YC Yao
Thank you for your prompt replay!

I noticed that “error” message before, but it resides  in 
FreeSurferPipeline.sh.o23511 which is the output logging file but not in 
FreeSurferPipeline.sh.e23511 which is the error message file. Therefore, I 
assume that it will not do harm to the result.

I believe I have deleted all files except the unprocessed directory where the 
example data resided. I will try again later.

Thanks again!

Best regards,
YC Yao
___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] errors with HCP_Pipelines structural processing

2016-10-14 Thread Harms, Michael

It sounds like FreeSurfer didn’t run properly.  The end of your 
FreeSurferPipeline.sh.o23511 file states:

ERROR: You are trying to re-run an existing subject with (possibly)
 new input data (-i). If this is truly new input data, you should delete
 the subject folder and re-run, or specify a different subject name.
 If you are just continuing an analysis of an existing subject, then
 omit all -i flags.

Are you sure that you deleted all the files from your previous attempt, because 
the message above indicates that you did not.

cheers,
-MH

--
Michael Harms, Ph.D.
---
Conte Center for the Neuroscience of Mental Disorders
Washington University School of Medicine
Department of Psychiatry, Box 8134
660 South Euclid Ave. Tel: 314-747-6173
St. Louis, MO  63110 Email: mha...@wustl.edu

From: 
mailto:hcp-users-boun...@humanconnectome.org>>
 on behalf of YC Yao mailto:yao_yongch...@icloud.com>>
Date: Friday, October 14, 2016 at 10:29 AM
To: "hcp-users@humanconnectome.org<mailto:hcp-users@humanconnectome.org>" 
mailto:hcp-users@humanconnectome.org>>
Subject: Re: [HCP-Users] errors with HCP_Pipelines structural processing

Hi Tim,

Thank you for your detailed replay, I have fixed the errors read:
mghRead(/100307/T1w/100307/mri/brain.finalsurfs.mgz, -1): could not open file
mghRead(/100307/T1w/100307/mri/brain.finalsurfs.mgz, -1): could not open file
mghRead(/100307/T1w/100307/mri/brain.finalsurfs.mgz, -1): could not open file
/home/yoson/Applications/HCP_Pipelines/PostFreeSurfer/scripts/FreeSurfer2CaretConvertAndRegisterNonlinear.sh:
 line 63: /100307/T1w/100307/mri/c_ras.mat: No such file or directory

As you suppose, the reason for having these errors is the wrong path directing 
to  brain.finalsurfs.mgz, so after checking the script I use to invoke 
PostFreeSurferPipeline.sh, I find out that I set the the value 
/Users/YOSON/Projects/HcpPipelinesExampleDataGDC to a wrong variable name 
SStudyFolder where I duplicate the capital S.However, successive errors appear 
even after I set the right path.

In case errors would have occurred in the first two part, I deleted all 
generated files and re-runed pre-freesurfer and freesurfer process. After that, 
I found that the FreeSurferPipeline.sh.e
23511 and PreFreeSurferPipeline.sh.e13527 were blank, while there were errors 
in PostFreeSurferPipeline.sh.e23895.
The errors read:
mghRead(/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz,
 -1): could not open file
mghRead(/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz,
 -1): could not open file
mghRead(/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz,
 -1): could not open file
Cannot open volume 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/wmparc_1mm for 
reading!

I checked the data repository, and could not find 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz
 and /home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/wmparc_1mm.


Here is the info of PreFreeSurferPipeline.sh.o13527:
Fri Oct 14 15:28:05 CST 2016 - PreFreeSurferPipeline.sh - Platform Information 
Follows:
Linux yoson-Precision-Tower-3620 4.4.0-42-generic #62-Ubuntu SMP Fri Oct 7 
23:11:45 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Fri Oct 14 15:28:05 CST 2016 - PreFreeSurferPipeline.sh - Parsing Command Line 
Options
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - Finished Parsing 
Command Line Options
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - StudyFolder: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - Subject: 100307
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wInputImages: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/unprocessed/3T/T1w_MPR1/100307_3T_T1w_MPR1.nii.gz@
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T2wInputImages: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/unprocessed/3T/T2w_SPC1/100307_3T_T2w_SPC1.nii.gz@
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wTemplate: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_0.7mm.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wTemplateBrain: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_0.7mm_brain.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wTemplate2mm: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_2mm.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T2wTemplate: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T2_0.7mm.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T2wTemplateBrain: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T2_0.7mm_brain.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline

Re: [HCP-Users] errors with HCP_Pipelines structural processing

2016-10-14 Thread YC Yao
Hi Tim,

Thank you for your detailed replay, I have fixed the errors read:
mghRead(/100307/T1w/100307/mri/brain.finalsurfs.mgz, -1): could not open file
mghRead(/100307/T1w/100307/mri/brain.finalsurfs.mgz, -1): could not open file
mghRead(/100307/T1w/100307/mri/brain.finalsurfs.mgz, -1): could not open file
/home/yoson/Applications/HCP_Pipelines/PostFreeSurfer/scripts/FreeSurfer2CaretConvertAndRegisterNonlinear.sh:
 line 63: /100307/T1w/100307/mri/c_ras.mat: No such file or directory

As you suppose, the reason for having these errors is the wrong path directing 
to  brain.finalsurfs.mgz, so after checking the script I use to invoke 
PostFreeSurferPipeline.sh, I find out that I set the the value 
/Users/YOSON/Projects/HcpPipelinesExampleDataGDC to a wrong variable name 
SStudyFolder where I duplicate the capital S.However, successive errors appear 
even after I set the right path.

In case errors would have occurred in the first two part, I deleted all 
generated files and re-runed pre-freesurfer and freesurfer process. After that, 
I found that the FreeSurferPipeline.sh.e
23511 and PreFreeSurferPipeline.sh.e13527 were blank, while there were errors 
in PostFreeSurferPipeline.sh.e23895. 
The errors read:
mghRead(/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz,
 -1): could not open file
mghRead(/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz,
 -1): could not open file
mghRead(/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz,
 -1): could not open file
Cannot open volume 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/wmparc_1mm for 
reading!

I checked the data repository, and could not find 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/100307/mri/brain.finalsurfs.mgz
 and /home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/T1w/wmparc_1mm.


Here is the info of PreFreeSurferPipeline.sh.o13527:
Fri Oct 14 15:28:05 CST 2016 - PreFreeSurferPipeline.sh - Platform Information 
Follows: 
Linux yoson-Precision-Tower-3620 4.4.0-42-generic #62-Ubuntu SMP Fri Oct 7 
23:11:45 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Fri Oct 14 15:28:05 CST 2016 - PreFreeSurferPipeline.sh - Parsing Command Line 
Options
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - Finished Parsing 
Command Line Options
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - StudyFolder: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - Subject: 100307
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wInputImages: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/unprocessed/3T/T1w_MPR1/100307_3T_T1w_MPR1.nii.gz@
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T2wInputImages: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/unprocessed/3T/T2w_SPC1/100307_3T_T2w_SPC1.nii.gz@
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wTemplate: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_0.7mm.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wTemplateBrain: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_0.7mm_brain.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T1wTemplate2mm: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_2mm.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T2wTemplate: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T2_0.7mm.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T2wTemplateBrain: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T2_0.7mm_brain.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - T2wTemplate2mm: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T2_2mm.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - TemplateMask: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_0.7mm_brain_mask.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - Template2mmMask: 
/home/yoson/Applications/HCP_Pipelines/global/templates/MNI152_T1_2mm_brain_mask_dil.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - BrainSize: 150
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - FNIRTConfig: 
/home/yoson/Applications/HCP_Pipelines/global/config/T1_2_MNI152_2mm.cnf
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - MagnitudeInputName: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/unprocessed/3T/T1w_MPR1/100307_3T_FieldMap_Magnitude.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - PhaseInputName: 
/home/yoson/Projects/HcpPipelinesExampleDataGDC/100307/unprocessed/3T/T1w_MPR1/100307_3T_FieldMap_Phase.nii.gz
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - GEB0InputName: NONE
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - TE: 2.46
Fri Oct 14 15:28:06 CST 2016 - PreFreeSurferPipeline.sh - 

Re: [HCP-Users] errors with HCP_Pipelines structural processing

2016-10-13 Thread Timothy B. Brown

Hi YC Yao,

Could you please send the actual call that you are using to invoke the 
PostFreeSurferPipeline.sh script?


I suspect that for some reason that invocation is missing the required 
--path= option or the option is in some way 
incorrectly formed.


Here is my reasoning.

The "no such file or directory" error you are getting reads:

   
/home/yoson/Applications/HCP_Pipelines/PostFreeSurfer/scripts/FreeSurfer2CaretConvertAndRegisterNonlinear.sh:
   line 63: /100307/T1w/100307/mri/c_ras.mat: No such file or directory

Looking line 63 in the FreeSurfer2CaretConvertAndRegisterNonlinear.sh 
script on line 63, we see that the statement there is trying to put some 
values in a file named c_ras.mat.


   echo "1 0 0 ""$MatrixX" > "$FreeSurferFolder"/mri/c_ras.mat

The file it is trying to create is named 
"$FreeSurferFolder"/mri/c_ras.mat and in your case it is trying to 
create that file as /100307/T1w/100307/mri/c_ras.mat. This means that at 
the point this statement is being executed the variable FreeSurferFolder 
has the value /100307/T1w/100307.


Since it is unlikely that you have a directory named 100307 at the very 
root of your file system (which is what a file path starting with 
/100307 means), it makes sense that the system is saying that there is 
no such file or directory. So it seems that there is something wrong 
with the value of FreeSurferFolder at this point.


So, if we trace back in the 
FreeSurfer2CaretConvertAndRegisterNonlinear.sh script to where the value 
of FreeSurferFolder is set, we see that it is the 6th command line 
parameter passed in to the script. Line 10 reads: FreeSurferFolder="$6". 
The FreeSurfer2CaretConvertAndRegisterNonlinear.sh script is invoked on 
line 127 of the PostFreeSurferPipeline.sh script, and the value that is 
passed in as the 6th command line parameter is the value of the 
FreeSurferFolder variable in the PostFreeSurferPipeline.sh script. In 
your case, that variable must have the value /100307/T1w/100307.


Back on line 119 of the PostFreeSurferPipeline.sh script, we see that 
the FreeSurferFolder variable gets the value 
"$T1wFolder"/"$FreeSurferFolder".


   FreeSurferFolder=$"T1wFolder"/"$FreeSurferFolder"

So we need to search further backward in the script for where T1wFolder 
and FreeSurferFolder have values set prior to this assignment.


Way back on line 80, FreeSurferFolder gets the value "$Subject". That 
likely accounts for the 100307 at the end of the value we are seeing 
(/100307/T1w/100307), meaning that the T1wFolder variable most likely 
has the value /100307/T1w.


So where does the T1wFolder variable get its value?

On line 116, T1wFolder is assigned a value as follows:

   T1wFolder="$StudyFolder"/"$Subject"/"$T1wFolder"

Recall that we have every reason to believe that your value for 
T1wFolder at this point is /100307/T1w.


Back on line 75, T1wFolder is assigned the value T1w, and you can bet 
that the Subject variable has the subject id number (100307) as its 
value. So the assignment of a new value for T1wFolder on line 116 would 
end up with a value of /100307/T1w in the case that the StudyFolder is 
an empty string or has no value.


So...where should StudyFolder be getting its value?

Line 50 of the PostFreeSurferPipeline.sh script reads:

   StudyFolder=`opts_GetOpt1 "--path" $@`

This line means that the StudyFolder variable gets its value from the 
--path= option used when invoking the 
PostFreeSurferPipeline.sh script. Since you are apparently getting an 
empty string value assigned to the StudyFolder variable, it seems that 
there some kind of problem with your --path= 
option. Perhaps it is missing. Perhaps it only has one hyphen in front 
of path (e.g. -path=). Perhaps (and this seems 
most likely to me) there is a space between the = and the path that you 
specified (e.g. --path= /my/study/directory). If there is a space after 
the =, then the StudyFolder variable will get assigned an empty string.


Please take a look at your invocation of the PostFreeSurferPipeline.sh 
script and see if the --path= option seems to be specified correctly.


Hope this is helpful,
  Tim

On 10/13/2016 09:43 AM, 姚永成 wrote:

Dear HCP users,

I am a  beginner of HCP Pipelines, and I have installed necessary 
tools including freesurfer_v5.3.0_HCP, fsl_v5.0.9(I can not find 
v5.0.6), HCP Workbench, HCP Pipelines scripts and other dependencies.
I have also downloaded HCP example data to test structural processing 
part of HCP Pipelines, fallowing the guidance 
here(https://github.com/Washington-University/Pipelines/wiki/v3.4.0-Release-Notes,-Installation,-and-Usage).


However, I encounter errors when it comes to the 3rd part of 
structural processing: Post-freesurfer-processing.
I checked the automatically generated file named xxx.sh.e, and 
found out that only a file named PostFreeSurferPipeline.sh.e6340 
contains errors messages, which mean that nothing wrong with the first 
two part.


The errors messages are :
mghRead(/100307/T1w