-
Notifications
You must be signed in to change notification settings - Fork 178
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
feat(protocol engine): calculate volume and height for irregular well shapes #16299
Conversation
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.
Excellent. Let's add some tests though. Remember, the code's obvious now, but somebody might accidentally change it later and if tests fail they'll know they messed up.
213b3cb
to
b2236c9
Compare
66aa20b
to
e5bdce7
Compare
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.
Would love to see an explicit isclose()
compare instead of set identity for floats.
Also, since this is a math thing, it might be worth investigating using hypothesis, but that doesn't have to be in this pr.
https://opentrons.atlassian.net/jira/software/c/projects/EXEC/list?selectedIssue=EXEC-726 |
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.
lgtm!
Overview
Previously in
frustum_helpers
, we were only handling the cases where wells had either all circular or all rectangular cross sections. If neither of these is the case, let's iterate through all the cross-sections and find the volume using the volume-of-a-frustum formula.Changelog
reject_unacceptable_heights
- this happened with 0.0Review Requests
Pls help me make sure I input the formula correctly