These SCIAMACHY tools are provided as convenience tools for handling SCIAMACHY level 1c limb spectra and retrieved level 2 trace-gas densities.
More extensive documentation is provided on sciapy.rtfd.io.
The sciapy.level1c submodule provides a few
conversion tools for SCIAMACHY
level 1c calibrated spectra, to be used as input for trace gas retrieval with
scia_retrieval_2d.
Note that this is not a level 1b to level 1c calibration tool.
For calibrating level 1b spectra (for example SCI_NL__1P version 8.02
provided by ESA via the
ESA data browser)
to level 1c spectra, use the
SciaL1C
command line tool or the free software
nadc_tools.
The first produces .child files, the second can output to HDF5 (.h5).
Further note: .child files are currently not supported.
The sciapy.level2 submodule provides
post-processing tools for trace-gas densities retrieved from SCIAMACHY limb scans.
Support simple operations as combining files into netcdf, calculating and noting
local solar time at the retrieval grid points, geomagnetic latitudes, etc.
The level 2 tools also include a simple binning algorithm.
The sciapy.regress submodule can be used for regression analysis of SCIAMACHY
level 2 trace gas density time series, either directly or as daily zonal means.
It uses the regressproxy package
for modelling the proxy input with lag and lifetime decay.
The regression tools support various parameter fitting methods using
scipy.optimize
and uncertainty evaluation using Markov-Chain Monte-Carlo sampling with
emcee.
Further supports covariance modelling via
celerite
and george.
Sciapy uses features from a lot of different packages.
All dependencies will be automatically installed when using
pip install or python setup.py, see below.
However, to speed up the install or for use
within a conda environment, it may be advantageous to
install some of the important packages beforehand:
numpyat least version 1.13.0 for general numerics,scipyat least version 0.17.0 for scientific numerics,matplotlibat least version 2.2 for plotting,netCDF4for the low level netcdf4 interfaces,h5pyfor the low level hdf5 interfaces,dask,toolz,pandasandxarrayfor the higher level data interfaces,astropyfor (astronomical) time conversions,parsefor ASCII text parsing inlevel1c,pybind11C++ interface needed byceleriteceleriteat least version 0.3.0 andgeorgefor Gaussian process modelling,emceefor MCMC sampling andcornerfor the sample histogram plots,regressproxyfor the regression proxy modelling.
Out of these packages, numpy is probably the most important one
to be installed first because at least celerite needs it for setup.
It may also be a good idea to install
pybind11
because both celerite and george use its interface,
and both may fail to install without pybind11.
Depending on the setup, numpy and pybind11 can be installed
via pip:
pip install numpy pybind11or conda:
conda install numpy pybind11Official releases are available as pip packages from the main package repository,
to be found at https://pypi.org/project/sciapy/, and which can be installed with:
$ pip install sciapyThe latest development version of
sciapy can be installed with pip directly
from github (see https://pip.pypa.io/en/stable/reference/pip_install/#vcs-support
and https://pip.pypa.io/en/stable/reference/pip_install/#git):
$ pip install [-e] git+https://github.com/st-bender/sciapy.gitThe other option is to use a local clone:
$ git clone https://github.com/st-bender/sciapy.git
$ cd sciapyand then using pip (optionally using -e, see
https://pip.pypa.io/en/stable/reference/pip_install/#install-editable):
$ pip install [-e] .or using setup.py:
$ python setup.py installThe whole module as well as the individual submodules can be loaded as usual:
>>> import sciapy
>>> import sciapy.level1c
>>> import sciapy.level2
>>> import sciapy.regressBasic class and method documentation is accessible via pydoc:
$ pydoc sciapyThe submodules' documentation can be accessed with pydoc as well:
$ pydoc sciapy.level1c
$ pydoc sciapy.level2
$ pydoc sciapy.regressThis python package is free software: you can redistribute it or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2 (GPLv2), see local copy or online version.
