Improved constraints - #395
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## polarized_channels #395 +/- ##
======================================================
+ Coverage 93.69% 93.89% +0.20%
======================================================
Files 51 54 +3
Lines 4519 5098 +579
======================================================
+ Hits 4234 4787 +553
- Misses 285 311 +26
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
rozyczko
added a commit
that referenced
this pull request
Sep 1, 2026
* initial version * added magnetic SLD profile * added magnetic parameters * ruff * code review comments addressed * code review fixes for Phase 2, added notebook * ruff * PR code review comments * fixed polarized file load issue * enable magnetic layers * new LayerMagnetism component * ruff * ruff on notebooks * bind calculator to model for performance * attempt at fixing package testing * package tests only on master * don't run ruff twice * code review fixes * added polarized fitting example/notebook * fixed default sample generation * improved wording in the magnetic fitting notebook * move the most expensive test to integration * Improved constraints (#395) * improved handling of constraints * ruff * wording * additional cell in a notebook to showcase the new way of doing constraints * fixed notebook * initial checkin * .bounds -> min, max * updates so the code is self-contained and doesn't depend on changes to core * Code review comments addressed * Updated docs (#398) * move everything to MKDocs minor updates/fixes after code review * ruff fix for notebook * Fix broken conflict resolutions from develop merge The merge of develop (2042778) left two files with damaged conflict resolutions: magnetism.ipynb gained a corrupt hybrid cell (invalid notebook JSON, duplicate cell id) and project.py gained a duplicated copy of the spin-asymmetry method block with an orphaned method body. Both files are restored to the branch-side version, which already contained everything develop had for them. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * code review issues addressed * removed explicit EasyCore constraints factory reliance --------- Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New constraint helpers and API exposure:
constrain,constrain_equal, andunconstrainfunctions in the newsrc/easyreflectometry/constraints.pymodule, providing user-friendly wrappers for parameter dependencies.src/easyreflectometry/__init__.pyand included them in__all__.Documentation updates:
model.mdtutorial, including examples for tying parameters, functional constraints, removing constraints, and caveats.