From fa121f007922fd3aec991242afc94b40da9bd6ff Mon Sep 17 00:00:00 2001 From: Filip Leonarski Date: Wed, 1 Jul 2026 21:30:10 +0200 Subject: [PATCH] jfjoch_viewer: show "Multiple lattices detected" in image statistics Add a row after the Indexing solution that flags images with more than one indexed lattice (indexing_lattice_count > 1). Co-Authored-By: Claude Opus 4.8 (1M context) --- viewer/widgets/JFJochViewerImageStatistics.cpp | 9 +++++++++ viewer/widgets/JFJochViewerImageStatistics.h | 1 + 2 files changed, 10 insertions(+) diff --git a/viewer/widgets/JFJochViewerImageStatistics.cpp b/viewer/widgets/JFJochViewerImageStatistics.cpp index 280fe4cc..c52cd900 100644 --- a/viewer/widgets/JFJochViewerImageStatistics.cpp +++ b/viewer/widgets/JFJochViewerImageStatistics.cpp @@ -123,6 +123,9 @@ JFJochViewerImageStatistics::JFJochViewerImageStatistics(QWidget *parent) : QWid indexed = new QLabel(this); layout->addRow(new QLabel("Indexing:"), indexed); + multiple_lattices = new QLabel(this); + layout->addRow(multiple_lattices); + res_estimate = new QLabel(this); layout->addRow(new QLabel("Resolution estimate:"), res_estimate); @@ -165,6 +168,7 @@ void JFJochViewerImageStatistics::loadImage(std::shared_ptrsetText(""); indexed->setText(""); indexed->setToolTip(""); + multiple_lattices->setText(""); b_factor->setText(""); profile_radius_label->setText(""); profile_radius->setText(""); @@ -359,4 +363,9 @@ void JFJochViewerImageStatistics::loadImage(std::shared_ptrsetText("N/A"); } + + if (image->ImageData().indexing_lattice_count.value_or(0) > 1) + multiple_lattices->setText("Multiple lattices detected"); + else + multiple_lattices->setText(""); } diff --git a/viewer/widgets/JFJochViewerImageStatistics.h b/viewer/widgets/JFJochViewerImageStatistics.h index 95459043..861c1c63 100644 --- a/viewer/widgets/JFJochViewerImageStatistics.h +++ b/viewer/widgets/JFJochViewerImageStatistics.h @@ -20,6 +20,7 @@ class JFJochViewerImageStatistics : public QWidget { QLabel *spots; QLabel *valid_values; QLabel *indexed; + QLabel *multiple_lattices; QLabel *bkg_estimate; QLabel *res_estimate; QLabel *masked_pixels;