diff --git a/image_analysis/RotationIndexer.cpp b/image_analysis/RotationIndexer.cpp index ebe5a83e0..a6891ffa3 100644 --- a/image_analysis/RotationIndexer.cpp +++ b/image_analysis/RotationIndexer.cpp @@ -9,6 +9,8 @@ #include "RotationIndexer.h" +#include "lattice_search/LatticeSearch.h" + RotationIndexer::RotationIndexer(const DiffractionExperiment &x, IndexerThreadPool &indexer) : experiment(x), index_ice_rings(x.GetIndexingSettings().GetIndexIceRings()), @@ -72,12 +74,15 @@ std::optional RotationIndexer::ProcessImage(int64_t image, const last_accumulated_image = image; if (accumulated_images >= min_images_for_indexing && image >= first_image_to_try_indexing) { + // Index auto indexer_result = indexer_.Run(experiment, coords_).get(); - if (!indexer_result.lattice.empty()) - indexed_lattice = indexer_result.lattice[0]; - - // Find lattice type - // Run refinement + if (!indexer_result.lattice.empty()) { + // Find lattice type + auto sym_result = LatticeSearch(indexer_result.lattice[0]); + indexed_lattice = sym_result.conventional; + // Run refinement + //... + } } } diff --git a/image_analysis/RotationIndexer.h b/image_analysis/RotationIndexer.h index c72f7d862..8433c98c5 100644 --- a/image_analysis/RotationIndexer.h +++ b/image_analysis/RotationIndexer.h @@ -25,7 +25,7 @@ class RotationIndexer { mutable std::mutex m; const DiffractionExperiment& experiment; - constexpr static float min_accum_angle_deg = 10.0; + constexpr static float min_accum_angle_deg = 20.0; constexpr static float stride_angle_deg = 0.5; constexpr static int64_t min_images_for_indexing = 10;