def updatePipeline(self, localId, medleyXml): root = ElementTree.fromstring(self.pipelineForKey[int(localId)]) changed, root2 = self.update_xml(localId, ElementTree.fromstring(medleyXml)) if not changed: return localId ppipe = ElementTree.tostring(root2) pdimm = self.dimensionsForKey[int(localId)] pmid = self.moduleIdsForKey[int(localId)] pnames = self.namesForKey[int(localId)] pinstance = unserialize(ppipe, Pipeline) self.deleteCell(localId) newId = self.dispatchPipeline(pinstance, pnames[0], pnames[1], pmid, pdimm) return str(newId)
def executePipeline(self,pipeline): from core.db.io import unserialize from core.vistrail.pipeline import Pipeline from core.interpreter.default import get_default_interpreter as getDefaultInterpreter from core.utils import DummyView import api tabController = self.spreadsheetWindow.get_current_tab_controller() pip = unserialize(str(pipeline), Pipeline) # print " **** Client-%s ---Received Pipeline--- modules:" % str( self.dimensions ) # for module in pip.module_list: # print " ", str(module.id) self.current_pipeline = pip interpreter = getDefaultInterpreter() kwargs = { "locator": None, "current_version": None, "view": DummyView(), "aliases": {} } interpreter.execute( pip, **kwargs ) print "Finished Executing Pipeline"
def executePipeline(self, pipeline): from core.db.io import unserialize from core.vistrail.pipeline import Pipeline from core.interpreter.default import get_default_interpreter as getDefaultInterpreter from core.utils import DummyView import api tabController = self.spreadsheetWindow.get_current_tab_controller() pip = unserialize(str(pipeline), Pipeline) # print " **** Client-%s ---Received Pipeline--- modules:" % str( self.dimensions ) # for module in pip.module_list: # print " ", str(module.id) self.current_pipeline = pip interpreter = getDefaultInterpreter() kwargs = { "locator": None, "current_version": None, "view": DummyView(), "aliases": {} } interpreter.execute(pip, **kwargs) print "Finished Executing Pipeline"