The net.simplace.sim.transformers Package

Transformers change data from resources before simulation start

Overview

Transformers normally act on resources and produce new resources, e.g. unit conversion, subdivision of layered data, aggregation etc.

The data is transformed before the simulation starts.

General Description

There are different types of transformers

Column transformers

They take colums of an existing resource and transforms them to coresponding columns of a new resource.

Column transformers have the same key values as the resource they transform. The key columns and the transformed columns are in the same order as in the resource.

Example: The SoilLayer transformer creates from each layered soil property of arbitrary depth a soil property with fixed layer depth.

Transformer-Generators

They take columns of an existing resource and generate one ore more columns of a new resource

Transformer-Generators often have an additional key column. The order of the keys is determined by the transformer. Some transformers can transform only resources that have a single key column. The number, datatype and order of the generated columns is determined by the transformer. See the documentation of particular transformer for details.

Example: The AstronomicParameterTransformer that transforms a resource containing a latitude column to a new resource that holds for each latitude in the resource the corresponding daylengths of all DOYs. The resulting resource has first the DOY as a key column, followed by the key column of the resources and then the columns for Daylength, PhotoperiodicDaylength, SolarConstant ... in this order.

Resourceless Generators

They transform no resource, but rather take parameters and generate a new resource.

The key column(s) and the number, datatype and order of the generated columns are defined by the transformer. See the documentation of particular transformer for details.

Example: The !Daylength transformer takes latitude as a parameter and generates daylengths of all DOYs. The only key column is the DOY.

Notice

When transformation depends on simulated values or when simulations within one project need custom transformations (e.g. for calibration) then the transformers can not be used. In these cases transforming sim components can help.

Some transformer's behaviour depends on the input configuration. The astronomic parameter transformer can act as a transformer-generator as well as a resourceless generator.

See individual transformer documentation for details.



See also: net.simplace.sim.components.util

Class hierarchy of package net.simplace.sim.transformers