Skip to content

Latest commit

 

History

History
124 lines (101 loc) · 5.6 KB

README.md

File metadata and controls

124 lines (101 loc) · 5.6 KB


PYRISM

Python bindings for Remote Sensing Models

Gitter

DescriptionInstallationExampleDoumentationAuthorAcknowledgments

Coverage Status Documentation Status

Description

This repository contains the Python bindings to different radar and optical backscattering and reflectance models, respectively. The bindings implement the following models:

Optical Models:

  • PROSPECT: Leaf reflectance model (versions 5 and D).
  • SAIL: Canopy reflectance model.
  • PROSAIL: Combination of PROSPECT and SAIL.
  • LSM: Simple Lambertian soil reflectance model.
  • Volume Scattering: Compute volume scattering functions and interception coefficients for given solar zenith, viewing zenith, azimuth and leaf inclination angle.

RADAR Models:

  • Rayleigh: Calculate the extinction coefficients in terms of Rayleigh scattering.
  • Mie: Calculate the extinction coefficients in terms of Mie scattering.
  • Dielectric Constants: Calculate the dielectric constant of different objects like water, saline water, soil and vegetation.
  • I2EM: RADAR soil scattering model to compute the backscattering coefficient VV and HH polarized.
  • Emissivity: Calculate the emissivity for single-scale random surface for Bi and Mono-static acquisitions.

For the optical models the code from José Gómez-Dans was used as a benchmark. The theory of the radar models is from F.T. Ulaby.

Installation

There are currently different methods to install pyrism.

Using pip

The pyrism package is provided on pip. You can install it with::

pip install pyrism

Standard Python

You can also download the source code package from this repository or from pip. Unpack the file you obtained into some directory (it can be a temporary directory) and then run::

python setup.py install

Test installation success

Independent how you installed pyrism, you should test that it was sucessfull by the following tests::

python -c "from pyrism import I2EM"

If you don't get an error message, the module import was sucessfull.

Example

At first we will run the PROSPECT model. To do this we import the pyrism package.

import pyrism

After that we specify the sensing geometry we want to simulate:

iza = 35  # Incidence zenith angle
vza = 30  # Viewing zenith angle
raa = 50  # Relative azimuth angle

Than we call the PROSPECT model:

prospect = pyrism.PROSPECT(N=1.5,
                          Cab=35,
                          Cxc=5,
                          Cbr=0.15,
                          Cw=0.003,
                          Cm=0.0055)

To access the attributes there are to ways. Firstly, we can access the whole spectrum with prospect.ks (scattering coefficient), prospect.ka (absorption coefficient), prospect.kt (transmittance coefficient), prospect.ke (extinction coefficient) and prospect.om (the division of ks through ke). Moreover, you can select the coefficient values for the specific bands of ASTER (B1 - B9) or LANDSAT8 (B2 - B7). To access these bands type prospect.L8.Bx (x = 2, 3, ..., 7) for Landsat 8 or prospect.ASTER.Bx (x = 1, 2, ..., 9) for ASTER.

To calculate the PROSAIL model we need some soil reflectance values. To obtain these we can use the LSM model:

lsm = pyrism.LSM(reflectance=3.14 / 4, moisture=0.15)

Now we must call SAIL and specify the scattering and transmittance coefficients with these from PROSPECT like:

prosail = pyrism.SAIL(iza=iza, vza=vza, raa=raa, ks=prospect.ks, kt=prospect.kt, rho_surface=lsm.ref,
                      lidf_type='campbell',
                      lai=3, hotspot=0.25)

The accessibility of the attributes are the same as the PROSPECT model.

Documentation

You can find the full documentation here.

Built With

  • Python 2.7 (But it works with Python 3.5 as well)
  • Requirements: numpy, scipy

Authors

Acknowledgments


ResearchGate @Ismail_Baris  ·  GitHub @ibaris  ·  Instagram @ism.baris