-
Notifications
You must be signed in to change notification settings - Fork 184
refactor(api, shared-data): Refine locating features #18672
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
Conversation
…rintAsChild feature
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## edge #18672 +/- ##
==========================================
+ Coverage 24.12% 25.31% +1.19%
==========================================
Files 3282 3284 +2
Lines 285236 285032 -204
Branches 28696 29361 +665
==========================================
+ Hits 68808 72154 +3346
+ Misses 216403 212857 -3546
+ Partials 25 21 -4
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
147f3c7
to
99cf57a
Compare
@SyntaxColoring , So one thing some of the new dummy labware migrations have shown is that some of the assumptions about footprint dimensions respective to extent totals are incorrect, and this is due to the fact that we don't factor in COFS for footprint calculations. We were just getting away with this because COFS on those definitions was always 0,0,0. I think we're correct in just deleting these tests, yeah? |
7fde47b
to
35df077
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.
Thank you! Working my way through this. First batch of comments:
This comment was marked as resolved.
This comment was marked as resolved.
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.
Love this approach. Couple requests
features=features, | ||
extents={ | ||
"total": { | ||
"backLeftBottom": {"x": 1, "y": 2, "z": 3}, |
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.
it seems bad to bake in this stuff with known-wrong numbers, might be pretty easy to forget to fix. would prefer to not have them or to gesture at having real values
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.
wait, especially since we have actual numbers in shared-data
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.
Oh wait, I totally thought this isn't a test case, whoops. Thanks.
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'm still trying to grok whether/why this is necessary, but my knee-jerk reaction is that an addressable area ought not have extents.total
because it muddies the waters. Cutout fixtures, the physical things, have extents.total
, 3D bounding boxes that the robot needs to path around. What is the "3D bounding box" around an addressable area?
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.
If an addressable area ought not have extents.total
, then it ought not have a 3D boundingBox
, which are defined in the schema as "The active area (both pipettes can reach) of this addressable area." I'm fine removing the extents
from AAs, but we should probably then remove boundingBox
from AAs in some later follow-up.
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've thought about this some more and I think I can describe more clearly now why this was bothering me. Let me start over:
With our new feature system, we have a bunch of feature
types that each define their dimensions in their own specific way. So slotFootprintAsChild
has backLeftBottom
/frontRightTop
/z
, and other features will have their own properties.
In the older addressable area system, things work differently. Each addressable area generically has a boundingBox
, and then the areaType
defines the interpretation of that bounding box.
What was bothering me was that a slotFootprintAsParent
feature covers exactly what areaType: "slot"
+ boundingBox
used to cover, so it doesn't make sense for them both to coexist (except as a temporary compromise while we port all our code).
boundingBox
might look like it's a different thing that needs to be preserved, because it's 3D and it's "the active area (both pipettes can reach)." But those differences aren't actually worth preserving for deck slots. The older addressable area system needed those nuances for things like trashes, and because deck slots shared the same boundingBox
schema as trashes, they incidentally applied to deck slots too.
Let's sync on this. Some COFS do have a positive value, which makes this test fail. EDIT: After syncing, we've decided that any time there is a non-zero COFS value, we'll have to manually review the definition and determine |
1d4e524
to
d61477a
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.
Love it, thank you. Just a handful of minor things.
5108d3f
to
5ffaa72
Compare
Works towards EXEC-77
Overview
After finalizing our approach to locating features with @SyntaxColoring , we've made some changes into how we are defining a few top level properties and how we plan to implement LFs. LFs are informally fleshed out in this doc now. This PR serves to lay the groundwork before diving into adding each locating feature. It's definitely easiest to view this PR commit-by-commit, as it's mainly a lot of noise.
There's nothing too noteworthy here as future PRs that actually add each locating feature will clarify this work, however, the "footprint" extents, which represent the extents confined to a slot, are now considered a locating feature,
slotFootprintAsChild
. We don't do anything with this feature as of yet.There are several scripts created and/or modified to migrate the code. These are in our work's scripts repo under a few branches:
migrate_to_extents_v3
,update_deck_defs
, andupdate_module_defs
. It's important to note that there is some duplication in definition fields now. It initially seemed like we could use pydantic's virtual properties to deriveextents
and some locating features, but alas,ModuleDefinition
andDeckDefinitionV5
are TypedDicts, and it's quite a bit of effort to migrate these to pydantic, and more importantly, these wouldn't work with our typescript code anyway. I think the actual solution is to removeboundingBox
andcornerOffsetFromSlot
from related defs, see EXEC-1625.89aeb4e adds some more dummy labware defs so we can properly test all planned locating features via the snapshot script as we add each new LF.
Test Plan and Hands on Testing
Changelog
footprint
logic to a locating feature.locatingFeaturesAsParent
tofeatures
.locatingFeaturesAsChild
.Review requests
slotFootprintAsChild
as required for each labware. I think this is correct, but do others feel differently?Risk assessment
none