{"action":"closed","issue":{"url":"https://api.github.com/repos/creare-com/podpac/issues/30","repository_url":"https://api.github.com/repos/creare-com/podpac","labels_url":"https://api.github.com/repos/creare-com/podpac/issues/30/labels{/name}","comments_url":"https://api.github.com/repos/creare-com/podpac/issues/30/comments","events_url":"https://api.github.com/repos/creare-com/podpac/issues/30/events","html_url":"https://github.com/creare-com/podpac/issues/30","id":323295125,"node_id":"MDU6SXNzdWUzMjMyOTUxMjU=","number":30,"title":"Rasterio exception using integer array as DataSource source ","user":{"login":"jmilloy","id":1051972,"node_id":"MDQ6VXNlcjEwNTE5NzI=","avatar_url":"https://avatars1.githubusercontent.com/u/1051972?v=4","gravatar_id":"","url":"https://api.github.com/users/jmilloy","html_url":"https://github.com/jmilloy","followers_url":"https://api.github.com/users/jmilloy/followers","following_url":"https://api.github.com/users/jmilloy/following{/other_user}","gists_url":"https://api.github.com/users/jmilloy/gists{/gist_id}","starred_url":"https://api.github.com/users/jmilloy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmilloy/subscriptions","organizations_url":"https://api.github.com/users/jmilloy/orgs","repos_url":"https://api.github.com/users/jmilloy/repos","events_url":"https://api.github.com/users/jmilloy/events{/privacy}","received_events_url":"https://api.github.com/users/jmilloy/received_events","type":"User","site_admin":false},"labels":[{"id":865784010,"node_id":"MDU6TGFiZWw4NjU3ODQwMTA=","url":"https://api.github.com/repos/creare-com/podpac/labels/bug","name":"bug","color":"d73a4a","default":true},{"id":933964164,"node_id":"MDU6TGFiZWw5MzM5NjQxNjQ=","url":"https://api.github.com/repos/creare-com/podpac/labels/confirmed","name":"confirmed","color":"d73a4a","default":false}],"state":"closed","locked":false,"assignee":{"login":"mlshapiro","id":8190979,"node_id":"MDQ6VXNlcjgxOTA5Nzk=","avatar_url":"https://avatars1.githubusercontent.com/u/8190979?v=4","gravatar_id":"","url":"https://api.github.com/users/mlshapiro","html_url":"https://github.com/mlshapiro","followers_url":"https://api.github.com/users/mlshapiro/followers","following_url":"https://api.github.com/users/mlshapiro/following{/other_user}","gists_url":"https://api.github.com/users/mlshapiro/gists{/gist_id}","starred_url":"https://api.github.com/users/mlshapiro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlshapiro/subscriptions","organizations_url":"https://api.github.com/users/mlshapiro/orgs","repos_url":"https://api.github.com/users/mlshapiro/repos","events_url":"https://api.github.com/users/mlshapiro/events{/privacy}","received_events_url":"https://api.github.com/users/mlshapiro/received_events","type":"User","site_admin":false},"assignees":[{"login":"mlshapiro","id":8190979,"node_id":"MDQ6VXNlcjgxOTA5Nzk=","avatar_url":"https://avatars1.githubusercontent.com/u/8190979?v=4","gravatar_id":"","url":"https://api.github.com/users/mlshapiro","html_url":"https://github.com/mlshapiro","followers_url":"https://api.github.com/users/mlshapiro/followers","following_url":"https://api.github.com/users/mlshapiro/following{/other_user}","gists_url":"https://api.github.com/users/mlshapiro/gists{/gist_id}","starred_url":"https://api.github.com/users/mlshapiro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlshapiro/subscriptions","organizations_url":"https://api.github.com/users/mlshapiro/orgs","repos_url":"https://api.github.com/users/mlshapiro/repos","events_url":"https://api.github.com/users/mlshapiro/events{/privacy}","received_events_url":"https://api.github.com/users/mlshapiro/received_events","type":"User","site_admin":false}],"milestone":null,"comments":4,"created_at":"2018-05-15T16:35:13Z","updated_at":"2018-11-09T19:58:12Z","closed_at":"2018-11-09T19:58:12Z","author_association":"COLLABORATOR","body":"**Description**\r\nDefining a DataSource node with a integer array as the source results in a rasterio exception when evaluating the node. The no-data value during interpolation using rasterio is `np.nan` which is invalid for integer inputs.\r\n\r\n**Steps to Reproduce**\r\n```\r\nclass A(NumpyArray):\r\n    source = np.arange(10000).reshape(100, 100)\r\n\r\n    def get_native_coordinates(self):\r\n        return Coordinate(lat=(-25, 25, 100), lon=(-25, 25, 100), order=['lat', 'lon'])\r\n\r\na = A()\r\ncoords = Coordinate(lat=(0, 10, 80), lon=(0, 10, 80), order=['lat', 'lon'])\r\nout = a.execute(coords)\r\n```\r\n\r\n**Observed Behavior**\r\n```\r\nTraceback (most recent call last):\r\n  File \"jxm.py\", line 37, in <module>\r\n    out = a.execute(coords)\r\n  File \"/home/jmilloy/Pipeline/podpac/podpac/core/data/data.py\", line 108, in execute\r\n    self.interpolate_data(data_subset, coords_subset, coordinates)\r\n  File \"/home/jmilloy/Pipeline/podpac/podpac/core/data/data.py\", line 270, in interpolate_data\r\n    return self.rasterio_interpolation(data_src, coords_src, data_dst, coords_dst)\r\n  File \"/home/jmilloy/Pipeline/podpac/podpac/core/data/data.py\", line 393, in rasterio_interpolation\r\n    resampling=getattr(Resampling, self.interpolation)\r\n  File \"/usr/local/lib/python2.7/dist-packages/rasterio-1.0a9-py2.7-linux-x86_64.egg/rasterio/env.py\", line 275, in wrapper\r\n    return f(*args, **kwds)\r\n  File \"/usr/local/lib/python2.7/dist-packages/rasterio-1.0a9-py2.7-linux-x86_64.egg/rasterio/warp.py\", line 286, in reproject\r\n    init_dest_nodata, **kwargs)\r\n  File \"rasterio/_warp.pyx\", line 277, in rasterio._warp._reproject (rasterio/_warp.cpp:4742)\r\nValueError: src_nodata must be in valid range for source dtype\r\n```\r\n\r\n**Expected Behavior**\r\nA `traitlets.TraitsError` or `ValueError` exception is raised during node initialization."}}
{"actor":{"display_login":"mlshapiro"}}