If you are a modeler at COAPS and are looking for a quick reference, skip to the Quick References section.
There are two ways do download the project.
I would suggest the former option. There is no guarantee that the version available on the server is the latest version. If you want the lastest version with all the conversion modules, clone a copy from github.
If you do not have github, and do not want to install it or make an account, you can still download a version below.
Version 1.0 - Download
Currently the project depends on only the NetCDF4 library. A version is packaged inside the project. Onc can either compile the in source library or obtain an external one. If you already have NetCDF4, or you have compiled it separately, ensure that the shared library files are in the lib64 directory.
Ideally this tool will simplify your life. Typing in long complex paths is not efficient or simple. We want to add the path to the c2v utility to our environment variable PATH. On most linux and unix flavors the PATH variable can easily be set from within your shell’s local config file.
If you’re using BASH:
MacOSX:
Add the path to your .bash_profile file:
PATH=$PATH: <Path/To/Converter/Here>
export PATH
Linux:
Add the path to your .bashrc file:
PATH=$PATH: <Path/To/Coverter/Here>
export PATH
Also source the .bashrc file in your .bash_profile, or .profile:
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
The .profile, or .bash_profile is called everytime a user logs in to their account, and the .bashrc is called everytime a new terminal is opened. MacOSX only has the .bash_profile which is always called upon the execution of the Terminal.app
So now that you’ve downloaded the converter, installed the dependencies, and added the path to the converter to the PATH variable you can convert your data! Make sure your data is on the same machine as the converter, and follow the example below.
You can call the conversion utility with the c2v command:
$ c2v data parameter_file
data - The path to your model output data file
parameter_file - The path to your parameter file