Skip to content

Add bounds to sample_candidates in Constraints classes. #1315

Open
chrisjonesBSU wants to merge 3 commits intomosdef-hub:developfrom
chrisjonesBSU:volume-sample-regions
Open

Add bounds to sample_candidates in Constraints classes. #1315
chrisjonesBSU wants to merge 3 commits intomosdef-hub:developfrom
chrisjonesBSU:volume-sample-regions

Conversation

@chrisjonesBSU
Copy link
Copy Markdown
Contributor

PR Summary:

This adds bounds parameters to volume constraints sample_candidates method. This lets you choose random starting points within a certain region, which adds more flexibility for different initialization.

This also changes volume.py to constraints.py to be more consistent, and it moves the file from mbuild/utils to path

PR Checklist


  • Includes appropriate unit test(s)
  • Appropriate docstring(s) are added/updated
  • Code is (approximately) PEP8 compliant
  • Issue(s) raised/addressed?
    …e file to match class names

@chrisjonesBSU chrisjonesBSU added the 2.0 Additions for mBuild 2.0 label Mar 20, 2026
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 20, 2026

Codecov Report

❌ Patch coverage is 77.77778% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.21%. Comparing base (53013f1) to head (c5e4984).

Files with missing lines Patch % Lines
mbuild/simulation.py 0.00% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #1315   +/-   ##
========================================
  Coverage    82.20%   82.21%           
========================================
  Files           59       59           
  Lines         6283     6285    +2     
========================================
+ Hits          5165     5167    +2     
  Misses        1118     1118           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 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

2.0 Additions for mBuild 2.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant