Open ayushnag opened 3 months ago
I wouldn't say this issue is fully closed yet. See https://github.com/zarr-developers/VirtualiZarr/issues/281#issuecomment-2445526098 for an explanation. #191 closes an important part of it but #224 is also required.
The
xr.Dataset
constructed byopen_virtual_dataset
doesn't seem to correctly identify coordinates when the coordinate has more than one dimension. The bug seems to be inseparate_coords
on this line. The correct functionality could be to use thecoordinates
attribute within each variables.zattrs
and maintain a set of all coordinate namesHere is a reproducible example:
Note that the underlying kerchunk json does have this coordinate information since when you
virtualize
the dataset and materialize data, the coordinates are correct: