Public Member Functions | |
def | __init__ |
def | add_fact |
def | add_rule |
def | convert_trivial_rules |
def | dump |
def | normalize |
def | remove_free_effect_variables |
def | split_duplicate_arguments |
def | split_rules |
Public Attributes | |
facts | |
new_name | |
objects | |
rules |
Definition at line 9 of file pddl_to_prolog.py.
def pddl_to_prolog.PrologProgram.__init__ | ( | self | ) |
Definition at line 10 of file pddl_to_prolog.py.
def pddl_to_prolog.PrologProgram.add_fact | ( | self, | |
atom | |||
) |
Definition at line 18 of file pddl_to_prolog.py.
def pddl_to_prolog.PrologProgram.add_rule | ( | self, | |
rule | |||
) |
Definition at line 21 of file pddl_to_prolog.py.
Convert rules with an empty condition into facts. This must be called after bounding rule effects, so that rules with an empty condition must necessarily have a variable-free effect. Variable-free effects are the only ones for which a distinction between ground and symbolic atoms is not necessary.
Definition at line 80 of file pddl_to_prolog.py.
def pddl_to_prolog.PrologProgram.dump | ( | self | ) |
Definition at line 23 of file pddl_to_prolog.py.
def pddl_to_prolog.PrologProgram.normalize | ( | self | ) |
Definition at line 28 of file pddl_to_prolog.py.
Remove free effect variables like the variable Y in the rule p(X, Y) :- q(X). This is done by introducing a new predicate @object, setting it true for all objects, and translating the above rule to p(X, Y) :- q(X), @object(Y). After calling this, no new objects should be introduced!
Definition at line 47 of file pddl_to_prolog.py.
Make sure that no variable occurs twice within the same symbolic fact, like the variable X does in p(X, Y, X). This is done by renaming the second and following occurrences of the variable and adding equality conditions. For example p(X, Y, X) is translated to p(X, Y, X@0) with the additional condition =(X, X@0); the equality predicate must be appropriately instantiated somewhere else.
Definition at line 68 of file pddl_to_prolog.py.
def pddl_to_prolog.PrologProgram.split_rules | ( | self | ) |
Definition at line 37 of file pddl_to_prolog.py.
Definition at line 10 of file pddl_to_prolog.py.
Definition at line 10 of file pddl_to_prolog.py.
Definition at line 10 of file pddl_to_prolog.py.
Definition at line 10 of file pddl_to_prolog.py.