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/1474#issuecomment-314167150,https://api.github.com/repos/pydata/xarray/issues/1474,314167150,MDEyOklzc3VlQ29tbWVudDMxNDE2NzE1MA==,8699967,2017-07-10T16:53:25Z,2017-07-10T16:53:25Z,CONTRIBUTOR,"@fmaussion, thanks again for your time!","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,241714748
https://github.com/pydata/xarray/issues/1474#issuecomment-314162736,https://api.github.com/repos/pydata/xarray/issues/1474,314162736,MDEyOklzc3VlQ29tbWVudDMxNDE2MjczNg==,8699967,2017-07-10T16:38:39Z,2017-07-10T16:38:39Z,CONTRIBUTOR,Which is what I think you do in salem.,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,241714748
https://github.com/pydata/xarray/issues/1474#issuecomment-314162500,https://api.github.com/repos/pydata/xarray/issues/1474,314162500,MDEyOklzc3VlQ29tbWVudDMxNDE2MjUwMA==,8699967,2017-07-10T16:37:56Z,2017-07-10T16:37:56Z,CONTRIBUTOR,"Oh, and to make the time slice work for WRF, I had to make the time variables consistent:
```python
xds.rename(
{
time_dim: 'time',
time_var: 'time',
},
inplace=True
)
```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,241714748
https://github.com/pydata/xarray/issues/1474#issuecomment-314162219,https://api.github.com/repos/pydata/xarray/issues/1474,314162219,MDEyOklzc3VlQ29tbWVudDMxNDE2MjIxOQ==,8699967,2017-07-10T16:36:53Z,2017-07-10T16:36:53Z,CONTRIBUTOR,"OK. That is good to know.
In this case, I don't know the name if the dimension beforehand, so I thought it might be preferable to do:
```python
data = data.loc[{self.lsm_time_dim: [pd.to_datetime(time_step)]}]
```
instead of:
```python
data = data.sel(**{self.lsm_time_dim: [pd.to_datetime(time_step)]})
```
What are your thoughts?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,241714748
https://github.com/pydata/xarray/issues/1474#issuecomment-314159012,https://api.github.com/repos/pydata/xarray/issues/1474,314159012,MDEyOklzc3VlQ29tbWVudDMxNDE1OTAxMg==,8699967,2017-07-10T16:25:20Z,2017-07-10T16:25:20Z,CONTRIBUTOR,"OK. I feel silly now. I thought I should have been using loc[]
Thanks @fmaussion for that.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,241714748
https://github.com/pydata/xarray/issues/1474#issuecomment-314151625,https://api.github.com/repos/pydata/xarray/issues/1474,314151625,MDEyOklzc3VlQ29tbWVudDMxNDE1MTYyNQ==,8699967,2017-07-10T16:00:11Z,2017-07-10T16:02:35Z,CONTRIBUTOR,"I am having the same issue with a completely different grid:
```
dask.array
Coordinates:
* longitude (longitude) float32 248.0 248.25 248.5 248.75
* latitude (latitude) float32 40.75 40.5 40.25 40.0 39.75
* time (time) datetime64[ns] 2016-01-02 2016-01-02T01:00:00 ...
Attributes:
units: Pa
long_name: Surface pressure
standard_name: surface_air_pressure
```
Error:
```
self = DatetimeIndex(['2016-01-02 00:00:00', '2016-01-02 01:00:00',
'2016-01-02 02:00:00', '2016-01-02 03:00:0...:00:00',
'2016-01-04 22:00:00', '2016-01-04 23:00:00'],
dtype='datetime64[ns]', freq=None)
key = array(Timestamp('2016-01-02 00:00:00'), dtype=object)
def __getitem__(self, key):
""""""
This getitem defers to the underlying array, which by-definition can
only handle list-likes, slices, and integer scalars
""""""
is_int = is_integer(key)
if is_scalar(key) and not is_int:
raise ValueError
getitem = self._data.__getitem__
if is_int:
val = getitem(key)
return self._box_func(val)
else:
if com.is_bool_indexer(key):
key = np.asarray(key)
if key.all():
key = slice(0, None, None)
else:
key = lib.maybe_booleans_to_slice(key.view(np.uint8))
attribs = self._get_attributes_dict()
is_period = isinstance(self, ABCPeriodIndex)
if is_period:
freq = self.freq
else:
freq = None
if isinstance(key, slice):
if self.freq is not None and key.step is not None:
freq = key.step * self.freq
else:
freq = self.freq
attribs['freq'] = freq
> result = getitem(key)
E IndexError: arrays used as indices must be of integer (or boolean) type
../../../tethys/miniconda/envs/gssha/lib/python3.6/site-packages/pandas/core/indexes/datetimelike.py:296: IndexError
```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,241714748