Commit ed3afd18 authored by Sumitra Corraya's avatar Sumitra Corraya

Update symple.cc

parent 57feac48
......@@ -197,24 +197,30 @@ int symple::step() {
<< std::endl;
// Reconstruct plan
Plan plan;
double startRec = g_timer();
if (!astarFwd.reconstructSolution(collisionFound, plan)) {
return FAILED;
}
if (!astarBwd.reconstructSolution(collisionFound, plan)) {
return FAILED;
}
if (!validatePlan(plan)) {
std::cerr << "Plan not valid!" << std::endl;
return FAILED;
}
for (int i = 1; i <= 20; i++) {
// Reconstruct plan
Plan plan;
double startRec = g_timer();
if (!astarFwd.reconstructSolution(collisionFound, plan)) {
return FAILED;
}
if (!astarBwd.reconstructSolution(collisionFound, plan)) {
return FAILED;
}
if (!validatePlan(plan)) {
std::cerr << "Plan not valid!" << std::endl;
return FAILED;
}
// if (sat_planning)
// save_plan(plan, plan_id);
this->set_plan(plan);
std::cout << "Plan reconstruction took: " << g_timer() - startRec << "sec"
<< std::endl;
// if (sat_planning)
// save_plan(plan, plan_id);
//this->set_plan(plan);
std::cout << "***************Opt plan : " << i << "***************" << std::endl;
save_plan(plan, plan_id);
plan_id++;
std::cout << "Plan reconstruction took: " << g_timer() - startRec << "sec"
<< std::endl;
}
// Clean up
printMemoryState(forest);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment