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/2636#issuecomment-450458650,https://api.github.com/repos/pydata/xarray/issues/2636,450458650,MDEyOklzc3VlQ29tbWVudDQ1MDQ1ODY1MA==,30388627,2018-12-29T02:38:00Z,2018-12-29T02:39:41Z,NONE,"@dcherian It works by `netCDF4`, but not for `xarray`: ``` file = Dataset('ds1.nc') print (file.variables['time'],'\n') with xr.open_dataset('ds1.nc') as f: print (f.time.attrs) ``` Output: ``` int64 time(time) units: hours since 2015-01-01 unlimited dimensions: current shape = (3,) filling on, default _FillValue of -9223372036854775806 used OrderedDict() ``` What's the difference between `units` and `attrs`?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,394625579 https://github.com/pydata/xarray/issues/2636#issuecomment-450456616,https://api.github.com/repos/pydata/xarray/issues/2636,450456616,MDEyOklzc3VlQ29tbWVudDQ1MDQ1NjYxNg==,30388627,2018-12-29T02:17:49Z,2018-12-29T02:17:49Z,NONE,"@xylar Thanks! I just found [another question](https://stackoverflow.com/questions/46702600/how-to-prevent-xarray-from-converting-time-offsets-to-absolute-datetimes) similar to this one. I've tried some operations: ``` with xr.open_dataset('merge.nc') as f: print (f['temperature'],'\n') print ('---------------------------') print (f.mean(dim='time')) print ('---------------------------') print (f['temperature'].loc[:,:,'2015-01-05T04:00:00',]) print ('---------------------------') ``` It works fine: ``` array([[[-0.022611, -1.428088, -0.655508, 0.977389, -0.428088, 0.344492], [ 0.430102, 0.996973, -0.882054, 1.430102, 1.996973, 0.117946]], [[ 0.157233, -0.230397, -0.505775, 1.157233, 0.769603, 0.494225], [-0.075826, -1.933904, -0.823982, 0.924174, -0.933904, 0.176018]]]) Coordinates: lon (x, y) float64 ... lat (x, y) float64 ... * time (time) datetime64[ns] 2015-01-05T04:00:00 2015-01-05T05:00:00 ... Dimensions without coordinates: x, y --------------------------- Dimensions: (x: 2, y: 2) Coordinates: lon (x, y) float64 ... lat (x, y) float64 ... Dimensions without coordinates: x, y Data variables: temperature (x, y) float64 -0.2021 0.6817 0.307 -0.4446 --------------------------- array([[-0.022611, 0.430102], [ 0.157233, -0.075826]]) Coordinates: lon (x, y) float64 ... lat (x, y) float64 ... time datetime64[ns] 2015-01-05T04:00:00 Dimensions without coordinates: x, y --------------------------- ```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,394625579