def __init__(self, exp, algo, task): Run.__init__(self, exp) self.algo = algo self.task = task self._set_properties() # Linking to instead of copying the PDDL files makes building # the experiment twice as fast. self.add_resource("domain", self.task.domain_file, "domain.pddl", symlink=True) self.add_resource("problem", self.task.problem_file, "problem.pddl", symlink=True) self.add_command( "planner", [tools.get_python_executable()] + ["{" + _get_solver_resource_name(algo.cached_revision) + "}"] + algo.driver_options + ["{domain}", "{problem}"] + algo.component_options, )
def __init__(self, exp, algo, task): Run.__init__(self, exp) self.algo = algo self.task = task self.driver_options = algo.driver_options[:] if self.task.domain_file is None: self.add_resource("task", self.task.problem_file, "task.sas", symlink=True) input_files = ["{task}"] # Without PDDL input files, we can't validate the solution. self.driver_options.remove("--validate") else: self.add_resource( "domain", self.task.domain_file, "domain.pddl", symlink=True ) self.add_resource( "problem", self.task.problem_file, "problem.pddl", symlink=True ) input_files = ["{domain}", "{problem}"] self.add_command( "planner", [tools.get_python_executable()] + ["{" + _get_solver_resource_name(algo.cached_revision) + "}"] + self.driver_options + input_files + algo.component_options, ) self._set_properties()
def __init__(self, exp, algo, task): # Note: We surpass the FastDownwardRun constructor to avoid adding the # Fast Downward planner command and adding ours instead Run.__init__(self, exp) self.algo = algo self.task = task self._set_properties() # Linking to instead of copying the PDDL files makes building # the experiment twice as fast. self.add_resource('domain', self.task.domain_file, 'domain.pddl', symlink=True) self.add_resource('problem', self.task.problem_file, 'problem.pddl', symlink=True) # TODO Note that we just pass '.' as the output directory, since the command # TODO will be executed from the run directory. Perhaps cleaner options are available # TODO that don't mix the workspace with other important LAB files? self.add_command( 'planner', ['{' + algo.cached_revision.get_planner_resource_name() + '}'] + algo.driver_options + [ '--domain', '{domain}', '--instance', '{problem}', '--output', '.' ] + algo.component_options, time_limit=exp.time_limit, memory_limit=exp.memory_limit, )
def __init__(self, exp, parts, problem): Run.__init__(self, exp) self.parts = parts self.problem = problem self._set_properties() self._save_limits()
def __init__(self, exp, algo, task): Run.__init__(self, exp) self.algo = algo self.task = task self._set_properties() # Linking to instead of copying the PDDL files makes building # the experiment twice as fast. self.add_resource( 'domain', self.task.domain_file, 'domain.pddl', symlink=True) self.add_resource( 'problem', self.task.problem_file, 'problem.pddl', symlink=True) self.add_command( 'planner', ['{' + algo.cached_revision.get_planner_resource_name() + '}'] + algo.driver_options + ['{domain}', '{problem}'] + algo.component_options)
def __init__(self, exp, config, task, port, rddlsim_runtime, run_time): Run.__init__(self, exp) self.config = config self.task = task self.port = port self.rddlsim_runtime = rddlsim_runtime self._set_properties() self.add_resource("", self.task.domain_file, "domain.rddl", symlink=True) self.add_resource("", self.task.problem_file, "problem.rddl", symlink=True) self.add_command( "planner", [ "{" + _get_wrapper_resource_name(config.cached_revision) + "}", "{" + _get_server_resource_name(config.cached_revision) + "}", "./", str(self.port), str(self.experiment.rddlsim_seed), str(self.rddlsim_runtime), str(self.experiment.num_runs), "{" + _get_planner_resource_name(config.cached_revision) + "}", self.task.problem_name, " ".join(self.config.parser_options), " ".join(self.config.driver_options), self.config.search_engine_desc, ], time_limit=run_time, memory_limit=exp.memory_limit, soft_stdout_limit=exp.soft_stdout_limit, hard_stdout_limit=exp.hard_stdout_limit, soft_stderr_limit=exp.soft_stderr_limit, hard_stderr_limit=exp.hard_stderr_limit, )
def __init__(self, exp, algo, task): Run.__init__(self, exp) self.algo = algo self.task = task self._set_properties() # Linking to instead of copying the PDDL files makes building # the experiment twice as fast. self.add_resource( 'domain', self.task.domain_file, 'domain.pddl', symlink=True) self.add_resource( 'problem', self.task.problem_file, 'problem.pddl', symlink=True) CONF = 'conf2' domain_dir_path = os.path.dirname(self.task.domain_file) domain_name = domain_dir_path.split('/')[-1] problem_name = os.path.splitext(self.task.problem_file)[0].split('/')[-1] asnetsfastdownward_path = os.path.dirname(os.path.dirname(os.path.dirname(domain_dir_path))) network_path = os.path.join(asnetsfastdownward_path + '/evaluation/network_runs/evaluation/protobuf_networks/elu_acc/' + domain_name + '/' + CONF + '/', problem_name + '.pb') # network_path = os.path.join(asnetsfastdownward_path + '/evaluation/network_runs/evaluation/protobuf_networks/' + domain_name + '/accumulate_samples/' + CONF + '/', problem_name + '.pb') # replace the network path dummy string algo.component_options[1] = algo.component_options[1].replace('NETWORK_PATH', network_path) self.add_command( 'fast-downward', ['{' + algo.cached_revision.get_planner_resource_name() + '}'] + algo.driver_options + ['{domain}', '{problem}'] + algo.component_options) algo.component_options[1] = algo.component_options[1].replace(network_path, 'NETWORK_PATH') self.add_command('parse-preprocess', ['{preprocess_parser}']) self.add_command('parse-search', ['{search_parser}']) self.add_command( 'compress-output-sas', ['xz', 'output.sas'])
def __init__(self, exp, algo, task): Run.__init__(self, exp) self.algo = algo self.task = task self._set_properties() # Linking to instead of copying the PDDL files makes building # the experiment twice as fast. self.add_resource( 'domain', self.task.domain_file, 'domain.pddl', symlink=True) self.add_resource( 'problem', self.task.problem_file, 'problem.pddl', symlink=True) self.add_command( 'fast-downward', ['{' + algo.cached_revision.get_planner_resource_name() + '}'] + algo.driver_options + ['{domain}', '{problem}'] + algo.component_options) self.add_command('parse-preprocess', ['{preprocess_parser}']) self.add_command('parse-search', ['{search_parser}']) self.add_command( 'compress-output-sas', ['xz', 'output.sas'])