Skip to content

Commit

Permalink
Refs #9840 Tidy up execution order
Browse files Browse the repository at this point in the history
We can group the IvsQ workspaces at the same time as the IvsLam ones
  • Loading branch information
Harry Jeffery committed Nov 27, 2014
1 parent c7e784e commit 2d5ed6a
Showing 1 changed file with 6 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,7 @@ namespace Mantid
this->setPropertyValue("ThetaOut", alg->getPropertyValue("ThetaOut"));
}

//Group the IvsLam workspaces together
//Group the IvsQ and IvsLam workspaces
Algorithm_sptr groupAlg = this->createChildAlgorithm("GroupWorkspaces");
groupAlg->setChild(false);
groupAlg->setRethrows(true);
Expand All @@ -453,6 +453,10 @@ namespace Mantid
groupAlg->setProperty("OutputWorkspace", outputIvsLam);
groupAlg->execute();

groupAlg->setProperty("InputWorkspaces", IvsQGroup);
groupAlg->setProperty("OutputWorkspace", outputIvsQ);
groupAlg->execute();

//If this is a multiperiod workspace and we have polarization corrections enabled
if(this->getPropertyValue("PolarizationAnalysis") != noPolarizationCorrectionMode())
{
Expand Down Expand Up @@ -491,15 +495,9 @@ namespace Mantid
}
}

//Now we have our final IvsQ workspaces, so let's group them too
groupAlg->setProperty("InputWorkspaces", IvsQGroup);
groupAlg->setProperty("OutputWorkspace", outputIvsQ);
groupAlg->execute();

//We finished successfully
this->setPropertyValue("OutputWorkspace", outputIvsQ);
this->setPropertyValue("OutputWorkspaceWavelength", outputIvsLam);

//We finished successfully
setExecuted(true);
notificationCenter().postNotification(new FinishedNotification(this,isExecuted()));
return true;
Expand Down

0 comments on commit 2d5ed6a

Please sign in to comment.