Skip to content

multiple contrasts #425, phase 2 - #351

Merged
rozyczko merged 4 commits into
developfrom
425-multiple-contrasts
Oct 12, 2026
Merged

rozyczko merged 4 commits into
developfrom
425-multiple-contrasts

Conversation

@rozyczko

Copy link
Copy Markdown
Member

This pull request introduces significant improvements to the handling of multiple contrasts and experiment-model associations, as well as enhancements to fitting logic and error handling in the analysis backend. It also adds new demo datasets and updates the user interface to better support advanced fitting workflows. The most important changes are grouped below.

Multiple Contrasts and Experiment-Model Management:

  • Added support for associating each experiment with a specific model, including new API methods and properties for managing these associations, tracking included experiments in fits, and updating experiment selection when experiments are removed (setModelOnExperiment, experimentsModelIndices, experimentsIncludedInFit, setExperimentIncludedInFit, follow_removed_experiments)

Fitting Logic and Error Handling Improvements:

  • Refactored fitting logic to use a prepared fit object for improved thread safety and clarity, and enhanced the recording of fit results and error/cancellation handling
  • Improved pre-fit error checking to handle minimizers that require finite bounds, and ensured only unique, enabled, free parameters are checked

API and Property Additions:

  • Added new properties and methods for minimizer settings and fit objectives in the mock backend, preparing for expanded fitting options in the UI (fitObjectives, fitObjective, minimizerOptions, etc.)

Other Enhancements:

  • Added color coding for experiments with no model and improved reporting of model names and colors for experiments.
  • Extended the fit results dictionary to include more detailed fit statistics and dataset-level results.

@rozyczko rozyczko added [scope] enhancement Adds/improves features (major.MINOR.patch) [priority] high Should be prioritized soon labels Oct 10, 2026
@rozyczko
rozyczko force-pushed the 425-multiple-contrasts branch from 5286e10 to 840e4a1 Compare October 12, 2026 08:15
@rozyczko
rozyczko merged commit e3a640a into develop Oct 12, 2026
28 checks passed
@rozyczko
rozyczko deleted the 425-multiple-contrasts branch October 12, 2026 08:39
rozyczko added a commit that referenced this pull request Oct 19, 2026
* accordion groups.
combine layer editor with model editor

* added fixes to other lists

* PR review fixes

* fixed treatment of multilayers

* duplicate/add layer should not append after subphase

* force collapse explicitly

* fix for assembly removal (+test)

* more PR related fixes

* added two standard icons for docs/issues

* can't move subphase and superphase. Can't replace these as well.

* remove redundant section in the report

* Implement scatter series for measured data and synchronize colors with
current experiment

* missed file

* Fixed issue with Sample tab
Added different ways to show experimental data (dots, circles, line)

* properly scaled residuals display

* zero display for residuals, initialization errors fixed.

* replaced `undo` icon with `home` for chart axis reset

* react to changed resolution % in the exp tab

* use easyapplication

* moved to EasyApplication module (#305)

* moved to EasyApplication module

* fixed test

* 1.2.0 -> 1.3.0

* only released modules

* updated release date and changelog

* summary prettified (#308)

* summary prettified

* minor fixes after code review

* make links clickable (#310)

* Bayesian analysis (#309)

* initial version.

* updates to the parameter passing

* nice Bayesian sub-tabs display

* add parameter names, add cancellation of sampling, add number of steps
in status bar

* correct parenting

* added required dependencies and modified Fit Status dialog

* add save button to the plots

* added tests for bayesian logic

* attempt at getting posterior median and credibility intervals on the
main chart

* enable/disable legends on bayesian sampling

* reload bumps images on recalculation. Use different caption when running
sampling

* updates and changes, new unit tests and GUI elements. New colors

* fixed typo

* actually sample multiple experiments

* nicer plots

* trace plot - nice display

* updated plots

* changes for the new EasyList based reflectometry-lib

* changes after updates to core

* unit test fixed

* weird conflict

* Bayesian fixes (#332)

* removed MD file, fixed #312

* fixed #313

* Fixed issues #312 - #322
Temporarily commented out code signing

* Addressed issues #323, #324, #325, #326

* addressed #327, #328, #329

* update paths in the Summary textboxes

* minor updates based on the new ERL

* summary results now show correct GoF #375

* reparent to released lib

* fixes from code review (#334)

* updated versioning (#335)

* Preparation for the release (#333) (#336)

* Polar channels (#338)

* initial version - dirty

* reparent ERL

* Code review comments addressed

* fix for file load

* added magnetic layers

* Added polarized experiment import and display

* bugs and issues addressed

* make polarized channels more performant

* minor fixes for tabbed elements, improved wording

* code review changes

* update the sample page with fitting results

* arviz follies

* added control over reflectivity profiles for up-up and down-down cases

* Added Summary docs, added PICKLE option for saving MPL plots

* spin asymmetry should be positive

* don't show errors for dependent parameters

* show correct error value

* Improved constraints (#339)

* initial commit

* updated constraints

* code review comments addressed

* show tooltip on long parameter names

* reparent reflectometry-lib to develop

* Sample layer visualization (#341)

* initial version

* bugfix: single-layer sample is misclassified and reports zero total
thickness

* Updated docs (#342)

* initial version

* bugfix: single-layer sample is misclassified and reports zero total
thickness

* updated docs

* Refactor SLD and molecular weight dependency in app structure (#343)

* changes for SLD <-> molecular weight dependence

* reparent the app

* attached functionality to the material editor rows

* updated docs

* added github-instructions for easier maintenance

* code review issues addressed

* disable density/formula fields when not directly using them

* code review comments addressed

* make molecular weight a descriptor

* reparent the library

* 401 project save (#344)

* Improved project tracking, #401

* backend state added

* CR review fixes

* fixed density subdialog enablement. Reparented lib to develop

* attempt at fixing some visual issues with the model editor #407 (#345)

* HOTFIX for native Linux dialogs

* Minor fixes (#349)

* added testing workflow

* fix tests

* fixes to windows tests

* fixed stuck UI results in Bayesian

* remove Qt imports/deps from Logic (Backend)

* fixed constraints de/serialization

* maintain consistence after model/experiment deletion

* P1 level issues addressed. Point 7 in the 311-REMAINING-ISSUES.md list

* addressed 9. Circular Plotting1d ↔ Analysis coupling from the main doc

* reparent the library

* PR review fixes

* reparent lib dependency

* attempt at fixing visa-related opengl issues (#347)

* attempt at fixing visa-related opengl issues

* improved handling of QTWEBENGINE rendering types

* added fit settings controls (#350)

* added fit settings controls

* addressed code review comments

* update the library branch

* multiple contrasts #425, phase 2 (#351)

* Added fixes for multiple contrasts handling. Also, added example files
in examples/ directory

* CR review issues addressed

* added docs on multiple contrasts. Fixed issue with overflowing text

* back to `develop` for the lib

* Add spin arrows (#346)

* added arrows for magnetic moment visualization

* fixed reflectometry-lib branch

* removed arrow from SLD plot. Fixed smaller issues

* replace circular control with a slider

* removed dependence on reflectometry-lib modifications

* Variable resolution changes from #425, issue #3 (#352)

* Variable resolution changes from #425, issue #3

* CR fixes

* added fixes to magnetism as per #425, section 3 (#354)

* added fixes to magnetism as per #425, section 3

* code review comments addressed

* reparent to develop

* updated MD files (#353)

* preparations for the release (#357)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[priority] high Should be prioritized soon [scope] enhancement Adds/improves features (major.MINOR.patch)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant