Hi,
I’m trying to preprocess a longitudinal dataset using QuNEx 1.3.0. Most subjects have both T1w and T2w images, but a small number of sessions are missing the T2w image. I would therefore like to process those sessions using LegacyStyleData.
For the sessions without T2w, I set the following in my batch parameter file:
_hcp_processing_mode : LegacyStyleData
_hcp_t2 : NONE
However, hcp_pre_freesurfer fails immediately with:
ERROR: missing the following mandatory parameter(s):
--t2template --t2templatebrain --t2template2mm
ABORTING
I checked the generated PreFreeSurferPipeline.sh call, and when hcp_t2=NONE, QuNEx does not pass any of the three T2 template arguments.
I also inspected process_hcp.py in the QuNEx 1.3.0 container and found that the T2 template variables appear to be explicitly set to empty strings when hcp_t2 == “NONE”:
if options["hcp_t2"] == "NONE":
t2template = ""
elif options["hcp_prefs_t2template"] is None:
t2template = os.path.join(
hcp["hcp_Templates"],
"MNI152_T2_%smm.nii.gz" % (options["hcp_prefs_template_res"]),
)
else:
t2template = options["hcp_prefs_t2template"]
The same logic is used for t2templatebrain and t2template2mm.
I confirmed that the corresponding template files do exist inside the container:
/opt/HCP/HCPpipelines/global/templates/MNI152_T2_1mm.nii.gz
/opt/HCP/HCPpipelines/global/templates/MNI152_T2_1mm_brain.nii.gz
/opt/HCP/HCPpipelines/global/templates/MNI152_T2_2mm.nii.gz
As a control, when I process a subject that does have T2w, using HCPStyleData and _hcp_t2 : t2, QuNEx correctly generates a call containing the T2 image and all three T2 template arguments, and PreFreeSurfer proceeds normally.
Is there a recommended way to run T1-only data with LegacyStyleData in QuNEx 1.3.0? In particular, is there another parameter I should be setting when using _hcp_t2 : NONE, or is the omission of the T2 template arguments in this case a bug?
I would prefer to keep the same QuNEx/container version across the entire longitudinal cohort, so I would especially appreciate a solution that allows these few T1-only sessions to be processed within QuNEx 1.3.0.
Thank you!