示例#1
0
文件: PlannerOps.py 项目: c-l/planopt
    def getResult(self):
        planStr, rawOut, planCount = self.runPlanner()
        if planStr == -1:
            return -1,-1,-1

        self.planStrF = utils.getStringFile(planStr)
        return utils.getStringFile(planStr), rawOut, planCount
示例#2
0
文件: PlannerOps.py 项目: c-l/planopt
    def getResult(self):
        fdPlanStr, plannerOutput, planCount = self.runPlanner()
        if fdPlanStr == -1:
            return -1, -1, -1
        # modify planStr to add line numbers etc.
        planLines = fdPlanStr.replace("(", "").replace(")","").split("\n")
        planStr = ""
        for lineNum in range(0,len(planLines)):
            if planLines[lineNum].strip()!="":
                planStr += "\t"+repr(lineNum)+": "+  planLines[lineNum].upper() + "\n"

        self.planStrF = utils.getStringFile(planStr)
        return utils.getStringFile(planStr), plannerOutput, planCount 
示例#3
0
文件: HLPlan.py 项目: c-l/planopt
 def getStrIOPlan(self):
     i=0
     str = ""
     for aline in self.actionList:
         str += "\t" + repr(i) + ":" + aline + "\n"
         i+=1
     return utils.getStringFile(str)
示例#4
0
文件: PlannerOps.py 项目: c-l/planopt
    def getResult(self):
        planStr, rawOut, planCount = self.runPlanner()
        if planStr == -1:
            return -1, -1, -1

        linenum = 0
        outStr = ""
        for line in planStr.split("\n"):
            if line.strip() != "":
                outStr += "\t" + repr(linenum) + ": " + line.replace("(", " ").replace(")", " ").replace(",", " ").strip().upper()\
                    + "\n"
                linenum += 1 
        self.planStrF = utils.getStringFile(outStr)
        return self.planStrF, rawOut, planCount