Installation

Stable release

To install TotalDepth, run this command in your terminal:

$ pip install TotalDepth

This is the preferred method to install TotalDepth, as it will always install the most recent stable release.

If you don’t have pip installed, this Python installation guide can guide you through the process.

From sources

If you are using a virtual environment in your <PYTHONVENVS>, say ~/pyvenvs:

$ python3 -m venv <PYTHONVENVS>/TotalDepth
$ . <PYTHONVENVS>/TotalDepth/bin/activate
(TotalDepth) $

Or if you have a Conda environment:

$ conda create --name TotalDepth python=3.6 pip
$ source activate TotalDepth

Install the dependencies, numpy and Cython:

If you are using a virtual environment:

(TotalDepth) $ pip install numpy
(TotalDepth) $ pip install Cython

Or if you have a Conda environment:

(TotalDepth) $ conda install numpy
(TotalDepth) $ conda install Cython

The sources for TotalDepth can be downloaded from the Github repo.

You can either clone the public repository:

(TotalDepth) $ git clone git://github.com/paulross/TotalDepth.git

Or download the tarball:

(TotalDepth) $ curl  -OL https://github.com/paulross/TotalDepth/tarball/master

Once you have a copy of the source, you can install it with:

(TotalDepth) $ cd TotalDepth
(TotalDepth) $ python setup.py install

Install the test dependencies and run TotalDepth’s tests:

(TotalDepth) $ pip install pytest
(TotalDepth) $ pip install pytest-runner
(TotalDepth) $ python setup.py test

Developing with TotalDepth

If you are developing with TotalDepth you need the test coverage and documentation tools.

Test Coverage

Install pytest-cov:

(TotalDepth) $ pip install pytest-cov

The most meaningful invocation that elimates the top level tools is:

(TotalDepth) $ pytest --cov=TotalDepth.LAS.core --cov=TotalDepth.LIS.core --cov=TotalDepth.RP66.core --cov=TotalDepth.util --cov-report html tests/

Documentation

To build the documentation you need to:

(TotalDepth) $ pip install Sphinx
(TotalDepth) $ cd docs
(TotalDepth) $ make html

System Testing

See Testing the Plot Package for comprehensive testing of your installation to see if LIS/LAS files can be written, read and plotted. This pretty much executes all TotalDepth code.

Unit Testing

See Unit Tests for more information about testing and unit tests.