You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
** Suggestion **
Maybe channels starting with or uses only a number as a variable name should be prepended with like channel_1 for channel 1 when writing the netcdf files and the reader could remove this when reading. Or have a special attribute to the variable saying satpy_dataset_name som that satpy can traslate this when reading.
The text was updated successfully, but these errors were encountered:
I think having the netcdf writer rename the channels to channel_1, channel_2 would be the most intuitive. If we have a name attribute in the metadata of each channel, we could revert to the real name when reading the data.
@TAlonglong do you feel like starting a PR for that?
@djhoese not sure. In satpy it doesn't matter as far as understand. Only when writing to netcdf/cf you violate the cf recommandation.
But a comment in satpy "best practice" that the user should avoid starting a channel name with a number would not hurt.
I write netcdf with the satpy cf writer.
Some instruments uses numbers as channel names, like AVHRR channel 1,2,3a,3b,4 and 5. The writer uses these as variable names. According the the cf https://cfconventions.org/Data/cf-conventions/cf-conventions-1.7/build/ch02s03.html the variable names should start with a letter.
I try to read back the netcdf files I have created but this fails.
To Reproduce
Test file can be downloaded here https://thredds.met.no/thredds/fileServer/remotesensingsatellite/polar-swath/2021/01/29/noaa18-avhrr-20210129100918-20210129102333.nc
I see that the error is a missing
area
to the attributes. I dont understand why as the example below works.Expected behavior
I expected the
overview
to load.Environment Info:
linux conda environment, satpy 0.25.1 python 3.8.6
Additional context
Using variable names starting with an letter works better, eg VIIRS data.
same environment:
works fine. Data can be downloaded here: https://thredds.met.no/thredds/fileServer/remotesensingsatellite/polar-swath/2021/01/29/noaa20-viirs-mband-20210129094806-20210129100053.nc
** Suggestion **
Maybe channels starting with or uses only a number as a variable name should be prepended with like channel_1 for channel 1 when writing the netcdf files and the reader could remove this when reading. Or have a special attribute to the variable saying satpy_dataset_name som that satpy can traslate this when reading.
The text was updated successfully, but these errors were encountered: