analyzer.modules.common.column_tools

Attributes

Classes

Count

Abstract base class for all analyzer modules.

PromoteIndex

Promote a fixed index of a nested collection to a top-level column.

Concatenate

Abstract base class for all analyzer modules.

Module Contents

analyzer.modules.common.column_tools.logger[source]
class analyzer.modules.common.column_tools.Count[source]

Bases: analyzer.core.analysis_modules.AnalyzerModule

Abstract base class for all analyzer modules. Subclasses must implement the inputs and run methods.

input_col: analyzer.core.columns.Column[source]
output_col: analyzer.core.columns.Column[source]
run(columns, params)[source]
inputs(metadata)[source]
outputs(metadata)[source]
class analyzer.modules.common.column_tools.PromoteIndex[source]

Bases: analyzer.core.analysis_modules.AnalyzerModule

Promote a fixed index of a nested collection to a top-level column.

This analyzer selects a single element at a given index from each entry of a nested (jagged) input collection and stores it as a top-level column. It is commonly used to extract leading or sub-leading objects (e.g. leading jet, first lepton) from per-event collections.

Parameters

input_colColumn

Column containing a nested collection (e.g. N × M objects).

output_colColumn

Column where the selected elements will be stored.

indexint, optional

Index of the element to promote from each nested collection, by default 0 (leading element).

input_col: analyzer.core.columns.Column[source]
output_col: analyzer.core.columns.Column[source]
index: int = 0[source]
run(columns, params)[source]
inputs(metadata)[source]
outputs(metadata)[source]
class analyzer.modules.common.column_tools.Concatenate[source]

Bases: analyzer.core.analysis_modules.AnalyzerModule

Abstract base class for all analyzer modules. Subclasses must implement the inputs and run methods.

input_cols: list[analyzer.core.columns.Column][source]
output_col: analyzer.core.columns.Column[source]
run(columns, params)[source]
inputs(metadata)[source]
outputs(metadata)[source]
adlExport(metadata)[source]