Welcome to FOAM’s documentation!

The Forward Ocean Atmosphere Microwave (FOAM) package is a radiative transfer model that can be used to simulate polarimetric microwave radiometer observations of the ocean. FOAM permits simulations with variable levels of fidelity, from an ideal ocean to a more realistic one.

The core of the model is the ocean module, which contains models for specular and wind-roughened oceans. Wind roughening is implemented for different ocean classes as

  • ocean.ocean: interpolation of geophysical model functions (GMF) developed at discrete frequencies (e.g. papers by Meissner and Wentz).

  • ocean.fastem: the FASTEM-5 ocean emissivity model

  • ocean.two_scale, a full two-scale model (originally developed by Simon Yueh).

This module is combined with the atmosphere, ionosphere, and sky modules to create a full forward model, which is controlled at a high level by the solver module.

The SPICE-based spacecraft module can be used to simulate pointing information from an orbiting spacecraft

Several modules can operate in an online mode and download ancillary data from OpenDAP servers based on a user-specified datetime object. Details of the ancillary data sources can be found in module documentation.

FOAM is <v1, so subsequent updates may signficantly alter workflow. Feel free to recommend changes that can improve the model via Github. If you notice any issues with FOAM, please raise an issue through GitHub or e-mail Alex Akins at alexander.akins@jpl.nasa.gov

Installation and Development

To test FOAM, download the package from the repository and build locally using pip install -e .

FOAM modules download ancillary data from OpenDAP servers hosted by DAACs and other sources. To use FOAM, the user must configure .netrc, .urs_cookies, and .dodsrc files in their home directories following the instructions at https://disc.gsfc.nasa.gov/data-access.

In your URS Earth data user profile, it will be necessary to authorize applications for PODAAC, GESDISC, CDDIS, and NSIDC (see https://urs.earthdata.nasa.gov/users/your_user_name/authorized_apps) to download files remotely

Before use, FOAM needs to build a local cache. Execute the following in a Python terminal

import foam.utils.config as config
config.setup_cache()
config.get_ancillary_data()

This will setup the cache (.foam) in your home directory and download some ancillary data required to use FOAM offline.

There are several non-automated tests in the tests/ directory that demonstrate use cases for each module. Any changes in the documentation can be compiled using sphinx-build -b html source build

Indices and tables