Skip to content

Commit

Permalink
More tidy up
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisspyB committed May 17, 2024
1 parent 52f6630 commit 0ac2eed
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 39 deletions.
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# GribJump

GribJump is a C++ library for extracting subsets of data from GRIB files archived in the [FDB](https://github.com/ecmwf/fdb).
GribJump is a C++ library for extracting subsets of data from GRIB files, particularly data archived in the [FDB](https://github.com/ecmwf/fdb).

:warning: **This is a work in progress.** Consult the developers before using.
:warning: **This is a work in progress.** Expect bugs, and for interfaces and functionality to change. Consult the developers before using.

## Installation

Expand All @@ -14,6 +14,7 @@ Currently, GribJump has the following runtime dependencies:
- [eckit](https://github.com/ecmwf/eckit)
- [metkit](https://github.com/ecmwf/metkit)
- [fdb5](https://github.com/ecmwf/fdb)
- [libaec](https://github.com/MathisRosenhauer/libaec)

as well as [ecbuild](https://github.com/ecmwf/ecbuild) for building.

Expand All @@ -32,13 +33,19 @@ Building and installing:
cd $builddir

# 2. Run ecbuild
ecbuild --prefix=$installdir -- -DCMAKE_INSTALL_PREFIX=</path/to/installations> $srcdir
ecbuild --prefix=${installdir} -- \
-DENABLE_MEMFS=ON \
-DENABLE_ECCODES_THREADS=ON \
-DENABLE_AEC=ON \
-DCMAKE_INSTALL_PREFIX=$</path/to/installations> ${srcdir}

# 3. Compile / Install
make -j10
make install
```

A clientside build (which cannot extract data but talks to a server which can) is built using the flag `-DENABLE_GRIBJUMP_LOCAL_EXTRACT=OFF`. This requires only eckit and metkit to be installed.

### Python Library

The python interface, `pygribjump`, can be installed with pip:
Expand All @@ -49,4 +56,4 @@ python3 -m pip install --upgrade git+ssh://[email protected]/ecmwf/gribjump.git@mas

`pygribjump` uses [findlibs](https://github.com/ecmwf/findlibs) to find an installed `libgribjump` library. You can use `export GRIBJUMP_HOME=/path/to/gribjump/install` to help with finding the library.

See `pygribjump/test.py` for a simple use case.
See the `pygribjump/example*.py` files for simple use cases.
2 changes: 1 addition & 1 deletion pygribjump/example_extract.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import os
os.environ['GRIBJUMP_HOME'] = '/Users/maby/repo/mars-client-bundle/build/'
os.environ['GRIBJUMP_HOME'] = '/path/to/gribjump/build/'
os.environ['GRIBJUMP_CONFIG_FILE'] = "/path/to/gribjump/config.yaml"

import pygribjump as pygj
Expand Down
34 changes: 0 additions & 34 deletions todo.md

This file was deleted.

0 comments on commit 0ac2eed

Please sign in to comment.