Closed RPrudden closed 5 years ago
You just need to tell GeoViews what coordinate system your data is in, using the crs
parameter accepted by GeoViews objects. Without that declaration, it assumes your data is in PlateCaree, which is clearly not the case here. Maybe pass crs=crs.GOOGLE_MERCATOR
(given the size of those coordinates)?
Thanks, this helped! I switched to the geoviews Dataset and used
gv_ds = gv.Dataset(xr_ds, crs=cube.coord_system().as_cartopy_crs())
Strangely, the limits of the cartopy CRS seem to be different than in Iris so that part of the data is cut off. The original is in a TransverseMercator coordinate system, but in cartopy it is mapped to OSGB.
But I think this is either an Iris or a dataset issue, rather than geoviews.
You just need to tell GeoViews what coordinate system your data is in, using the
crs
parameter accepted by GeoViews objects. Without that declaration, it assumes your data is in PlateCaree, which is clearly not the case here. Maybe passcrs=crs.GOOGLE_MERCATOR
(given the size of those coordinates)?
I think GeoViews needs its own FAQ about this heh
I have some working code in holoviews which displays a dataset (constructed from an xarray dataset).
However, when I try to do the equivalent in geoviews the plot does not contain any data. Also, the axes are completely different. I think geoviews is only plotting a small section of the data, but I have no idea why.
Extra information
The geoviews version also runs considerably slower than the holoviews version - on the order of minutes, rather than seconds. It gave some warnings while it was running:
I have also tried loading the data from iris, and regridding into latitude/longitude coordinates, but the results were much the same.