Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Read GRIB 2 files with Python. This package is a Python wrapper around the Rust library gribberish.
There is support for xarray
and kerchunk
integration, as well as just reading the data directly into numpy
arrays.
pip
pip install gribberish
or install with git:
pip install -e "gribberish@git+https://github.com/mpiannucci/gribberish.git#egg=gribberish\&subdirectory=python"
With optional xarray
support:
pip install "gribberish[xarray]"
With optional kerchunk
support:
pip install "gribberish[kerchunk]"
With optional zarr
support:
pip install "gribberish[zarr]"
With pip:
pip install -e .
or with maturin
pip install maturin
maturin develop
This module can be used directly, or via xarray
.
For direct usage, see dump_dataset.py or compare with eccodes
usage and performance in bench.py.
xarray
To use with xarray
, simply specify the gribberish
backend when loading a grib2
file:
import xarray as xr
ds = xr.open_dataset('gfswave.20210826.t12z.atlocn.0p16.f000.grib2', engine='gribberish')
Some examples are provided:
xarray_usage.ipynb
shows how to load a single GFS Wave model grib2 filehrrr.ipynb
shows how to load a single HRRR model grib2 file. There are multiple time and vertical coordinates in this file so it shows how the full dataset can be loaded or filtered down to only what is desired. It also demonstrates how to select data at a given point in space using the non regular gridded coordinate system.nwps.ipynb
shows how to load an entire NWPS model output that is distributed in a single grib2 file.gfs.ipynb
shows how to load a single GFS grib2 output file.read_radar.ipynb
shows how to load a single radar file from a single uncompressed MRMS
grib2 file.kerchunk
This package also supports building virtual datasets with kerchunk
. Two examples are provided:
kerchunk_gefs_wave.ipynb
shows how to build a single virtual dataset from an entire GEFS Wave Ensemble model run (30 ensemble members, 384 hour time horizon)kerchunk_hrrr_subhourly.ipynb
shows how to build a single virtual dataset from an entire HRRR subhourly surface model run. This results in a virtual dataset with data at 15 minute time intervals over the following 18 hours.zarr
This package also supports use with zarr
for reading unmodified GRIB2 messages (arrays) as chunks using the gribberish.zarr.GribberishCodec
codec. This usually will not be used directly, but with VirtualiZarr
or kerchunk
Examples to come soon.
FAQs
Unknown package
We found that gribberish demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.