eradiate.experiments.DEMExperiment#
- class eradiate.experiments.DEMExperiment(measures=NOTHING, results=NOTHING, default_spectral_set=AUTO, quad_spec=NOTHING, extra_objects=None, illumination=NOTHING, geometry='plane_parallel', atmosphere=NOTHING, surface=NOTHING, integrator=NOTHING)[source]#
Bases:
EarthObservationExperimentSimulate radiation in a scene with a digital elevation model (DEM) under a 1D atmosphere.
- Parameters:
measures (
listofMeasureorlistofdictorMeasureordict, default:MultiDistantMeasure()) – List of measure specifications. The passed list may contain dictionaries, which will be interpreted bymeasure_factory. Optionally, a singleMeasureor dictionary specification may be passed and will automatically be wrapped into a list.default_spectral_set (
BinSetorWavelengthSetorAUTO, default:AUTO) – Default spectral set. This attribute is used to set the default value forspectral_set.If the value isAUTO, the default spectral set is selected based on the active mode. Otherwise, the value must be aBinSetorWavelengthSetinstance.extra_objects (
dictorNone, default:None) – Dictionary of extra objects to be added to the scene. The keys of this dictionary are used to identify the objects in the kernel dictionary.illumination (
DirectionalIlluminationordict, default:DirectionalIllumination()) – Illumination specification. This parameter can be specified as a dictionary which will be interpreted byillumination_factory.geometry (
{"plane_parallel", "spherical_shell"}ordictorPlaneParallelGeometryorSphericalShellGeometry, default:"plane_parallel") – Problem geometry.atmosphere (
AtmosphereordictorNone, default:HomogeneousAtmosphere()) – Atmosphere specification. If set toNone, no atmosphere will be added. This parameter can be specified as a dictionary which will be interpreted byatmosphere_factory.surface (
BasicSurfaceorDEMSurfaceorBSDFordict, optional, default:BasicSurface(bsdf=LambertianBSDF())) – Surface specification. If set toNone, no surface will be added. This parameter can be specified as a dictionary which will be interpreted bysurface_factoryandbsdf_factory.integrator (
VolPathIntegratorordict, default:VolPathIntegrator()) – Monte Carlo integration algorithm specification. This parameter can be specified as a dictionary which will be interpreted byintegrator_factory. The DEMExperiment requiresthe use of a .VolPathIntegrator.
- Fields:
measures (
listofMeasure) – List of measure specifications.default_spectral_set (
BinSetorWavelengthSet) – Default spectral set.extra_objects (
dict) – Dictionary of extra objects to be added to the scene.illumination (
DirectionalIllumination) – Illumination specification.geometry (
SceneGeometry) – Problem geometry.atmosphere (
AtmosphereorNone) – Atmosphere specification.
Warning
Although technically supported, DEMs extending below 0 elevation may be a tricky case because atmospheric profile behaviour below sea level is undefined. This will be addressed in a future release.
Notes
When using distant measures, setting a target is highly recommended. This experiment will issue a warning during configuration if it detects that a distant measure is used with no or an inappropriate target. If a distant measure is used and no target is set, it defaults to [0, 0, 0].
This experiment supports arbitrary measure positioning, except for
MultiRadiancemeterMeasure, for which subsensor origins are required to be either all inside or all outside of the atmosphere. If an unsuitable configuration is detected, aValueErrorwill be raised during initialization.Even without an atmosphere, this experiment requries using a volumetric path tracing integrator.
- clear()#
Clear previous experiment results and reset internal state.
- init()#
Generate kernel dictionary and initialise Mitsuba scene.
- pipeline(measure)#
Return the post-processing pipeline for a given measure.
- process(spp=0, seed_state=None)#
Run simulation and collect raw results.
- Parameters:
- spectral_indices(measure_index)#
Generate spectral indices for a given measure.
- Parameters:
measure_index (
int) – Measure index for which spectral indices are generated.- Yields:
SpectralIndex– Spectral index.
- property context_init#
Return a single context used for scene initialization.
- property contexts#
Return a list of contexts used for processing.
- property integrator#
Integrator used to solve the radiative transfer equation.
- Type:
- property results#
Post-processed simulation results.
- Returns:
dict[str,Dataset]– Dictionary mapping measure IDs to xarray datasets.
- property scene#
Return a scene object used for kernel dictionary template and parameter table generation.
- property spectral_set#
A dictionary mapping measure index to the associated spectral set.