Skip to content

Improved constraints - #395

Open
rozyczko wants to merge 5 commits into
polarized_channelsfrom
improved_constraints
Open

Improved constraints#395
rozyczko wants to merge 5 commits into
polarized_channelsfrom
improved_constraints

Conversation

@rozyczko

Copy link
Copy Markdown
Member

New constraint helpers and API exposure:

  • Added constrain, constrain_equal, and unconstrain functions in the new src/easyreflectometry/constraints.py module, providing user-friendly wrappers for parameter dependencies.
  • Exposed these helpers in the public API via src/easyreflectometry/__init__.py and included them in __all__.

Documentation updates:

  • Added a comprehensive "Constraining Parameters" section to the model.md tutorial, including examples for tying parameters, functional constraints, removing constraints, and caveats.
  • Updated the assemblies library documentation to reference the new constraints tutorial section.

@rozyczko rozyczko added chore Chore changes to the code [scope] maintenance Code/tooling cleanup, no feature or bugfix (major.minor.PATCH) [priority] medium Normal/default priority labels Aug 21, 2026
@codecov

codecov Bot commented Aug 21, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.71%. Comparing base (e92b6b7) to head (fff5716).

Additional details and impacted files

Impacted file tree graph

@@                  Coverage Diff                   @@
##           polarized_channels     #395      +/-   ##
======================================================
+ Coverage               93.69%   93.71%   +0.01%     
======================================================
  Files                      51       52       +1     
  Lines                    4519     4532      +13     
======================================================
+ Hits                     4234     4247      +13     
  Misses                    285      285              
Flag Coverage Δ
integration 39.51% <69.23%> (+0.08%) ⬆️
unittests 93.71% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/easyreflectometry/__init__.py 81.81% <100.00%> (+6.81%) ⬆️
src/easyreflectometry/constraints.py 100.00% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore Chore changes to the code [priority] medium Normal/default priority [scope] maintenance Code/tooling cleanup, no feature or bugfix (major.minor.PATCH)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant