columnflow.production#
Tools for producing new array columns (e.g. high-level variables).
Classes:
|
Base class for all producers. |
Functions:
|
Decorator for creating a new |
- class Producer(*args, **kwargs)[source]#
Bases:
TaskArrayFunctionBase class for all producers.
Attributes:
Methods:
producer([func, bases, mc_only, data_only])Decorator for creating a new
Producersubclass with additional, optional bases and attaching the decorated function to it ascall_func().- exposed = True#
- classmethod producer(func=None, bases=(), mc_only=False, data_only=False, **kwargs)[source]#
Decorator for creating a new
Producersubclass with additional, optional bases and attaching the decorated function to it ascall_func().When mc_only (data_only) is True, the producer is skipped and not considered by other calibrators, selectors and producers in case they are evaluated on a
order.Dataset(using thedataset_instattribute) whoseis_mc(is_data) attribute is False.All additional kwargs are added as class members of the new subclasses.
- Parameters:
func (Callable | None, default:
None) – Function to be wrapped and integrated into newProducerclass.bases (tuple, default:
()) – Additional bases for the newProducer.mc_only (bool, default:
False) – Boolean flag indicating that thisProducershould only run on Monte Carlo simulation and skipped for real data.data_only (bool, default:
False) – Boolean flag indicating that thisProducershould only run on real data and skipped for Monte Carlo simulation.
- Return type:
DerivableMeta | Callable
- Returns:
New
Producersubclass.
- cache_instances = True#
- producer(func=None, bases=(), mc_only=False, data_only=False, **kwargs)#
Decorator for creating a new
Producersubclass with additional, optional bases and attaching the decorated function to it ascall_func().When mc_only (data_only) is True, the producer is skipped and not considered by other calibrators, selectors and producers in case they are evaluated on a
order.Dataset(using thedataset_instattribute) whoseis_mc(is_data) attribute is False.All additional kwargs are added as class members of the new subclasses.
- Parameters:
func (Callable | None, default:
None) – Function to be wrapped and integrated into newProducerclass.bases (tuple, default:
()) – Additional bases for the newProducer.mc_only (bool, default:
False) – Boolean flag indicating that thisProducershould only run on Monte Carlo simulation and skipped for real data.data_only (bool, default:
False) – Boolean flag indicating that thisProducershould only run on real data and skipped for Monte Carlo simulation.
- Return type:
DerivableMeta | Callable
- Returns:
New
Producersubclass.