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

Properly support dd.Index in setitem #5703

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

TomAugspurger
Copy link
Member

@TomAugspurger TomAugspurger commented Dec 11, 2019

We don't want to align these. It has the same semantics as setting a dask array: we validate that the number of blocks match the number of partitions, and assume that the size of each block / partition matches.

This is a bit light on tests at the moment for invalid input (since we're re-using the dask.array implementation).

Closes #5702

cc @AlbertDeFusco

@TomAugspurger
Copy link
Member Author

I updated assert_eq a bit. We're generating key-names that are slightly too long for assert_sane_keynames (101, and the cutoff is 102).

I updated assert_eq to be able to control what it considers too long. Alternatively, I could debug why we're making longer key names.

@mrocklin
Copy link
Member

Alternatively, I could debug why we're making longer key names.

This sounds like a good idea to me if you have the time. No expectations though if the cost/benefit ratio isn't high enough.

Copy link
Member

@jrbourbeau jrbourbeau left a comment

Choose a reason for hiding this comment

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

Just a couple of nitpicks

dask/dataframe/core.py Outdated Show resolved Hide resolved
dask/dataframe/io/io.py Outdated Show resolved Hide resolved
TomAugspurger and others added 2 commits December 12, 2019 06:31
Co-Authored-By: James Bourbeau <jrbourbeau@users.noreply.github.com>
Co-Authored-By: James Bourbeau <jrbourbeau@users.noreply.github.com>
@TomAugspurger
Copy link
Member Author

This sounds like a good idea to me if you have the time. No expectations though if the cost/benefit ratio isn't high enough.

The short version is we have task names like {new-key}-{new-token}-index-{old-token}

from_pandas-8595dbb3832b7f73fae91c38aae7c616-index-da2e17dacb52404ea6cc043a671e8659

but I haven't figured out why yet, or what the old names were.

@mrocklin
Copy link
Member

We should probably just include the old token (or the old dataframe) within the tokenize call when we generate the new token. Having multiple tokens lying around is probably a bad idea.

Base automatically changed from master to main March 8, 2021 20:19
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.

Merged dataframe complains that not all divisions are known
3 participants