Skip to content

Consolidation between Dask with/without Distributed #3237

Closed

Description

@jakirkham

Copied from this comment:

One of the things I've been thinking about has been how we seem to have two ways to do Python threaded work.

A user can choose to just use Dask (w/o Distributed) or they can use Dask w/Distributed, but request that no additional processes be created. These seem to be overlapping quite a bit (though maybe not enough ;) and it might be better to just pick one. If we do pick one, we'd want to do that before 1.0 as it would be a breaking change. Though perhaps there is a way to ease into this choice.

Naively would suggest we drop the Dask (w/o Distributed) case. This would allow users and developers to be reasonably confident that there is always some Client working and would give guarantees about what dask.get and friends mean, which is a nice guarantee in loads of cases. Though maybe there are reasons not to go this way (e.g. circular dependency).

cc @shoyer

Activity

  1. mrocklin commented on Mar 1, 2018

    @mrocklin
    Member

    @shoyer brought up dependency issues, which I agree with. There are downstream projects that are comfortable depending on us now but probably would not want to do this with tornado along as well.

    In practice the simplicity of the single-machine task scheduler makes it, in my mind, essential. This not only helps testing and algorithm development, but also aids significantly in debugging. Often when hard problems arise I ask people to try their computation on many different schedulers and report back what happens. This is surprisingly helpful in isolating issues.

  2. jakirkham commented on Mar 2, 2018

    @jakirkham
    MemberAuthor

    Sure, admittedly this may be totally unachievable, don't really know, but to what extent can Distributed soften its dependencies? What about Tornado (since this dependency was brought up) is problematic for downstream?

    Can see that there would be value in comparing several different schedulers for debugging purposes. Though would think that the Distributed scheduler would be much better for doing that debugging given the array of diagnostic information it provides and the fact that using multiple processes can be turned on and off. That said, not doing enough debugging of other users' issues in this area to say. Are there particular kinds of issues that the single machine scheduler (or Distributed scheduler using Python threads) avoid?

    Perhaps instead of making this a pro/con discussion, it would be more informative to learn exactly in what ways the single machine scheduler differs or is similar to running Client(processes=False). Would it be possible to have the single machine scheduler accessible from some slimmed down version of the same Client API for instance? What API could be available and what API would be lost? What notable changes would occur to how the API performs?

  3. mrocklin commented on Mar 2, 2018

    @mrocklin
    Member

    That said, not doing enough debugging of other users' issues in this area to say. Are there particular kinds of issues that the single machine scheduler (or Distributed scheduler using Python threads) avoid?

    The single-machine scheduler is just a much simpler system. It's 1000 lines rather than 10000 lines. People can understand it after a day of study. The single-threaded variant is of particular use due to tools like pdb and cProfile.

    Sure, admittedly this may be totally unachievable, don't really know, but to what extent can Distributed soften its dependencies?

    It needs a concurrent framework with coroutines. Today this is tornado, asyncio, or one of the newer systems like curio or trio. Tornado is, I believe, the easiest to depend upon.

    At this point though I don't see any future path in which enough incentive is placed to displace us from tornado. The development cost would be moderate and the gains are not large enough that I would expect anyone to volunteer to do it. I also think that, among the options today, Tornado is possibly the best.

    Making a client-like API based on concurrent.futures might be possible. It would again require some investment though and I haven't seen an entity (volunteer developer or commercial entity) that has the combined interest and skill to implement this. I would love to be shown wrong here. A clever graduate student could accomplish this with a few months of dedicated learning and work.

  4. jakirkham commented on Apr 10, 2018

    @jakirkham
    MemberAuthor

    cc-ing @jcrist (as it sounded like you also have some thoughts on this topic from our discussion this evening)

  5. dhirschfeld commented on May 2, 2018

    @dhirschfeld

    I'm obviously not very concerned about dependencies, but are they really that much of a concern these days?

    If you use dask.dataframe it depends on pandas which has a huge list of complex compiled dependencies:

    conda install pandas + standard deps
        beautifulsoup4:  4.6.0-py36_0
        blosc:           1.14.3-he51fdeb_0
        bottleneck:      1.2.1-np112py36_0
        bzip2:           1.0.6-vc14_1
        ca-certificates: 2018.4.16-0
        certifi:         2018.4.16-py36_0
        cycler:          0.10.0-py36_0
        freetype:        2.8.1-vc14_0
        hdf5:            1.10.1-vc14_2
        icc_rt:          2018.0.2-0
        icu:             58.2-vc14_0
        intel-openmp:    2018.0.0-8
        jinja2:          2.10-py36h292fed1_0
        jpeg:            9b-vc14_0
        kiwisolver:      1.0.1-py36h12c3424_0
        libiconv:        1.15-h1df5818_7
        libpng:          1.6.34-vc14_0
        libxml2:         2.9.8-vc14_0
        libxslt:         1.1.32-vc14_0
        lxml:            4.2.1-py36heafd4d3_0
        lzo:             2.10-vc14_0
        markupsafe:      1.0-py36_0
        matplotlib:      2.2.2-py36h153e9ff_0
        mkl:             2018.0.2-1
        numexpr:         2.6.4-py36h30784b8_0
        numpy:           1.12.1-py36hf30b8aa_1
        openssl:         1.0.2o-vc14_0
        pandas:          0.22.0-py36h6538335_0
        pip:             10.0.1-py36_0
        pyodbc:          4.0.23-py36h6538335_0
        pyparsing:       2.2.0-py36_0
        pyqt:            5.6.0-py36_2
        pytables:        3.4.3-py36he6f6034_0
        python:          3.6.5-h0c2934d_0
        python-dateutil: 2.7.2-py36_0
        pytz:            2018.4-py36_0
        qt:              5.6.2-vc14_1
        scipy:           1.0.1-py36hce232c7_0
        setuptools:      39.1.0-py36_0
        sip:             4.19.8-py36h6538335_0
        six:             1.11.0-py36h4db2310_1
        snappy:          1.1.7-vc14_1
        sqlalchemy:      1.2.7-py36ha85dd04_0
        tornado:         5.0.2-py36_0
        vc:              14-0
        vs2015_runtime:  14.0.25420-0
        wheel:           0.31.0-py36_0
        wincertstore:    0.2-py36_0
        xlsxwriter:      1.0.4-py36_0
        zlib:            1.2.11-vc14_0
    

    Sure, you can cut down a bit on those dependencies but are there actual users out there who would be running a stripped down pandas with dask?

    Maybe users of dask.array are more dependency sensitive?

  6. mrocklin commented on Oct 24, 2018

    @mrocklin
    Member

    I'm going to close this. The local scheduler is very valuable to a large number of conservative developers. I suspect that many libraries that directly depend on us today would not do so if it required depending on the distributed scheduler.

  7. mrocklin commented on Oct 24, 2018

    @mrocklin
    Member

    If people still have strong thoughts the other way and plan to continue the conversation feel free to reopen. This seems to have gone stale for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions