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

Remove assertion in HighLevelGraph constructor #4699

Merged
merged 2 commits into from Apr 15, 2019

Conversation

Projects
None yet
2 participants
@mrocklin
Copy link
Member

commented Apr 14, 2019

This was not necessary and causes significant slowdowns in
HighLevelGraph construction.

See dask/distributed#2611

  • Tests added / passed
  • Passes flake8 dask
Remove assertion in HighLevelGraph constructor
This was not necessary and causes significant slowdowns in
HighLevelGraph construction.

See dask/distributed#2611
@mrocklin

This comment has been minimized.

Copy link
Member Author

commented Apr 14, 2019

The rest of the time is mostly in the construction of layers and deps in HighLevelGraph.from_collections. We end up recreating the full dict each time. Previously I recall that @jcrist had a clever solution with a list of dicts perhaps? My guess is that at some point that was removed (possibly for ShareDict? probably by me?). I'm surprised that this didn't trigger issues earlier on.

@jcrist

This comment has been minimized.

Copy link
Member

commented Apr 14, 2019

Previously I recall that @jcrist had a clever solution with a list of dicts perhaps?

Originally delayed was implemented with a list-of-dicts approach to prevent the merging-on-every-task issue. There's likely a way we can restructure this to bring back that performance (perhaps with a change to HighLevelGraph, or a subclass optimized for delayed objects, idk).

@jcrist

This comment has been minimized.

Copy link
Member

commented Apr 15, 2019

LGTM, merging.

@jcrist jcrist merged commit 918854d into dask:master Apr 15, 2019

3 checks passed

codecov/project 91.24% (target 90%)
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@jcrist jcrist deleted the mrocklin:dask.delayed-performance branch Apr 15, 2019

asmith26 added a commit to asmith26/dask that referenced this pull request Apr 22, 2019

Remove assertion in HighLevelGraph constructor (dask#4699)
* Remove assertion in HighLevelGraph constructor

This was not necessary and causes significant slowdowns in
HighLevelGraph construction.

See dask/distributed#2611

* remove more assertions

jorge-pessoa pushed a commit to jorge-pessoa/dask that referenced this pull request May 14, 2019

Remove assertion in HighLevelGraph constructor (dask#4699)
* Remove assertion in HighLevelGraph constructor

This was not necessary and causes significant slowdowns in
HighLevelGraph construction.

See dask/distributed#2611

* remove more assertions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.