本文整理汇总了Python中pipeline.Pipeline.recon方法的典型用法代码示例。如果您正苦于以下问题:Python Pipeline.recon方法的具体用法?Python Pipeline.recon怎么用?Python Pipeline.recon使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pipeline.Pipeline
的用法示例。
在下文中一共展示了Pipeline.recon方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: SPMJob
# 需要导入模块: from pipeline import Pipeline [as 别名]
# 或者: from pipeline.Pipeline import recon [as 别名]
StudyVariables.statsTemplateStatsDir,
StudyVariables.statsTemplateOnsetsDir,
],
StudyVariables.statsTemplateRuns,
fieldmap=StudyVariables.statsTemplateFM,
)
stats_job = SPMJob(subjStatsJob, stats_template_identity, pipe.config["spm_version"])
print "Replacing Stats SPM Identity in subject job "
print stats_job
stats_job.replaceIdentity(subj_stats_identity)
current = os.getcwd()
os.chdir(pipe.working_preprocdir)
if options.recon:
pipe.recon(StudyVariables.studyName, subjFunctionalFormat)
if os.path.exists(subid + "_assetRun1.nii"):
pipe.remove_discdacqs(subid + "_assetRun1.nii", 2)
if os.path.exists(subid + "_assetRun2.nii"):
pipe.remove_discdacqs(subid + "_assetRun2.nii", 2)
if os.path.exists(subid + "_assetRest195.nii"):
pipe.remove_discdacqs(subid + "_assetRest195.nii", 32)
if os.path.exists(subid + "_assetRest165.nii"):
pipe.remove_discdacqs(subid + "_assetRest165.nii", 2)
if options.stc:
pipe.stc(subjFunctionalFormat)
if options.realign:
pipe.realign(subjRealignJob)
if options.motioncheck:
pipe.motionCheck(MOTION_THRESHOLD)
if options.calcderivs:
示例2: SPMJobIdentity
# 需要导入模块: from pipeline import Pipeline [as 别名]
# 或者: from pipeline.Pipeline import recon [as 别名]
print StudyVariables.statsTemplateSubid
# make and change stats job instance
stats_template_identity = SPMJobIdentity (
StudyVariables.statsTemplateSubid,
[StudyVariables.statsTemplatePreprocDir, StudyVariables.statsTemplateStatsDir, StudyVariables.statsTemplateOnsetsDir],
StudyVariables.statsTemplateRuns,
fieldmap=StudyVariables.statsTemplateFM
)
stats_job = SPMJob(subjStatsJob, stats_template_identity)
print "Replacing Stats SPM Identity in subject job "; print stats_job
stats_job.replaceIdentity(subj_stats_identity)
current = os.getcwd()
os.chdir(pipe.working_preprocdir)
if options.recon: pipe.recon(StudyVariables.studyName, subjFunctionalFormat)
if options.stc: pipe.stc(subjFunctionalFormat)
if options.realign: pipe.realign(subjRealignJob)
if options.motioncheck: pipe.motionCheck(MOTION_THRESHOLD)
if options.calcderivs: pipe.calcDerivs()
if options.fmap and subjHasFmap: pipe.fieldMap()
if options.normalize: pipe.normSmooth(subjNormJob)
if options.moveLocalFiles: pipe.moveLocalFilesToNetwork()
os.chdir(pipe.statsdir)
if options.stats: pipe.stats1L(subjStatsJob)
os.chdir(current)
示例3: SPMJob
# 需要导入模块: from pipeline import Pipeline [as 别名]
# 或者: from pipeline.Pipeline import recon [as 别名]
StudyVariables.statsTemplateRuns,
fieldmap=StudyVariables.statsTemplateFM
)
stats_job = SPMJob(subjStatsJob, stats_template_identity)
print "Replacing Stats SPM Identity in subject job "; print stats_job
stats_job.replaceIdentity(subj_stats_identity)
current = os.getcwd()
os.chdir(pipe.working_preprocdir)
if options.recon:
# If we are to do a reconstruction, check to see if the subject had
# ref.dat files in the subject csv. If so, pass them in to the pipe reconstruction,
# otherwise don't.
if subjVisitVars.has_key('refdat_files'):
pipe.recon(StudyVariables.studyName, StudyVariables.studyFunctionalFormat, subjVisitVars['tasks'], subjVisitVars['pfiles'], subjVisitVars['refdat_files'])
else:
pipe.recon(StudyVariables.studyName, StudyVariables.studyFunctionalFormat,subjVisitVars['tasks'], subjVisitVars['pfiles'] )
if os.path.exists(subid + '_assetRun1.nii'): pipe.remove_discdacqs(subid + '_assetRun1.nii', 2)
if os.path.exists(subid + '_assetRun2.nii'): pipe.remove_discdacqs(subid + '_assetRun2.nii', 2)
if os.path.exists(subid + '_assetRest195.nii'): pipe.remove_discdacqs(subid + '_assetRest195.nii', 32)
if os.path.exists(subid + '_assetRest165.nii'): pipe.remove_discdacqs(subid + '_assetRest165.nii', 2)
if options.stc: pipe.stc(subjFunctionalFormat)
if options.realign: pipe.realign(subjRealignJob)
if options.motioncheck: pipe.motionCheck(MOTION_THRESHOLD)
if options.calcderivs: pipe.calcDerivs()
if options.fmap and subjHasFmap: pipe.fieldMap()
if options.normalize: pipe.normSmooth(subjNormJob)
if options.moveLocalFiles: pipe.moveLocalFilesToNetwork()
if options.stats:
示例4: Pipeline
# 需要导入模块: from pipeline import Pipeline [as 别名]
# 或者: from pipeline.Pipeline import recon [as 别名]
print str % ('ALZ2.studyName',StudyVariables.studyName)
print str % ('subjRealignJob',subjRealignJob)
print str % ('MOTION_THRESHOLD',MOTION_THRESHOLD)
print str % ('subjNormJob',subjNormJob)
print str % ('subjStatsJob',subjStatsJob)
print str % ('statstasks',statstasks)
# make a pipe, run it.
pipe = Pipeline(subid, subjRawDir, subjAnatDir, subjPreprocDir, subjStatsDir)
pipe.checkSetup()
if options.recon:
# If we are to do a reconstruction, check to see if the subject had
# ref.dat files in the subject csv. If so, pass them in to the pipe reconstruction,
# otherwise don't.
if subjVisitVars.has_key('refdat_files'):
pipe.recon(subjVisitVars['tasks'], subjVisitVars['pfiles'], StudyVariables.studyName, subjVisitVars['refdat_files'])
else:
pipe.recon(subjVisitVars['tasks'], subjVisitVars['pfiles'], StudyVariables.studyName)
if options.stc: pipe.stc()
if options.realign: pipe.realign(subjRealignJob)
if options.motioncheck: pipe.motionCheck(MOTION_THRESHOLD)
if options.calcderivs: pipe.calcDerivs()
if subjHasFmap and options.fmap: pipe.fieldMap()
if options.normalize: pipe.normSmooth(subjNormJob)
if options.stats: pipe.stats1L(subjStatsJob)
开发者ID:brainmap,项目名称:WADRC-fMRI-Pipeline,代码行数:27,代码来源:preproc-johnson.alz.visit2.adaptrecogwithoutrest.py
示例5: SPMJobIdentity
# 需要导入模块: from pipeline import Pipeline [as 别名]
# 或者: from pipeline.Pipeline import recon [as 别名]
stats_template_identity = SPMJobIdentity (
ALZ1.statsTemplateSubid,
[ALZ1.statsTemplatePreprocDir, ALZ1.statsTemplateStatsDir, ALZ1.statsTemplateOnsetsDir],
ALZ1.statsTemplateRuns,
fieldmap=ALZ1.statsTemplateFM
)
stats_job = SPMJob(subjStatsJob, stats_template_identity)
stats_job.replaceIdentity(subj_stats_identity)
# make a pipe, run it.
pipe = Pipeline(subid, subjRawDir, subjAnatDir, subjPreprocDir, subjStatsDir)
pipe.checkSetup()
if options.recon: pipe.recon(subjVisitVars['tasks'], subjVisitVars['pfiles'], ALZ1.studyName)
if options.stc: pipe.stc()
if options.realign: pipe.realign(subjRealignJob)
if options.motioncheck: pipe.motionCheck(MOTION_THRESHOLD)
if options.calcderivs: pipe.calcDerivs()
if subjHasFmap and options.fmap: pipe.fieldMap()
if options.normalize: pipe.normSmooth(subjNormJob)
if options.stats: pipe.stats1L(subjStatsJob)
示例6: SPMJobIdentity
# 需要导入模块: from pipeline import Pipeline [as 别名]
# 或者: from pipeline.Pipeline import recon [as 别名]
print str % ('ALZ2.studyName',ALZ2.studyName)
print str % ('subjRealignJob',subjRealignJob)
print str % ('MOTION_THRESHOLD',MOTION_THRESHOLD)
print str % ('subjNormJob',subjNormJob)
print str % ('subjStatsJob',subjStatsJob)
print str % ('statstasks',statstasks)
"""
# make a pipe, run it.
pipe.checkSetup()
current = os.getcwd()
os.chdir(pipe.working_preprocdir)
if options.recon:
print str % ("subjVisitVars['tasks']",subjVisitVars['tasks'])
print str % ("subjVisitVars['pfiles']",subjVisitVars['pfiles'])
print pipe.recon(StudyVariables.studyName, 'pfiles', subjVisitVars['tasks'], subjVisitVars['pfiles'])
if options.stc: pipe.stc()
if options.realign:
print subjRealignJob, StudyVariables.realignJob
print str % ("subjVisitVars['tasks']",subjVisitVars['tasks'])
print str % ("subjVisitVars['pfiles']",subjVisitVars['pfiles'])
if not os.path.exists(subjRealignJob) and StudyVariables.realignJob:
shutil.copy(StudyVariables.realignJob, subjRealignJob)
# making a job instance for the template realign job and changing its identity
realign_template_identity = SPMJobIdentity (
StudyVariables.realignTemplateSubid,
[StudyVariables.realignTemplatePreprocDir],
StudyVariables.realignTemplateRuns,
fieldmap=StudyVariables.realignTemplateFM
)
realign_job = SPMJob(subjRealignJob, realign_template_identity)