ccplot

CloudSat and CALIPSO plotting tool

Installation

Archive of ccplot releases

DateRelease
8 September 2023 ccplot 2.1.4
Release notes | Show all

Introduction

ccplot works on Linux, macOS, and Windows. For best experience, it is recommended to install ccplot on Linux.

Archived installation instructions for past versions of ccplot are available here:

Below, you can find installation instructions for:

Linux

The installation works with either native Python 3 on Linux distributions, or with Anaconda. The instructions below are for native Python 3.

Dependencies on Debian-based distributions (Debian, Ubuntu, Devuan, …)

To install dependencies, enter the following command in the terminal:

sudo apt install --no-install-recommends python3 python3-dev python3-pip gcc python3-distutils pipx cython3 libhdf4-dev libhdfeos-dev python3-pil python3-numpy python3-scipy python3-matplotlib python3-cartopy python3-packaging python3-tz ttf-bitstream-vera proj-bin

Dependencies on Fedora

On Fedora, download szip-2.1.1.tar.gz and hdf-eos2-3.0-src.tar.gz from Earthdata Wiki, and install dependencies with the following commands in the terminal:

sudo yum install g++ make python3-devel python3-Cython python3-numpy python3-matplotlib python3-cartopy python3-pytz pipx hdf-devel zlib-devel
tar xf szip-2.1.1.tar.gz
cd szip-2.1.1
./configure --prefix=/usr/local
make
sudo make install
cd ..
tar xf hdf-eos2-3.0-src.tar.gz
cd hdf-eos2-3.0
./configure CFLAGS=-I/usr/include/hdf --prefix=/usr/local --enable-install-include --with-pic
make
sudo make install

Installation of ccplot

To install ccplot, enter the following commands in the terminal:

pipx install ccplot
mkdir -p ~/.local/share/man/man1
ln -s ~/.local/pipx/venvs/ccplot/share/man/man1/ccplot.1 ~/.local/share/man/man1/

You might have to add “$HOME/.local/bin” the PATH environment variable if not already.

Alternatively, to install ccplot from an archive:

pipx install ./ccplot-x.y.z.tar.gz
mkdir -p ~/.local/share/man/man1
ln -s ~/.local/pipx/venvs/ccplot/share/man/man1/ccplot.1 ~/.local/share/man/man1/

ccplot <= 2.1.2: Instead of pipx, install with pip3 install ccplot or pip install ccplot if pip3 is not available.

You should now be able to run ccplot in the terminal:

ccplot -V

and view the manual page with:

man ccplot

Windows

Option 1: Native

ccplot can be installed from a binary distribution (Python wheel) in the official Python distribution.

To install ccplot on Windows:

  1. Install Python 3.11 (later versions are currently not supported). In the installer, tick Add python.exe to PATH.

  2. Open the Command Prompt from the Windows Start Menu. Install ccplot with:

    pip install ccplot
    

You should now be able to run ccplot in the Command Prompt:

ccplot -V

Option 2: Windows Subsystem for Linux

On Windows, it is possible to install ccplot under the “Windows Subsystem for Linux” (WSL), which is a full-featured Linux distribution running on Windows. Unlike the native installation described above, ccplot can only be run in the WSL environment, and the ccplot API is only available in Python programs run within this environment.

  1. Install the “Windows Subsystem for Linux” (found under Settings → Optional features → More Windows features).

  2. Open Microsoft Store and install “Ubuntu”.

  3. Open “Ubuntu” in the Start Menu.

  4. In the console, type:

    sudo apt update
    sudo apt upgrade
    

    and then follow the instructions above for installing ccplot on Ubuntu Linux. Use cd /mnt/c/Users/<user> to change the current directory to the Windows user’s home directory, where <user> is the name of your Windows user account, and ls to list the content of a directory.

Option 3: Building from source code

