def setInitialTarget(initModelOption, lsq6Target, targetFileDir, outputDir, pipeName):
    if(initModelOption == None and lsq6Target == None):
        print("Error: please specify either a target file for the registration (--lsq6-target or --bootstrap), or an initial model (--init-model)\n")
        sys.exit()   
    if(initModelOption != None and lsq6Target != None):
        print("Error: please specify ONLY ONE of the following options: --lsq6-target, --bootstrap, --init-model\n")
        sys.exit()
        
    initModel = None
    if(lsq6Target != None):
        targetPipeFH = rfh.RegistrationPipeFH(abspath(lsq6Target), basedir=targetFileDir)
    else: # options.init_model != None  
        initModel = setupInitModel(initModelOption, pipeName, outputDir)
        if (initModel[1] != None):
            # we have a target in "native" space 
            targetPipeFH = initModel[1]
        else:
            # we will use the target in "standard" space
            targetPipeFH = initModel[0]
    
    return(initModel, targetPipeFH)
Function checks to make sure either an init model or inital target are specified.
dataset/ETHPy150Open Mouse-Imaging-Centre/pydpiper/atoms_and_modules/registration_functions.py/setInitialTarget