I think these ultimately come from PDDL preconditions that we take apart and
split into two actions, e.g. of the form "(or X Y)" where X and Y later turn out
to be evaluatable to constant true in certain instantiations of the operator
parameters.
It would be useful to filter these, but I think there will be a non-trivial
overhead, and there will likely remain missed optimization opportunities where
we have actions that are not duplicates, but dominate each other. I think it
would be great to look into this. As a first step, pure duplicates can probably
be detected most easily by using a dict that maps all parts of the action that
we care about for detecting duplicates (preconditions and effects, but not the
cost -- we want to detect if we have actions that are identical except for the
cost) to the action.
If we go through with this, we should update the parts of our documentation that
refer to pruning performed in preprocessing, since I suggest we drop duplicates
also if actions have different names, which is a form of pruning. Maybe we
should also make it possible to switch this of because people might want to
disable this for purposes such as generating multiple or all optimal plans.
|