Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Threp Overview

Interpolation is a bridge links the discrete space to the continuous space, in other words, real solutions to theories, so it's great!

Interpolation in Coupled Earth System Model is something called 'Remap' or 'Regridding'. It's a special application of interpolation.

Also, it is a little different from traditional interpolation in Computer Graphics. We must seperate the interpolation here into two step:i). Generate weights, ii). Calculate values, according to the specific application scene. What's more, interpolation here happens on surface of the earth, so we must take 'Polar Problem' and 'Periodic Boundary Problem' into account. More importantly, we must 'keep conservative' during flux remapping process..

Embrace Threp!


I. Install NumPy Python Library. NumPy is the fundamental package for scientific computing with Python. See more infomation at

II. Install MPI4Py Python Library. MPI4Py is a Python version of MPI. See more infomation at

III. Install Scientific Python Library to support NetCDF(a kind of binary file) file format in Threp, see more infomation at

IV. Define environment variable 'THREP_DIR' in $THREP_DIR/config/, and then type

$ python

V. Now you are successfully installed Threp, have fun.


Example for generating a remapping weight file:

$ cd $THREP_DIR/../bin/wgen/
$ python	# serial
$ mpirun -n $num python	# parallel

Here, you can modify file(line 42) to reset your input. Python2.7 or earlier tested.

Example for developing a new remapping algorithm:

Create a at $THREP_DIR/interp/algs.

Write a class which inherit the Interp superclass, that means you can use lots of functions in class Interp.

Rewrite interp method in your newalg class, just a long loop(100~200 LOC)


Threp - a lightweight remap framework for the Earth System Model.






No releases published


No packages published