issue_comments
10 rows where author_association = "CONTRIBUTOR" and issue = 173612265 sorted by updated_at descending
This data as json, CSV (advanced)
Suggested facets: reactions, created_at (date), updated_at (date)
issue 1
- Hooks for custom attribute handling in xarray operations · 10 ✖
id | html_url | issue_url | node_id | user | created_at | updated_at ▲ | author_association | body | reactions | performed_via_github_app | issue |
---|---|---|---|---|---|---|---|---|---|---|---|
413723632 | https://github.com/pydata/xarray/issues/988#issuecomment-413723632 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDQxMzcyMzYzMg== | dopplershift 221526 | 2018-08-17T00:33:47Z | 2018-08-17T00:33:47Z | CONTRIBUTOR | I see your argument, but here's my problem. In this future where things work (assuming that NEP is accepted), and I want distributed computing with dask, units, and xarray, I have: xarray wrapping a pint array wrapping a dask array. I like composition, but that level of wrapping...feels wrong to me for some reason. Is there some elegance I'm missing here? (Other than array-like things playing together.) And then I still need hooks in xarray so that when pint does a calculation, it can update the metadata in xarray; so it feels like we're back here anyway. |
{ "total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
413360749 | https://github.com/pydata/xarray/issues/988#issuecomment-413360749 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDQxMzM2MDc0OQ== | dopplershift 221526 | 2018-08-15T22:36:21Z | 2018-08-15T22:36:21Z | CONTRIBUTOR | @shoyer I know elsewhere you said you weren't sure about this idea any more, but personally I'd like to push forward on this idea. Do you have problems with this approach we need to resolve? Any chance you have some preliminary code? I think this is the right way to solve the unit issue in XArray, since at it's core unit handling is mostly a metadata operation. |
{ "total_count": 2, "+1": 2, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
283531258 | https://github.com/pydata/xarray/issues/988#issuecomment-283531258 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI4MzUzMTI1OA== | gerritholl 500246 | 2017-03-02T01:51:08Z | 2017-03-02T01:51:08Z | CONTRIBUTOR | We do often deal with those in my line of work as well, I just happen not to right now. But time is the one thing that already carries units, doesn't it? One can convert between various |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
283515941 | https://github.com/pydata/xarray/issues/988#issuecomment-283515941 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI4MzUxNTk0MQ== | gerritholl 500246 | 2017-03-02T00:22:18Z | 2017-03-02T00:22:18Z | CONTRIBUTOR | Good point. I didn't think of that; my coordinates happen to be either time or unitless, I think. How common is it though that the full power of a unit library is needed for coordinates? I suppose it arises with indexing, i.e. the ability to write When it's a bit more polished I intend to publish it somewhere, but currently several things are missing ( |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
282273509 | https://github.com/pydata/xarray/issues/988#issuecomment-282273509 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI4MjI3MzUwOQ== | gerritholl 500246 | 2017-02-24T11:49:42Z | 2017-02-24T11:49:42Z | CONTRIBUTOR | I wrote a small recipe that appears to contain basic functionality I'm looking for. There's plenty of caveats but it could be a start, if such an approach is deemed desirable at all. ``` from common import ureg # or ureg = pint.UnitRegistry() import operator import xarray class UnitsAwareDataArray(xarray.DataArray): """Like xarray.DataArray, but transfers units """
for tp in ("add", "sub", "mul", "matmul", "truediv", "floordiv", "mod", "divmod"): meth = "{:s}".format(tp) def func(self, other, meth=meth, tp=tp): x = getattr(super(UnitsAwareDataArray, self), meth)(other) return self._apply_binary_op_to_units(getattr(operator, tp), other, x) func.name = meth print(func, id(func)) setattr(UnitsAwareDataArray, meth, func) del func ``` |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
282081462 | https://github.com/pydata/xarray/issues/988#issuecomment-282081462 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI4MjA4MTQ2Mg== | gerritholl 500246 | 2017-02-23T18:41:19Z | 2017-02-23T18:41:19Z | CONTRIBUTOR | Is it not? The documentation says it's new in numpy 1.11 and we're at 1.12 now. I tried to make a small units-aware subclass of ``` class UnitsAwareDataArray(xarray.DataArray): """Like xarray.DataArray, but transfers units """
``` |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
282070342 | https://github.com/pydata/xarray/issues/988#issuecomment-282070342 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI4MjA3MDM0Mg== | gerritholl 500246 | 2017-02-23T18:00:32Z | 2017-02-23T18:00:46Z | CONTRIBUTOR | Apparently |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
282063849 | https://github.com/pydata/xarray/issues/988#issuecomment-282063849 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI4MjA2Mzg0OQ== | gerritholl 500246 | 2017-02-23T17:37:18Z | 2017-02-23T17:37:18Z | CONTRIBUTOR | I would say using the ``` ureg is a pint unit registryy = a/b y.attrs["units"] = ureg(a.attrs["units"]) / ureg(b.attrs["units"]) ``` which if I understand the codebase correctly could be added to |
{ "total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
243974692 | https://github.com/pydata/xarray/issues/988#issuecomment-243974692 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI0Mzk3NDY5Mg== | pwolfram 4295853 | 2016-09-01T04:44:21Z | 2016-09-01T04:44:21Z | CONTRIBUTOR | +1 on requiring attribute handlers to be registered at a single location because this will make for cleaner code long term. |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 | |
243952679 | https://github.com/pydata/xarray/issues/988#issuecomment-243952679 | https://api.github.com/repos/pydata/xarray/issues/988 | MDEyOklzc3VlQ29tbWVudDI0Mzk1MjY3OQ== | robintw 296686 | 2016-09-01T01:41:51Z | 2016-09-01T01:41:51Z | CONTRIBUTOR | I also prefer an approach that doesn't use context managers: I agree with @darothen's comments about the issues with their use. Regardless of the exact implementation, I am strongly in favour of this functionality being added to xarray - I can already think of a number of very useful ways I could use it! |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
Hooks for custom attribute handling in xarray operations 173612265 |
Advanced export
JSON shape: default, array, newline-delimited, object
CREATE TABLE [issue_comments] ( [html_url] TEXT, [issue_url] TEXT, [id] INTEGER PRIMARY KEY, [node_id] TEXT, [user] INTEGER REFERENCES [users]([id]), [created_at] TEXT, [updated_at] TEXT, [author_association] TEXT, [body] TEXT, [reactions] TEXT, [performed_via_github_app] TEXT, [issue] INTEGER REFERENCES [issues]([id]) ); CREATE INDEX [idx_issue_comments_issue] ON [issue_comments] ([issue]); CREATE INDEX [idx_issue_comments_user] ON [issue_comments] ([user]);
user 4