home / github

Menu
  • Search all tables
  • GraphQL API

issues

Table actions
  • GraphQL API for issues

3 rows where milestone = 799012, repo = 13221727 and type = "issue" sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: user, comments, author_association, created_at (date), updated_at (date), closed_at (date)

type 1

  • issue · 3 ✖

state 1

  • closed 3

repo 1

  • xarray · 3 ✖
id node_id number title user state locked assignee milestone comments created_at updated_at ▲ closed_at author_association active_lock_reason draft pull_request body reactions performed_via_github_app state_reason repo type
46022646 MDU6SXNzdWU0NjAyMjY0Ng== 254 order matters when doing comparisons against scalar xray objects WeatherGod 291576 closed 0   0.3.1 799012 2 2014-10-16T19:03:11Z 2014-10-23T06:43:30Z 2014-10-23T06:43:23Z CONTRIBUTOR      

Working on some bounding box extraction code, I computed a bounding box by taking mins and maxes of the coordinates from an xray object resulting in a dictionary of scalar xray objects. When comparing an xray DataArray against this scalar xray object, the order seems to matter. This results in problems down the road that wouldn't happen if I just had a scalar value instead of a scalar xray object.

```

bbox {'longitude': (<xray.DataArray 'longitude' ()> array(-102.8782), <xray.DataArray 'longitude' ()> array(-94.6244))} a = bbox['longitude'][0] <= mod['longitude'] b = mod['longitude'] <= bbox['longitude'][1] c = mod['longitude'] >= bbox['longitude'][0] a <xray.DataArray 'longitude' (longitude: 7001)> array([False, False, False, ..., True, True, True], dtype=bool) Coordinates: * longitude (longitude) bool False False False False False False False False False ... b <xray.DataArray (longitude: 7001)> array([ True, True, True, ..., False, False, False], dtype=bool) Coordinates: * longitude (longitude) float32 -129.995 -129.985 -129.975 -129.965 -129.955 ... ```

See that the "a" object has a name "longitude" while the "b" object does not. Therefore...

```

a & b Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/nas/home/broot/centos6/lib/python2.7/site-packages/xray/core/dataarray.py", line 850, in func ds = self.coords.merge(other_coords) File "/nas/home/broot/centos6/lib/python2.7/site-packages/xray/core/coordinates.py", line 122, in merge conflicts = self._merge_validate(other) File "/nas/home/broot/centos6/lib/python2.7/site-packages/xray/core/coordinates.py", line 80, in _merge_validate raise ValueError('index %r not aligned' % k) ValueError: index 'longitude' not aligned ```

But, if I use the "c" object instead which was created flipping the comparison around:

```

c * b <xray.DataArray (longitude: 7001)> array([False, False, False, ..., False, False, False], dtype=bool) Coordinates: * longitude (longitude) float32 -129.995 -129.985 -129.975 -129.965 -129.955 ...

```

everything works as expected. I have a vague idea of why this is happening, but I am not exactly sure how one should go about dealing with this. It is a similar problem elsewhere with subclassed numpy arrays. For now, I am going to have to go with the rule of keeping the xray dataarray object first, but that really isn't going to work in other places where I may not know that I am passing xray objects.

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/254/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed xarray 13221727 issue
29030870 MDU6SXNzdWUyOTAzMDg3MA== 58 Add a DataArray.dropna() method for removing missing values shoyer 1217238 closed 0   0.3.1 799012 0 2014-03-08T21:49:29Z 2014-10-23T04:57:36Z 2014-10-17T20:02:22Z MEMBER      

This should be patterned off of pandas.DataFrame.dropna.

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/58/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed xarray 13221727 issue
45948310 MDU6SXNzdWU0NTk0ODMxMA== 253 We should ship test data with the source distribution on pypi shoyer 1217238 closed 0   0.3.1 799012 0 2014-10-16T04:57:19Z 2014-10-20T07:32:03Z 2014-10-20T07:32:03Z MEMBER      

This will make it easier to test xray (e.g., with nosetests xray)

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/253/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed xarray 13221727 issue

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issues] (
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [number] INTEGER,
   [title] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [state] TEXT,
   [locked] INTEGER,
   [assignee] INTEGER REFERENCES [users]([id]),
   [milestone] INTEGER REFERENCES [milestones]([id]),
   [comments] INTEGER,
   [created_at] TEXT,
   [updated_at] TEXT,
   [closed_at] TEXT,
   [author_association] TEXT,
   [active_lock_reason] TEXT,
   [draft] INTEGER,
   [pull_request] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [state_reason] TEXT,
   [repo] INTEGER REFERENCES [repos]([id]),
   [type] TEXT
);
CREATE INDEX [idx_issues_repo]
    ON [issues] ([repo]);
CREATE INDEX [idx_issues_milestone]
    ON [issues] ([milestone]);
CREATE INDEX [idx_issues_assignee]
    ON [issues] ([assignee]);
CREATE INDEX [idx_issues_user]
    ON [issues] ([user]);
Powered by Datasette · Queries took 962.554ms · About: xarray-datasette