G2S: The GeoStatistical Server

An extensible geostatistical framework connecting programming interfaces to simulation algorithms through a shared server.

Installation of interfaces

Python

Automatic installation

Simply use pip install G2S

Manual compilation

  1. If needed Python and build dependencies: sudo apt install python3-distutils python3-dev python3-numpy -y
  2. (A C++ compiler with c++17 is required)
  3. Go to build/python-build
  4. Install the Python build/runtime dependencies: python3 -m pip install -U build numpy pyzmq requests tifffile
  5. Run python3 setup.py install --user

Check proper interface installation

Simply run from g2s import g2s; g2s('--version')

MATLAB

Installation on Ubuntu

  1. (A C++ compiler with c++17 is required)
  2. Install the static ZeroMQ and libsodium libraries: sudo apt install libzmq3-dev libsodium-dev
  3. Open MATLAB (R2018a or later)
  4. Go to build/matlab-build
  5. Run CompileG2S
  6. Add compiled file in the MATLAB path

Installation on macOS

Supported and tested on Apple Silicon (arm64) with Homebrew. Intel Macs are not supported explicitly.

  1. Install the Xcode command line tools and the static ZeroMQ and libsodium libraries: brew install zeromq libsodium
  2. Open MATLAB (R2018a or later)
  3. Go to build/matlab-build
  4. Run CompileG2S
  5. Add compiled file in the MATLAB path

Installation on Windows 10

Download precompiled interfaces
  1. Download here.
  2. Unzip and add the folder to MATLAB path.
Manual compilation
  1. (A C++ compiler with c++17 is required)
  2. Open MATLAB (R2018a or later)
  3. Install a compiler with c++17, available here (2017 or later)
  4. Go to build/matlab-build
  5. Run CompileG2S
  6. Add compiled file in the MATLAB path
Notes
  • jsoncpp and cppzmq are bundled in include_interfaces/third_party and compiled into the MEX file, so no jsoncpp library needs to be installed.
  • CompileG2S builds the C++ MEX API interface. To build the older C API interface instead, set the environment variable G2S_MATLAB_LEGACY_API=1 before running CompileG2S (for example setenv('G2S_MATLAB_LEGACY_API','1')).
Check proper interface installation

Simply run g2s('--version')

R

TODO !