PseudoNetCDF like NetCDF except for many scientific format backends
Clone or download
Latest commit d2cca9e Oct 22, 2018

PseudoNetCDF like NetCDF except for many scientific format backends

Build Status


PseudoNetCDF provides read, plot, and sometimes write capabilities for atmospheric science data formats including:

  • CAMx (
  • RACM2 box-model outputs
  • Kinetic Pre-Processor outputs
  • ICARTT Data files (ffi1001)
  • CMAQ Files
  • GEOS-Chem Binary Punch/NetCDF files

for a full list of formats see pncdump --list-formats

Example code

Code below needs paths and formats filled in. The format should be chosen from "Current Formats" below. Note that there are many methods for modifying the files. Use help on infile to learn more options.

import PseudoNetCDF as pnc
inpath = '<path-to-input>'
outpath = '<path-for-output>'
infile = pnc.pncopen(inpath, format = '<choose-format-below>')
# Print CDL representation - good for learning dimensions, variables, and properties
# Optionally, add dimension slicing
# infile = infile.sliceDimensions(<layer-dim-name> = 0)
# infile = infile.applyAlongDimenions(<time-dim-name> = 'mean')
# patches = infile.plot('<varkey>', plottype = 'longitude-latitude')
# patches.axes.figure.savefig('<path-for-figure>')

Example Command Line Interfaces

pncdump - like ncdump pncgen - reads from a file and generates a netcdf file pncload - read in a file and open a python environment

$ pncdump -f <choose-format-below> <path-to-input>
$ pncgen -f <choose-format-below> <path-to-input> <path-to-output>
$ pncload -f <choose-format-below> <path-to-input>

Current Formats

Long Name Short Name
netcdf netcdf
cmaqfiles.ioapi ioapi
cmaqfiles.jtable jtable
epafiles.aqsraw aqsraw
geoschemfiles.bpch bpch
geoschemfiles.bpch2 bpch2
geoschemfiles.flightlogs flightlogs
geoschemfiles.geos geos
noaafiles.arlpackedbit arlpackedbit
noaafiles.arlconcdump arlconcdump
noaafiles.arlpackedbit arlpackedbit
noaafiles.arlpardump arlpardump
noaafiles.arltrajdump arltrajdump
textfiles.csv csv
cmaqfiles.profile.bcon_profile bcon_profile
cmaqfiles.profile.icon_profile icon_profile
icarttfiles.ffi1001.ffi1001 ffi1001
camxfiles.cloud_rain.Memmap.cloud_rain cloud_rain
camxfiles.finst.Memmap.finst finst
camxfiles.height_pressure.Memmap.height_pressure height_pressure
camxfiles.humidity.Memmap.humidity humidity
camxfiles.ipr.Memmap.ipr ipr
camxfiles.irr.Memmap.irr irr
camxfiles.landuse.Memmap.landuse landuse
camxfiles.lateral_boundary.Memmap.lateral_boundary lateral_boundary
camxfiles.point_source.Memmap.point_source point_source
camxfiles.temperature.Memmap.temperature temperature
camxfiles.uamiv.Memmap.uamiv uamiv
camxfiles.uamiv.Transforms.osat osat
camxfiles.vertical_diffusivity.Memmap.vertical_diffusivity vertical_diffusivity
camxfiles.wind.Memmap.wind wind

More information

Lots more available at our wiki

Try our:

Quick tour:

  • Install:
  • pip install for the most stable version or
  • pip install for the latest.
  • Download example icartt file: e.g., HOx from INTEX-NA
  • curl -L
  • Dump an icartt file in CDL: pncdump -f ffi1001 HOX_DC8_20040626_R0.ict
  • Create a netcdf from an icartt file: pncgen -f ffi1001 HOX_DC8_20040626_R0.ict