Commit 57758252 authored by Yaroslav Gevorkov's avatar Yaroslav Gevorkov
Browse files

adjust refinement result selection for refinement 3, too

parent 7ecc96dd
......@@ -142,8 +142,11 @@ void PinkIndexer::refine(Lattice& indexedLattice, Vector2f& centerShift, const M
double minFittedNodesMeanDefect = 1;
for (int i = 0; i < refinementTries; ++i)
{
if (fittedNodesCount[i] > maxFittedNodesCount ||
(fittedNodesCount[i] == maxFittedNodesCount && fittedNodesMeanDefects[i] < minFittedNodesMeanDefect))
// if (fittedNodesCount[i] > maxFittedNodesCount ||
// (fittedNodesCount[i] == maxFittedNodesCount && fittedNodesMeanDefects[i] < minFittedNodesMeanDefect))
if (fittedNodesCount[i] / maxFittedNodesCount > 1.2 ||
(fittedNodesCount[i] > maxFittedNodesCount || fittedNodesMeanDefects[i] < minFittedNodesMeanDefect) &&
(fittedNodesCount[i] / maxFittedNodesCount - 1) * 3 > (minFittedNodesMeanDefect / fittedNodesMeanDefects[i] - 1))
{
maxFittedNodesCount = fittedNodesCount[i];
minFittedNodesMeanDefect = fittedNodesMeanDefects[i];
......
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