-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Additions for #327 - Enable DesignCosts
in WeightedCost
#413
Conversation
…s error checking for different problem class, general refactor for improved clarity
…inimising, adds integration tests
# Conflicts: # examples/scripts/spm_weighted_cost.py # pybop/costs/_likelihoods.py # pybop/costs/_weighted_cost.py # pybop/costs/base_cost.py # pybop/costs/fitting_costs.py # tests/unit/test_cost.py
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #413 +/- ##
===========================================
- Coverage 98.28% 98.24% -0.04%
===========================================
Files 46 46
Lines 2907 2910 +3
===========================================
+ Hits 2857 2859 +2
- Misses 50 51 +1 ☔ View full report in Codecov by Sentry. |
DesignCosts
in WeightedCost
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made some changes to clarify when each problem should be evaluated. Please check and see what you think! I also updated the output messages in spme_max_energy.py.
Happy to discuss further if you like, or proceed with this version.
…global update_capacity() usage, add tests for side-effects on underlying objects
Hi @NicolaCourtier - I've made a few updates, happy to discuss if you see anything worriesome, otherwise I'll merge :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please just amend the attribute description, otherwise looks good to me, thanks!
# Conflicts: # pybop/costs/_likelihoods.py # pybop/costs/_weighted_cost.py # pybop/costs/base_cost.py # pybop/costs/design_costs.py
Decreased coverage due to flaky test is fixed in #411. Merging as is. |
Description
This PR implements the following:
DesignCost
class intoWeightedCost
structure with support for sharing a single problem classWeightedCost
with design and fitting problemsIssue reference
Fixes #327
Review
Before you mark your PR as ready for review, please ensure that you've considered the following:
Type of change
Key checklist:
$ pre-commit run
(or$ nox -s pre-commit
) (see CONTRIBUTING.md for how to set this up to run automatically when committing locally, in just two lines of code)$ nox -s tests
$ nox -s doctest
You can run integration tests, unit tests, and doctests together at once, using
$ nox -s quick
.Further checks:
Thank you for contributing to our project! Your efforts help us to deliver great software.