Commit 00d340dd authored by Yaroslav Gevorkov's avatar Yaroslav Gevorkov
Browse files

use only lokal minima in refinement

parent cb6413fa
......@@ -104,12 +104,12 @@ void PinkIndexer::refine(Lattice& indexedLattice, Vector2f& centerShift, const M
break;
case RefinementType::firstFixedThenVariableLatticeParametersMultiSeed:
{
constexpr int refinementTries = 1000;
constexpr int refinementTries = 1500;
int fittedNodesCount[refinementTries];
double fittedNodesMeanDefects[refinementTries];
Lattice fittedLattices[refinementTries];
float maxRelativeDeviation = 0.0125;
float maxRelativeDeviation = 0.014;
Array<float, 1, 3> columnDeviationNorms = indexedLattice.getBasis().colwise().norm() * maxRelativeDeviation;
#pragma omp parallel for
for (int i = 0; i < refinementTries; ++i)
......@@ -138,8 +138,8 @@ void PinkIndexer::refine(Lattice& indexedLattice, Vector2f& centerShift, const M
fittedNodesMeanDefects[i] = refinement.getMeanDefect(fittedLattices[i].getBasis(), ucsDirections, ucsBorderNorms);
}
int maxFittedNodesCount = refinement.getFittedPeaksCount(indexedLattice, ucsDirections, ucsBorderNorms);
double minFittedNodesMeanDefect = refinement.getMeanDefect(indexedLattice.getBasis(), ucsDirections, ucsBorderNorms);
int maxFittedNodesCount = 0;
double minFittedNodesMeanDefect = 1;
for (int i = 0; i < refinementTries; ++i)
{
if (fittedNodesCount[i] > maxFittedNodesCount ||
......
Supports Markdown
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