DM-36395: Support incremental redefinition of multi-snap visits#447
Merged
DM-36395: Support incremental redefinition of multi-snap visits#447
Conversation
a5df38b to
50f4b4a
Compare
ktlim
approved these changes
Apr 28, 2023
| instrument=first.instrument, | ||
| ) | ||
| ) | ||
| records.difference_update(set(exposures_in_group)) |
Contributor
There was a problem hiding this comment.
Seems kind of a shame to have this by group, then merge it all into one big list, then group again. But I guess that keeps the interfaces simple.
Member
Author
There was a problem hiding this comment.
Yes, it does, although I think there is a proposal to remove this subclass completely in #453 so it's not worth trying to make it more efficient.
da4a605 to
b5f370b
Compare
We have to close the Pool after we are done with it.
Previously the multi-snap visit was only defined when the second snap arrived. Now we can define the multi-snap visit even if we only have one snap (so we get two visits defined). When the second snap arrives there will be three visits and the multi-snap visit will be updated if --update-records is enabled.
…ries Implies update-records and so should be used when exposures for multi-snap visits are being ingested incrementally whilst continually updating the visit definition.
We had not been updating it as new options were added.
This is the true incremental mode where we ingest a new file and immediately run visit definition.
Since we know that it's a single dataId we can make it more efficiently with DataCoordinate rather than querying registry for a single value.
Rather than asking for every exposure in the visit, first work out which exposures we have and then determine the missing sequence numbers and query for those.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Checklist
doc/changes