html_url,issue_url,id,node_id,user,created_at,updated_at,author_association,body,reactions,performed_via_github_app,issue https://github.com/pydata/xarray/issues/3245#issuecomment-873481034,https://api.github.com/repos/pydata/xarray/issues/3245,873481034,MDEyOklzc3VlQ29tbWVudDg3MzQ4MTAzNA==,14808389,2021-07-03T22:53:08Z,2021-07-03T22:53:08Z,MEMBER,"right, I would leave these methods to xarray extension libraries like `cupy-xarray` or `pint-xarray`. I assume you meant `.as_pint` because adding `.to_pint` does not make much sense: following the naming convention from above, `.to_*` should return the duck array, which would make it an alias of either `.data` or the duck array's constructor called on `.data`.","{""total_count"": 1, ""+1"": 1, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,484240082 https://github.com/pydata/xarray/issues/3245#issuecomment-780923750,https://api.github.com/repos/pydata/xarray/issues/3245,780923750,MDEyOklzc3VlQ29tbWVudDc4MDkyMzc1MA==,14808389,2021-02-17T23:33:05Z,2021-02-17T23:33:05Z,MEMBER,"I agree, this would be useful. Ideally, that would be implemented by deferring to the data, for example by calling the data's `to_numpy` method (so duck array libraries or duck array integration libraries can customize that), falling back to `np.asarray(data)`.","{""total_count"": 1, ""+1"": 1, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,484240082 https://github.com/pydata/xarray/issues/3245#issuecomment-661094939,https://api.github.com/repos/pydata/xarray/issues/3245,661094939,MDEyOklzc3VlQ29tbWVudDY2MTA5NDkzOQ==,14808389,2020-07-20T15:02:02Z,2020-07-20T15:02:02Z,MEMBER,"Sounds good. It might be worth discussing the general strategy for the support of this kind of duck array (sparse, cupy and others) in the dev call on Wednesday.","{""total_count"": 4, ""+1"": 4, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,484240082 https://github.com/pydata/xarray/issues/3245#issuecomment-661062797,https://api.github.com/repos/pydata/xarray/issues/3245,661062797,MDEyOklzc3VlQ29tbWVudDY2MTA2Mjc5Nw==,14808389,2020-07-20T14:08:35Z,2020-07-20T14:09:33Z,MEMBER,"we currently don't really encourage this way of using accessors (especially using too many of these, see https://github.com/pydata/xarray/issues/1080#issuecomment-258582609 and https://github.com/pydata/xarray/issues/1080#issuecomment-258680571), but you *can* use `register_*_accessor` to register functions: ```python @xr.register_dataarray_accessor(""as_cupy"") def _(da): def as_cupy(self, ...): # ... return da return as_cupy ```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,484240082