extractor

Base I3Extractor class(es).

class graphnet.data.extractors.extractor.Extractor(extractor_name)[source]

Bases: ABC, Logger

Base class for extracting information from data files.

All classes inheriting from Extractor should implement the __call__ method, and should return a pure python dictionary on the form

output = {‘var1: ..,

… ,

‘var_n’: ..}

Variables can be scalar or array-like of shape [n, 1], where n denotes the number of elements in the array, and 1 the number of columns.

An extractor is used in conjunction with a specific FileReader.

Construct Extractor.

Parameters:

extractor_name (str) – Name of the Extractor instance. Used to keep track of the provenance of different data, and to name tables to which this data is saved. E.g. “mc_truth”.

property name: str

Get the name of the Extractor instance.