Follow these instructions if you want to build ccplot and the dependent libraries from source code. This is the most difficult installation method, but it can theoretically work with future versions of Python.

  1. Install:

    When installing Visual Studio, tick “Desktop development with C++”.

  2. Download and decompress:
  3. Open HDFEOS2.sln located in the HDF-EOS2 directory vs2019\HDF-EOS2 in Visual Studio. When prompted, choose to convert the project to the latest version of Visual Studio. Rename include\HE2_config.h.in to HE2_config.h. Set solution configuration to “Release”. Add paths to the include and lib directories of HDF4 to “Include Directories” and “Library Directories” under “VC++ Directories” under the project properties. Perform “Build” -> “Build solution”.

  4. Open the Command Prompt from the Windows Start Menu and run:

    pip install wheel cython numpy
    cd <ccplot-dir>
    set HDF_DIR=<hdf-dir>
    set HDFEOS_DIR=<hdfeos-dir>
    python setup.py bdist_wheel
    pip install dist\ccplot-2.1.4-cp311-cp311-win_amd64.whl
    

where <ccplot-dir>, <hdf-dir> and <hdfeos-dir> are the directories where you decompressed the respective packages.

You should now be able to run ccplot in the Command Prompt:

ccplot -V

macOS

This installation has been tested on macOS Ventura on Intel.

  1. Install MacPorts.

  2. Install required MacPorts packages. Enter the following command in the macOS Terminal:

     sudo port install jpeg hdf4 hdfeos
    
  3. Install required Python packages:

     python3 -m pip install cython numpy
    
  4. Install ccplot:

     python3 -m pip install ccplot
    

    Alternatively, to install ccplot from an archive:

     python3 -m pip install ccplot-x.y.z.tar.gz
    

You should now be able to run ccplot in the macOS Terminal:

ccplot -V

Your experience

If you have any difficulty with the installation, or if you find a bug, please write to the mailing list at ccplot-general@lists.sourceforge.net or submit an issue on GitHub. Please also check the known issues below.

Tutorial

Please continue with ccplot manual (Chapter 6) in Visualising Data from CloudSat and CALIPSO Satellites and ccplot man page.

License

ccplot is provided under the terms of a BSD license, allowing you to redistribute, modify and use the software in free and commercial products without restrictions.

Known issues

26 November 2021

Cartopy < 0.18.0 is not able to plot longitude/latitude labels for projections other than Plate Carree and Mercator. Ubuntu 20.04 ships with Cartopy 0.17. It is possible to use Anaconda instead, which has a newer version of Cartopy.

16 March 2021

basemap version 1.2.1 is incompatible with recent versions of matplotlib. You might get this error message:

ImportError: cannot import name 'dedent' from 'matplotlib.cbook'

Please follow the instructions above for Ubuntu 20.10 for installing the latest basemap version from GitHub.

10 October 2015

A bug in matplotlib 1.4.3 causes a warning to be printed:

matplotlib/collections.py:590: FutureWarning: elementwise comparison failed; returning scalar instead, but in the future will perform elementwise comparison

It should be fixed in matplotlib 1.5.0 (issue #5209).

4 June 2013

There is a bug with python-dap which causes a warning to be printed:

/usr/lib/pymodules/python2.7/mpl_toolkits/__init__.py:2: UserWarning: Module dap was already imported from None, but /usr/lib/python2.7/dist-packages is being added to sys.path
__import__('pkg_resources').declare_namespace(__name__)

Package python-dap is installed on Ubuntu and Debian as “recommended” by python-mpltoolkits.basemap. It can be removed (as it is not required), and the warning will not appear any more.

The bug has already been reported to the Debian bug reporting system.

12 June 2013

ccplot < 1.5 There is a bug in NetCDF compatibility layer of libhdf4 (used by PyNIO) which causes wrong size of datasets to be reported. As a result, the data may be trimmed by a relatively small amount of rays at the end of a granule. The bug has been confirmed by the HDF Group, and is being solved.

16 June 2013

ccplot <= 1.4.6 There was a serious bug in the visualization of CALIPSO profiles, whereby the altitude of data points was shifted by one element, resulting in a difference of as much as 300m relative to their true location. The difference in the highest-resolution regions was 60m.