Skip to content

Conversation

@matthiasdiener
Copy link
Collaborator

@matthiasdiener matthiasdiener commented Sep 25, 2024

Followup of inducer/pytato#548

Implements part of inducer/pytato#547

TODOs:

  • add to docs?

Please squash

@matthiasdiener matthiasdiener self-assigned this Sep 25, 2024
import arraycontext.impl.pyopencl.taggable_cl_array as tga
if isinstance(expr.data, tga.TaggableCLArray):
data = expr.data.get()
return DataWrapper(
Copy link
Collaborator Author

@matthiasdiener matthiasdiener Sep 25, 2024

Choose a reason for hiding this comment

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

@majosm asked in inducer/pytato#548 (comment)

Can we make this return an instance of a new DataWrapper type that can __hash__ by data instead of id? That would remove the need for data wrapper deduplication, if I understand the intended use of these mappers correctly.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Not sure; in that case, we probably should probably also override the EqualityComparer, otherwise we would get a lot of hash collisions when caching.

@matthiasdiener
Copy link
Collaborator Author

This is ready for a first review; I'm not sure what to do about the pylint errors.

@inducer
Copy link
Owner

inducer commented Oct 11, 2024

Please do add these to the docs, and then this should be ready to go.

@matthiasdiener matthiasdiener marked this pull request as ready for review October 11, 2024 23:16
@matthiasdiener
Copy link
Collaborator Author

Please do add these to the docs, and then this should be ready to go.

Added in b20d359

@inducer inducer enabled auto-merge (squash) November 14, 2024 14:31
@inducer inducer merged commit dee0ca4 into inducer:main Nov 14, 2024
12 checks passed
@matthiasdiener matthiasdiener deleted the transfermappers branch November 14, 2024 14:44
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.

2 participants