def registerCustomExecutables(self, workflow=None): """ 2013.1.28 """ AbstractVervetAlignmentWorkflow.registerCustomExecutables(self, workflow=workflow) if workflow is None: workflow = self namespace = workflow.namespace version = workflow.version operatingSystem = workflow.operatingSystem architecture = workflow.architecture site_handler = workflow.site_handler vervetSrcPath = self.vervetSrcPath #2012.8.7 each cell is a tuple of (executable, clusterSizeMultipler (0 if u do not need clustering) executableClusterSizeMultiplierList = [] psmc = Executable(namespace=namespace, name="psmc", version=version, \ os=operatingSystem, arch=architecture, installed=True) psmc.addPFN(PFN("file://" + os.path.join(self.psmcFolderPath, "psmc"), site_handler)) executableClusterSizeMultiplierList.append((psmc, 0.1)) fq2psmcfa = Executable(namespace=namespace, name="fq2psmcfa", version=version, \ os=operatingSystem, arch=architecture, installed=True) fq2psmcfa.addPFN(PFN("file://" + os.path.join(self.pymodulePath, "popgen/fq2psmcfa.sh"), site_handler)) executableClusterSizeMultiplierList.append((fq2psmcfa, 1)) psmc2history = Executable(namespace=namespace, name="psmc2history", version=version, \ os=operatingSystem, arch=architecture, installed=True) psmc2history.addPFN(PFN("file://" + os.path.join(self.psmcFolderPath, "utils/psmc2history.pl"), site_handler)) executableClusterSizeMultiplierList.append((psmc2history, 1)) history2ms = Executable(namespace=namespace, name="history2ms", version=version, \ os=operatingSystem, arch=architecture, installed=True) history2ms.addPFN(PFN("file://" + os.path.join(self.psmcFolderPath, "utils/history2ms.pl"), site_handler)) executableClusterSizeMultiplierList.append((history2ms, 1)) psmc_plot = Executable(namespace=namespace, name="psmc_plot", version=version, \ os=operatingSystem, arch=architecture, installed=True) psmc_plot.addPFN(PFN("file://" + os.path.join(self.psmcFolderPath, "utils/psmc_plot.pl"), site_handler)) executableClusterSizeMultiplierList.append((psmc_plot, 1)) self.addExecutableAndAssignProperClusterSize(executableClusterSizeMultiplierList, defaultClustersSize=self.clusters_size) self.addOneExecutableFromPathAndAssignProperClusterSize(path=os.path.join(self.pymodulePath, 'popgen/GenerateMSCommandFromPSMCOutput.sh'), \ name='GenerateMSCommandFromPSMCOutput', clusterSizeMultipler=1) self.addOneExecutableFromPathAndAssignProperClusterSize(path=os.path.join(self.pymodulePath, 'popgen/ReplaceMSPathInMSCommandFile.py'), \ name='ReplaceMSPathInMSCommandFile', clusterSizeMultipler=2) self.addOneExecutableFromPathAndAssignProperClusterSize(path=os.path.join(self.vervetSrcPath, 'db/input/AddIndividualAlignmentConsensusSequence2DB.py'), \ name='AddIndividualAlignmentConsensusSequence2DB', clusterSizeMultipler=0.05) #2013.2.10 reduce clustering size for runShellCommand because ms takes a while self.setOrChangeExecutableClusterSize(executable=self.runShellCommand, clusterSizeMultipler=0.1) #2013.2.15 this SelectChromosomeSequences does it only on one alignment at a time self.setOrChangeExecutableClusterSize(executable=self.SelectChromosomeSequences, clusterSizeMultipler=0.05)
def __init__(self, **keywords): """ 2013.1.25 """ AbstractVervetAlignmentWorkflow.__init__(self, **keywords) if hasattr(self, 'psmcFolderPath'): self.psmcFolderPath = self.insertHomePath(self.psmcFolderPath, self.home_path) else: self.psmcFolderPath = None if hasattr(self, 'msPath'): self.msPath = self.insertHomePath(self.msPath, self.home_path) else: self.msPath = None