isofit.radiative_transfer.engines.modtran

Attributes

Logger

eps

tropopause_altitude_km

Classes

ModtranRT

A model of photon transport including the atmosphere.

Module Contents

Logger[source]
eps = 1e-05[source]
tropopause_altitude_km = 17.0[source]
class ModtranRT(engine_config: RadiativeTransferEngineConfig, lut_path: str = '', lut_grid: dict = None, wavelength_file: str = None, interpolator_style: str = 'mlg', build_interpolators: bool = True, overwrite_interpolator: bool = False, wl: numpy.array = [], fwhm: numpy.array = [])[source]

Bases: isofit.radiative_transfer.radiative_transfer_engine.RadiativeTransferEngine

A model of photon transport including the atmosphere.

max_buffer_time = 0.5[source]
static parseTokens(tokens: list, coszen: float) dict[source]

Processes tokens returned by parseLine()

Parameters:
  • tokens (list) – List of floats returned by parseLine()

  • coszen (float) – cos(zenith(filename))

Returns:

Dictionary of calculated values using the tokens list

Return type:

dict

static parseLine(line: str) list[source]

Parses a single line of a .chn file into a list of token values

Parameters:

line (str) – Singular data line of a MODTRAN .chn file

Returns:

List of floats parsed from the line

Return type:

list

load_chn(file: str, coszen: float, header: int = 5) dict[source]

Parses a MODTRAN channel file and extracts relevant data

Parameters:
  • file (str) – Path to a .chn file

  • coszen (float) –

  • header (int, defaults=5) – Number of lines to skip for the header

Returns:

chn – Channel data

Return type:

dict

static load_tp6(file)[source]

Parses relevant information from a tp6 file. Specifically, seeking a table in the unstructured text and extracting a column from it.

Parameters:

tp6 (str) – tp6 file path

preSim()[source]

Post-initialized, pre-simulation setup

readSim(point)[source]

For a given point, parses the tp6 and chn file and returns the data

makeSim(point, file=None, timeout=None)[source]

Prepares the command to execute MODTRAN

modtran_driver(overrides)[source]

Write a MODTRAN 6.0 input file.

check_modtran_water_upperbound() float[source]

Check to see what the max water vapor values is at the first point in the LUT

Returns:

max water vapor value, or None if test fails

Return type:

float

static modtran_water_upperbound_polynomials() dict[source]

Polynomials as a function of ground altitude (km) to estimate upperbound of water column vapor (g/cm2).

Returns:

3rd degree polynomials to estimate upperbound of water column vapor

Return type:

dict

static modtran_aot_lowerbound_polynomials() dict[source]

Polynomials as a function of ground altitude (km) to estimate lowerbound of AOT at 550nm.

Returns:

3rd degree polynomials to estimate lowerbound of AOT

Return type:

dict

required_results_exist(filename_base)[source]
wl2flt(wavelengths: numpy.array, fwhms: numpy.array, outfile: str) None[source]

Helper function to generate Gaussian distributions around the center wavelengths.

Parameters:
  • wavelengths – wavelength centers

  • fwhms – full width at half max

  • outfile – file to write to