Skip to content
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

Include resource, datum in filler_state. #185

Merged
merged 1 commit into from
Sep 1, 2020

Conversation

danielballan
Copy link
Member

The filler_state is a threadsafe way to side-band information into
"coersion" functions that, for example, return the data as a dask array.
We added this so that the functions could have access to shape via the
descriptor. In some cases we also need access to the resource to do that
successfully. In the future, when we support variable-length chunks, we
may also want access to the datum.

Prototyped and interactively tested against FXI data in
https://gist.github.com/danielballan/b4fccac29cd77e7bdfd93eba775d9b81

The `filler_state` is a threadsafe way to side-band information into
"coersion" functions that, for example, return the data as a dask array.
We added this so that the functions could have access to `shape` via the
descriptor. In some cases we also need access to the resource to do that
successfully. In the future, when we support variable-length chunks, we
may also want access to the datum.

Prototyped and interactively tested against FXI data in
https://gist.github.com/danielballan/b4fccac29cd77e7bdfd93eba775d9b81
@danielballan
Copy link
Member Author

This whole feature feels like a giant hack, so I am slightly reluctant to extend it, but this PR constitutes a small, natural, and somewhat anticipated extension. When we rethink and simplify how bluesky handles external data (see #156) this mechanism will likely not be needed, but in the short term is a very helpful escape hatch for making data readable.

Copy link
Member

@cryos cryos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems reasonable to me, but I know you and @tacaswell have more background. It will be great to get at my angles ;-)

@tacaswell tacaswell merged commit 8f33606 into bluesky:master Sep 1, 2020
@danielballan danielballan deleted the more-filler-state branch September 1, 2020 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants