cars.pipelines.default.default_pipeline

CARS default pipeline class file

Attributes

package_path

FIRST_RES

INTERMEDIATE_RES

FINAL_RES

EDGE_DETECTION

PIPELINE_CONFS

Classes

DefaultPipeline

DefaultPipeline

Functions

extract_conf_section(current_conf_section, res[, ...])

Extract applications for current resolution

extract_conf_with_resolution(current_conf, res, ...)

Extract the configuration for the given resolution

generate_filling_applications_for_surface_modeling(...)

Generate filling applications configuration according to inputs

edge_detection_available()

Return True if edge detection plugin is installed within the environment,

get_edge_detection_sensor_keys(inputs_conf[, ...])

Return the sensor keys for which edge detection outputs are available.

get_edge_detection_inputs(edge_detection_out_dir, ...)

Build the sensor inputs dictionary from edge detection plugin outputs.

add_edge_detection_inputs(inputs_conf, ...[, ...])

Inject edge detection plugin outputs into the sensor inputs configuration.

overide_pipeline_conf(conf, overiding_conf[, ...])

Merge two dictionaries recursively without removing keys from the base conf.

merge_used_conf(used_configurations, resolutions, out_dir)

Merge all used configuration

Module Contents

cars.pipelines.default.default_pipeline.package_path
cars.pipelines.default.default_pipeline.FIRST_RES = 'first_resolution'
cars.pipelines.default.default_pipeline.INTERMEDIATE_RES = 'intermediate_resolution'
cars.pipelines.default.default_pipeline.FINAL_RES = 'final_resolution'
cars.pipelines.default.default_pipeline.EDGE_DETECTION = 'edge_detection'
cars.pipelines.default.default_pipeline.PIPELINE_CONFS
class cars.pipelines.default.default_pipeline.DefaultPipeline(conf, config_dir=None)[source]

Bases: cars.pipelines.pipeline_template.PipelineTemplate

DefaultPipeline

config_dir = None
metadata
out_dir
pipeline_to_use
intermediate_data_dir
positions
used_conf
keep_low_res_dir = True
check_inputs(conf, config_dir=None)[source]

Check the inputs given

Parameters:
  • conf (dict) – configuration

  • config_dir (str) – directory of used json, if user filled paths with relative paths

Returns:

overloader inputs

Return type:

dict

check_output(conf)[source]

Check the output given

Parameters:

conf (dict) – configuration of output

:return overloader output :rtype : dict

check_pipeline(conf)[source]

Check the pipeline section

check_subsampling(conf)[source]

Check the subsampling section

Parameters:

conf (dict) – configuration of subsampling

check_filling(conf)[source]

Check the filling section

Parameters:

conf (dict) – configuration of subsampling

check_edge_detection(conf)[source]

Check the edge detection section

Parameters:

conf (dict) – configuration of edge detection

check_pipeline_section(pipeline_name, pipeline_conf)[source]

Check any pipeline section

Parameters:
  • pipeline_name (str) – key name in conf

  • pipeline_conf (dict) – pipeline configuration

cleanup_low_res_dir()[source]

Clean low res dir

construct_merging_conf(conf)[source]

Construct the right conf for merging

construct_subsampling_conf(conf)[source]

Construct the right conf for subsampling

construct_formatting_conf(input_dir)[source]

Construct the right conf for formatting

construct_filling_conf(conf)[source]

Construct the right conf for filling

construct_edge_detection_conf(conf)[source]

Construct the configuration used to run the edge detection plugin.

run(args=None)

Run pipeline

cars.pipelines.default.default_pipeline.extract_conf_section(current_conf_section, res, default_conf_for_res=None, filling_applications=None)[source]

Extract applications for current resolution

Parameters:
  • current_applications_conf (dict) – current applications configuration

  • res (int) – resolution to extract

  • default_conf_for_res (dict) – default configuration for resolution

  • filling_applications (dict) – filling applications configuration

Returns:

configuration for the given resolution

Return type:

dict

cars.pipelines.default.default_pipeline.extract_conf_with_resolution(current_conf, res, first_res, intermediate_res, last_res, intermediate_data_dir, pipeline_to_use)[source]

Extract the configuration for the given resolution

Parameters:
  • current_conf (dict) – current configuration

  • res (int) – resolution to extract

  • first_res (bool) – is first resolution

  • intermediate_res (bool) – is intermediate resolution

  • last_res (bool) – is last resolution

  • previous_out_dir – path to previous outdir

Returns:

configuration for the given resolution

Return type:

dict

Type:

previous_out_dir: str

cars.pipelines.default.default_pipeline.generate_filling_applications_for_surface_modeling(inputs_conf)[source]

Generate filling applications configuration according to inputs

Parameters:

inputs_conf (dict) – inputs configuration

cars.pipelines.default.default_pipeline.edge_detection_available()[source]

Return True if edge detection plugin is installed within the environment, False otherwise.

cars.pipelines.default.default_pipeline.get_edge_detection_sensor_keys(inputs_conf, right_image_edge_detection=False)[source]

Return the sensor keys for which edge detection outputs are available.

cars.pipelines.default.default_pipeline.get_edge_detection_inputs(edge_detection_out_dir, sensor_key)[source]

Build the sensor inputs dictionary from edge detection plugin outputs.

cars.pipelines.default.default_pipeline.add_edge_detection_inputs(inputs_conf, edge_detection_out_dir, right_image_edge_detection=False)[source]

Inject edge detection plugin outputs into the sensor inputs configuration.

cars.pipelines.default.default_pipeline.overide_pipeline_conf(conf, overiding_conf, append_classification=False)[source]

Merge two dictionaries recursively without removing keys from the base conf.

Parameters:
  • conf (dict) – base configuration dictionary

  • overiding_conf (dict) – overriding configuration dictionary

Returns:

merged configuration

Return type:

dict

cars.pipelines.default.default_pipeline.merge_used_conf(used_configurations, resolutions, out_dir)[source]

Merge all used configuration