Siphon - A collection of Python utilities for retrieving data from Unidata data technologies.
-9999
), which get translated to nans. Siphon's not doing anything wrong in this case, that's an issue with the underlying data, nothing we can do about. If you encounter any additional data oddities in the future, my recommendation would be to first try to download the data manually and see if what Siphon is giving you matches up with what's in the raw data file.
CDMRemote
(which siphon supports using with xarray)
Is anyone having problems pulling netCDF subsets from NCEI using TDSCatalogs? I've been trying to update some old codes that used siphon and have been looking at the Unidata python training to help but it seems like I keep getting hung up on either one of theses lines : data = ncss.get_data(query)
or
ncss = cat.datasets[f'gfsanl_4_{dt:%Y%m%d}_{dt:%H}00_000.grb2'].subset()
which gives me error messages of:
HTTPError: Error accessing https://www.ncei.noaa.gov/thredds/ncss/model-gfs-g4-anl-files-old/201801/20180104/gfsanl_4_20180104_1200_000.grb2?var=Apparent_temperature_height_above_ground&var=Pressure_reduced_to_MSL_msl&var=v-component_of_wind_height_above_ground&var=u-component_of_wind_height_above_ground&time=2018-01-04T12%3A00%3A00&accept=netcdf
Server Error (500: java.lang.IllegalStateException: No records found in dataset gfsanl_4_20180104_1200_000.grb2)
and
HTTPError: Error accessing https://www.ncei.noaa.gov/thredds/ncss/model-gfs-g4-anl-files-old/201801/20180104/gfsanl_4_20180104_1200_000.grb2/dataset.xml
Server Error (500: java.lang.IllegalStateException: No records found in dataset gfsanl_4_20180104_1200_000.grb2)
I'm running this in jupyter notebooks, so once I get the first error if I don't restart I get the second error.
Also, if you click the link in the first error message it will download the netCDF subset that you were requesting.
I can't get the python logger to print to either a file or screen when using TDSCatalog. Is there an alternate way to create messages for debugging in siphon? For Example:
import logging
from siphon.catalog import TDSCatalog
FORMAT = '%(asctime)s %(clientip)-15s %(user)-8s %(message)s'
logging.basicConfig(format=FORMAT)
logger = logging.getLogger(__name__)
logger.warning("Test This")
Does not work when the siphon import is being used.