Skip to content

Support Ramba distributed arrays. #5970

Open

Description

@DrTodd13

I would like to see Ramba distributed arrays (https://github.com/Python-for-HPC/ramba) supported in xarray as an alternative to Dask arrays.

Activity

  1. DrTodd13 commented on Nov 12, 2021

    @DrTodd13
    Author

    @TomNicholas Please add an in-progress label for the associated PR I opened.

  2. DrTodd13 commented on Nov 17, 2021

    @DrTodd13
    Author

    @TomNicholas @keewis

    import ramba
    import numpy as np
    import xarray
    
    ra1 = ramba.random.randn(10,20)
    xa1 = xarray.DataArray(ra1)
    np1 = xa1.data.asarray()
    print("np1:", np1)
    print("xa1.data:", xa1.data, type(xa1.data), xa1.data.dtype, type(xa1.data.dtype))
    
    xa2 = xa1 + 10.0
    xa22 = xa2 * 7.1
    xa3 = np.sin(xa22)
    xa4 = xa3.transpose()
    xa5 = xa4.sum()
    print("xa5:", xa5, type(xa5))

    Using the __array_function__ API and other functions (and not my ill-conceived PR that added ramba to xarray for direct support) , I was able to run the above example. Originally, there were a couple parts of the NumPy API that ramba didn't previously support and I added those. The most difficult of those was 0d arrays. Those are working at least well enough now for the above example so now like I said in the meeting, I'd like even more complicated examples to explore.

    Can anybody suggest or provide one?

  3. dcherian commented on Nov 24, 2021

    @dcherian
    Contributor

    Sorry for the late reply @DrTodd13 .

    I think #4972 is the real answer here. It looks like @keewis has it mostly working. It hasn't been merged because test_sparse isn't passing yet.

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