Skip to content

Commit

Permalink
Removed some debug output. Refs #7001.
Browse files Browse the repository at this point in the history
  • Loading branch information
wdzhou committed Jun 18, 2013
1 parent 5f08e83 commit e304c14
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 50 deletions.
20 changes: 10 additions & 10 deletions Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1860,8 +1860,8 @@ namespace Algorithms

fwhm = leftfwhm + rightfwhm;

g_log.information() << "Estimated peak parameters: Centre = " << centre << ", Height = "
<< height << ", FWHM = " << fwhm << ".\n";
g_log.debug() << "Estimated peak parameters: Centre = " << centre << ", Height = "
<< height << ", FWHM = " << fwhm << ".\n";

return true;
}
Expand Down Expand Up @@ -1928,7 +1928,7 @@ namespace Algorithms
m_backgroundFunction->setParameter("A2", 0.0);
}

g_log.information() << "Estimated background: A0 = " << out_bg0 << ", A1 = "
g_log.debug() << "Estimated background: A0 = " << out_bg0 << ", A1 = "
<< out_bg1 << ".\n";

return;
Expand Down Expand Up @@ -1984,7 +1984,7 @@ namespace Algorithms
m_backgroundFunction->setParameter("A2", 0.0);
}

g_log.information() << "Estimated flat background: A0 = " << out_bg0 << ".\n";
g_log.debug() << "Estimated flat background: A0 = " << out_bg0 << ".\n";

return;
}
Expand Down Expand Up @@ -2057,20 +2057,20 @@ namespace Algorithms
for (std::vector<double>::const_iterator it = rawParams.begin(); it != rawParams.end(); ++it)
{
t << (*it);
g_log.information() << (*it) << " ";
g_log.debug() << (*it) << " ";
}
}
else
{
for (std::vector<double>::const_iterator it = params.begin(); it != params.end(); ++it)
{
t << (*it);
g_log.information() << (*it) << " ";
g_log.debug() << (*it) << " ";
}
}

t << mincost;
g_log.information() << "Chi2 = " << mincost << "\n";
g_log.debug() << "Chi2 = " << mincost << "\n";
}
}

Expand Down Expand Up @@ -2483,9 +2483,9 @@ namespace Algorithms
double startx = newX[0];
double endx = newX.back();

g_log.information() << "Background Type = " << m_backgroundType << " Function: "
<< m_backgroundFunction->asString() << " StartX = "
<< startx << " EndX = " << endx << ".\n";
g_log.debug() << "Background Type = " << m_backgroundType << " Function: "
<< m_backgroundFunction->asString() << " StartX = "
<< startx << " EndX = " << endx << ".\n";

// Set up the background fitting
IAlgorithm_sptr fit;
Expand Down
40 changes: 0 additions & 40 deletions Code/Mantid/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -618,40 +618,8 @@ namespace Algorithms
}
}

#if 1
// FIXME - Remove this section after debugging
if (s == 3695 || s == 3693)
{
std::stringstream dbmsgss;
bool highbkgd = getProperty("HighBackground");
dbmsgss << "FindPeaks(" << s << "): FWHM = 7, Tolerance = 4, PeakFunction = " << m_peakType << ", "
<< "BackgroundType = " << m_backType << ", High background = " << highbkgd
<< ", MinGuessedPeakWidth = 4, MaxGuessPeakWidth = 4" << ".\n";
dbmsgss << "Peak positions: ";
for (size_t i = 0; i < peakPosToFit.size(); ++i)
{
dbmsgss << peakPosToFit[i] << ", ";
}
dbmsgss << ".\n";
if (useFitWindows)
{
dbmsgss << "Fit windows: ";
for (size_t i = 0; i < fitWindowsToUse.size(); ++i)
dbmsgss << fitWindowsToUse[i] << ", ";
dbmsgss << ".\n";
}
else
{
dbmsgss << "No fit windows are set up to use.\n";
}
g_log.notice(dbmsgss.str());
}

#endif

double minpeakheight = getProperty("MinimumPeakHeight");


API::IAlgorithm_sptr findpeaks = createChildAlgorithm("FindPeaks", -1, -1, false);
findpeaks->setProperty("InputWorkspace", inputW);
findpeaks->setProperty<int>("FWHM",7);
Expand Down Expand Up @@ -697,15 +665,7 @@ namespace Algorithms
peakWidFitted.push_back(width);
peakHighFitted.push_back(height);
peakBackground.push_back(background);
#if 1
chisq.push_back(chi2);
#else
// Experiment to use peak height as a fitting fact
if (height > 0)
chisq.push_back(chi2/height);
else
chisq.push_back(1.0E10);
#endif
}

// first remove things that just didn't fit (center outside of window, bad chisq, ...)
Expand Down

0 comments on commit e304c14

Please sign in to comment.