Issue367

Title Reduce number of PDB evaluations in CanonicalPDBsHeuristic
Priority feature Status resolved
Superseder Nosy List florian, gabi, malte
Assigned To florian Keywords
Optional summary

Created on 2012-10-12.19:30:55 by florian, last changed by gabi.

Files
File name Uploaded Type Edit Remove
report-scatter-time.png florian, 2012-10-13.10:33:16 image/png
report-scatter-total_time.png florian, 2012-10-13.10:34:29 image/png
Messages
msg2362 (view) Author: malte Date: 2012-10-14.15:58:19
The results look excellent, and the patch is fine.
msg2361 (view) Author: florian Date: 2012-10-13.10:34:29
And here is the plot for total time (description below).
msg2360 (view) Author: florian Date: 2012-10-13.10:33:16
Looks like this was worth the change: attached is a scatter plot of the search
time for the base version (09c98fa990c1) and a version with this fix
(23b21684dcb5). I'll attach a plot for the total time in a second post, because
I couldn't figure out how to attach 2 files in one post. Since the total time is
dominated by the pattern generation, the impact is much smaller on the total
time compared to the search time. It is still significant with 11 additional
tasks solved across 7 domains.

Gabi, could you review and pull this?
I uploaded it here
https://bitbucket.org/flogo/fast-downward/changesets/tip/branch%28%22issue367%22%29
(ssh access via ssh://hg@bitbucket.org/flogo/fast-downward with your bitbucket key)
Please only pull branch "issue367", as there are some other unfinished patches
in this repo.
msg2359 (view) Author: florian Date: 2012-10-12.19:46:00
> The idea was that "evaluate" is called once for each pattern, and the later
> parts of the computation then use "is_dead_end" and "get_heuristic", which just
> return a stored value.
In this case, it should be ok to check "is_dead_end" immediately (in the loop
over PDBs, not in the one over cliques) because the reaction doesn't depend on
the clique.
msg2358 (view) Author: malte Date: 2012-10-12.19:37:39
> Currently PDBs are evaluated during the loop over the cliques, so if
> a PDB is part of multiple cliques, is is evaluated multiple times.

Interesting, this is not how we wanted it. :-)

The idea was that "evaluate" is called once for each pattern, and the later
parts of the computation then use "is_dead_end" and "get_heuristic", which just
return a stored value.

Thanks for noticing this, definitely worth changing!
msg2357 (view) Author: florian Date: 2012-10-12.19:30:55
Gabi and I just looked at a small improvement for the CanonicalPDBsHeuristic:
When the heuristic value is calculated, we can evaluate each PDB before looping
over the cliques. Currently PDBs are evaluated during the loop over the cliques,
so if a PDB is part of multiple cliques, is is evaluated multiple times.
This change led to some improvement in the search time on the few samples we
tested on. 
The tests with dominance pruning (see issue350) suggest that this might also
have impact on the overall solve time in some domains.
I'm starting this issue mainly to get an issue number, so I can branch and test
properly.
History
Date User Action Args
2012-10-15 17:22:41gabisetstatus: in-progress -> resolved
2012-10-14 15:58:19maltesetmessages: + msg2362
2012-10-13 10:34:29floriansetfiles: + report-scatter-total_time.png
messages: + msg2361
2012-10-13 10:33:16floriansetfiles: + report-scatter-time.png
messages: + msg2360
2012-10-12 19:46:00floriansetmessages: + msg2359
2012-10-12 19:37:39maltesetmessages: + msg2358
2012-10-12 19:30:55floriancreate