{"action":"created","issue":{"url":"https://api.github.com/repos/Alexander-Barth/NCDatasets.jl/issues/12","repository_url":"https://api.github.com/repos/Alexander-Barth/NCDatasets.jl","labels_url":"https://api.github.com/repos/Alexander-Barth/NCDatasets.jl/issues/12/labels{/name}","comments_url":"https://api.github.com/repos/Alexander-Barth/NCDatasets.jl/issues/12/comments","events_url":"https://api.github.com/repos/Alexander-Barth/NCDatasets.jl/issues/12/events","html_url":"https://github.com/Alexander-Barth/NCDatasets.jl/issues/12","id":326544857,"node_id":"MDU6SXNzdWUzMjY1NDQ4NTc=","number":12,"title":"Cannot convert time to DateTime","user":{"login":"Balinus","id":3630311,"node_id":"MDQ6VXNlcjM2MzAzMTE=","avatar_url":"https://avatars0.githubusercontent.com/u/3630311?v=4","gravatar_id":"","url":"https://api.github.com/users/Balinus","html_url":"https://github.com/Balinus","followers_url":"https://api.github.com/users/Balinus/followers","following_url":"https://api.github.com/users/Balinus/following{/other_user}","gists_url":"https://api.github.com/users/Balinus/gists{/gist_id}","starred_url":"https://api.github.com/users/Balinus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Balinus/subscriptions","organizations_url":"https://api.github.com/users/Balinus/orgs","repos_url":"https://api.github.com/users/Balinus/repos","events_url":"https://api.github.com/users/Balinus/events{/privacy}","received_events_url":"https://api.github.com/users/Balinus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":17,"created_at":"2018-05-25T14:23:46Z","updated_at":"2018-06-22T12:55:55Z","closed_at":null,"author_association":"NONE","body":"Hello!\r\n\r\nI was playing with the time vector when I realized that your package converts to a DateTime type. Hence, I'm thinking that I could simply leverage your package for this task. \r\n\r\nHowever, using multiples CORDEX and CMIP5 nc files, I can't convert the time variable to DateTime and get errors. I've added one of the file that are causing problem. I can provide more files. Thanks for any hints! :+1: \r\n\r\nhttps://www.dropbox.com/sh/1gjfdjpb0rtwq2w/AAAn19nXqu5wgeXGoxY97MS2a?dl=0\r\n\r\n```julia\r\nds=Dataset(cmip5file2)\r\nDataset: /path/to/file/tasmax_day_IPSL-CM5A-MR_historical_r2i1p1_20000101-20051231.nc\r\nGroup: /\r\n\r\nDimensions\r\n   time = 2190\r\n   lat = 143\r\n   lon = 144\r\n   bnds = 2\r\n\r\nVariables\r\n  time   (2190)\r\n    Datatype:    Float64\r\n    Dimensions:  time\r\n    Attributes:\r\n     bounds               = time_bnds\r\n     units                = days since 1850-01-01 00:00:00\r\n     calendar             = noleap\r\n     axis                 = T\r\n     long_name            = time\r\n     standard_name        = time\r\n\r\n  time_bnds   (2 × 2190)\r\n    Datatype:    Float64\r\n    Dimensions:  bnds × time\r\n\r\n  lat   (143)\r\n    Datatype:    Float64\r\n    Dimensions:  lat\r\n    Attributes:\r\n     bounds               = lat_bnds\r\n     units                = degrees_north\r\n     axis                 = Y\r\n     long_name            = latitude\r\n     standard_name        = latitude\r\n\r\n  lat_bnds   (2 × 143)\r\n    Datatype:    Float64\r\n    Dimensions:  bnds × lat\r\n\r\n  lon   (144)\r\n    Datatype:    Float64\r\n    Dimensions:  lon\r\n    Attributes:\r\n     bounds               = lon_bnds\r\n     units                = degrees_east\r\n     axis                 = X\r\n     long_name            = longitude\r\n     standard_name        = longitude\r\n\r\n  lon_bnds   (2 × 144)\r\n    Datatype:    Float64\r\n    Dimensions:  bnds × lon\r\n\r\n  height  \r\n    Attributes:\r\n     units                = m\r\n     axis                 = Z\r\n     positive             = up\r\n     long_name            = height\r\n     standard_name        = height\r\n\r\n  tasmax   (144 × 143 × 2190)\r\n    Datatype:    Float32\r\n    Dimensions:  lon × lat × time\r\n    Attributes:\r\n     standard_name        = air_temperature\r\n     long_name            = Daily Maximum Near-Surface Air Temperature\r\n     units                = K\r\n     original_name        = t2m_max\r\n     cell_methods         = time: maximum (interval: 30 minutes)\r\n     cell_measures        = area: areacella\r\n     history              = 2012-04-25T17:00:57Z altered by CMOR: Treated scalar dimension: 'height'. 2012-04-25T17:00:57Z altered by CMOR: replaced missing value flag (9.96921e+36) with standard missing value (1e+20). 2012-04-25T17:00:58Z altered by CMOR: Inverted axis: lat.\r\n     coordinates          = height\r\n     missing_value        = 1.0e20\r\n     _FillValue           = 1.0e20\r\n     associated_files     = baseURL: http://cmip-pcmdi.llnl.gov/CMIP5/dataLocation gridspecFile: gridspec_atmos_fx_IPSL-CM5A-MR_historical_r0i0p0.nc areacella: areacella_fx_IPSL-CM5A-MR_historical_r0i0p0.nc\r\n\r\nGlobal attributes\r\n  institution          = IPSL (Institut Pierre Simon Laplace, Paris, France)\r\n  institute_id         = IPSL\r\n  experiment_id        = historical\r\n  source               = IPSL-CM5A-MR (2010) : atmos : LMDZ4 (LMDZ4_v5, 144x143x39); ocean : ORCA2 (NEMOV2_3, 2x2L31); seaIce : LIM2 (NEMOV2_3); ocnBgchem : PISCES (NEMOV2_3); land : ORCHIDEE (orchidee_1_9_4_AR5)\r\n  model_id             = IPSL-CM5A-MR\r\n  forcing              = Nat,Ant,GHG,SA,Oz,LU,SS,Ds,BC,MD,OC,AA\r\n  parent_experiment_id = piControl\r\n  parent_experiment_rip = r1i1p1\r\n  branch_time          = 1860.0\r\n  contact              = ipsl-cmip5 _at_ ipsl.jussieu.fr Data manager : Sebastien Denvil\r\n  comment              = This 20th century simulation include natural and anthropogenic forcings.\r\n  references           = Model documentation and further reference available here : http://icmc.ipsl.fr\r\n  initialization_method = 1\r\n  physics_version      = 1\r\n  tracking_id          = 865ced25-4e24-43d1-bf07-fd163ba5c7b7\r\n  product              = output\r\n  experiment           = historical\r\n  frequency            = day\r\n  creation_date        = 2012-04-25T17:00:58Z\r\n  history              = 2012-04-25T17:00:58Z CMOR rewrote data to comply with CF standards and CMIP5 requirements.\r\n  Conventions          = CF-1.4\r\n  project_id           = CMIP5\r\n  table_id             = Table day (10 February 2011) 80e409bd73611e9d25d049ad2059c310\r\n  title                = IPSL-CM5A-MR model output prepared for CMIP5 historical\r\n  parent_experiment    = pre-industrial control\r\n  modeling_realm       = atmos\r\n  realization          = 2\r\n  cmor_version         = 2.7.1\r\n\r\n\r\njulia> ds[\"time\"]\r\ntime (2190)\r\n  Datatype:    Float64\r\n  Dimensions:  time\r\n  Attributes:\r\n   bounds               = time_bnds\r\n   units                = days since 1850-01-01 00:00:00\r\n   calendar             = noleap\r\n   axis                 = T\r\n   long_name            = time\r\n   standard_name        = time\r\n\r\njulia> ds[\"time\"][:]\r\nERROR: MethodError: no method matching start(::Void)\r\nClosest candidates are:\r\n  start(::SimpleVector) at essentials.jl:258\r\n  start(::Base.MethodList) at reflection.jl:560\r\n  start(::ExponentialBackOff) at error.jl:107\r\n  ...\r\nStacktrace:\r\n [1] timedecode(::Array{Float64,1}, ::String, ::String) at /home/proy/.julia/v0.6/NCDatasets/src/NCDatasets.jl:217\r\n [2] getindex(::NCDatasets.CFVariable{Float64,Float64,1}, ::Colon) at /home/proy/.julia/v0.6/NCDatasets/src/NCDatasets.jl:1091\r\n```\r\nedit - Should have added that all tests pass and I'm on latest master of NCDatasets.\r\n\r\n```julia\r\njulia> Pkg.test(\"NCDatasets\")\r\nINFO: Testing NCDatasets\r\nNetCDF library: /home/proy/.julia/v0.6/Conda/deps/usr/lib/libnetcdf.so\r\nNetCDF version: 4.5.0 of Nov  8 2017 13:35:26 $\r\nTest Summary: | Pass  Total\r\nNCDatasets    |  547    547\r\nINFO: NCDatasets tests passed\r\n\r\njulia> Pkg.status(\"NCDatasets\")\r\n - NCDatasets                    0.0.10+            master\r\n```"},"comment":{"url":"https://api.github.com/repos/Alexander-Barth/NCDatasets.jl/issues/comments/399433164","html_url":"https://github.com/Alexander-Barth/NCDatasets.jl/issues/12#issuecomment-399433164","issue_url":"https://api.github.com/repos/Alexander-Barth/NCDatasets.jl/issues/12","id":399433164,"node_id":"MDEyOklzc3VlQ29tbWVudDM5OTQzMzE2NA==","user":{"login":"Alexander-Barth","id":9881475,"node_id":"MDQ6VXNlcjk4ODE0NzU=","avatar_url":"https://avatars3.githubusercontent.com/u/9881475?v=4","gravatar_id":"","url":"https://api.github.com/users/Alexander-Barth","html_url":"https://github.com/Alexander-Barth","followers_url":"https://api.github.com/users/Alexander-Barth/followers","following_url":"https://api.github.com/users/Alexander-Barth/following{/other_user}","gists_url":"https://api.github.com/users/Alexander-Barth/gists{/gist_id}","starred_url":"https://api.github.com/users/Alexander-Barth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Alexander-Barth/subscriptions","organizations_url":"https://api.github.com/users/Alexander-Barth/orgs","repos_url":"https://api.github.com/users/Alexander-Barth/repos","events_url":"https://api.github.com/users/Alexander-Barth/events{/privacy}","received_events_url":"https://api.github.com/users/Alexander-Barth/received_events","type":"User","site_admin":false},"created_at":"2018-06-22T12:55:55Z","updated_at":"2018-06-22T12:55:55Z","author_association":"OWNER","body":"Just to let you know that I now released version v0.1.0 with the CFDateTime branch merged.\r\nI propose to close this issue if this is OK for your."}}
{"actor":{"display_login":"Alexander-Barth"}}