cars.pipelines.parameters.output_parameters

This module contains the output definition

Functions

is_valid_epsg(epsg) → bool

Check if the given EPSG code is valid using pyproj.

check_resolution_value(value)

Check that a rectangular resolution contains two numeric values.

check_resolution(resolution, epsg)

Check the resolution parameter and convert it to the unit expected by

check_output_parameters(inputs, conf[, scaling_coeff, ...])

Check the output json configuration and fill in default values

check_phasing_output_parameters(phasing, output)

Check consistency between phasing and output configuration.

check_product_format(overloaded_conf)

Check the product format

check_filling_parameter(overloaded_conf)

Check and overload filling parameter

check_texture_bands(inputs, overloaded_conf)

Check and overload texture bands

check_classification_parameter(inputs, overloaded_conf)

Check and overload classification parameter

check_performance_classes(overloaded_conf)

Check performance classes

intialize_product_index(orchestrator, product_levels, ...)

Initialize the index dictionary according to requested levels with None

Module Contents

cars.pipelines.parameters.output_parameters.is_valid_epsg(epsg) → bool[source]

Check if the given EPSG code is valid using pyproj.

cars.pipelines.parameters.output_parameters.check_resolution_value(value)[source]

Check that a rectangular resolution contains two numeric values.

cars.pipelines.parameters.output_parameters.check_resolution(resolution, epsg)[source]

Check the resolution parameter and convert it to the unit expected by the selected CRS.

The resolution value can be either scalar or rectangular.

Projected CRS:

meter -> meter

Geographic CRS:

degree -> degree arcsec -> degree

Any other unit/CRS combination raises a RuntimeError.

Parameters:
  • resolution (int, float, list, dict, or None) – resolution parameter to check

  • epsg (int or None) – EPSG code for the coordinate reference system

Returns:

resolution value in meters or degrees

Return type:

int, float, list, or None

cars.pipelines.parameters.output_parameters.check_output_parameters(inputs, conf, scaling_coeff=None, bounds=None)[source]

Check the output json configuration and fill in default values

Parameters:
  • conf (dict) – configuration of output

  • scaling_coeff (float) – scaling factor for resolution

  • pipeline_name (str) – name of corresponding pipeline

cars.pipelines.parameters.output_parameters.check_phasing_output_parameters(phasing, output)[source]

Check consistency between phasing and output configuration.

The phasing CRS must match the horizontal component of the output CRS. When phasing is enabled, an output EPSG must be explicitly specified.

Parameters:
  • phasing (dict or None) – validated phasing configuration

  • output (dict) – validated output configuration

Raises:

RuntimeError – If phasing is enabled without an output EPSG, or if the phasing CRS does not match the horizontal component of the output CRS.

Returns:

EPSG to use for terrain processing

Return type:

int or None

cars.pipelines.parameters.output_parameters.check_product_format(overloaded_conf)[source]

Check the product format

cars.pipelines.parameters.output_parameters.check_filling_parameter(overloaded_conf)[source]

Check and overload filling parameter

cars.pipelines.parameters.output_parameters.check_texture_bands(inputs, overloaded_conf)[source]

Check and overload texture bands

cars.pipelines.parameters.output_parameters.check_classification_parameter(inputs, overloaded_conf)[source]

Check and overload classification parameter

cars.pipelines.parameters.output_parameters.check_performance_classes(overloaded_conf)[source]

Check performance classes

cars.pipelines.parameters.output_parameters.intialize_product_index(orchestrator, product_levels, input_pairs)[source]

Initialize the index dictionary according to requested levels with None values for all paths.

Parameters:
  • orchestrator (Orchestrator) – cars orchestrator

  • product_levels (list) – name of corresponding pipeline

  • input_pairs (list) – list containing the pair names