Implementations of DataTransformer.

class ChainedDataTransformer(transformers: Iterable[DataTransformer], extend: bool = True)[source]#

Bases: DataTransformer

Combine multiple DataTransformer classes into one.

  • transformer – Ordered list of transformers that you want to chain.

  • extend – Set to True in order to keep keys of each output DataSample and collect them into the final, chained DataSample.

transformers: tuple[DataTransformer, ...]#
extend: bool#
class IdentityTransformer(*args, **kwds)[source]#

Bases: DataTransformer

DataTransformer that leaves a DataSample intact.

class SympyDataTransformer(functions: Mapping[str, Function])[source]#

Bases: DataTransformer

Implementation of a DataTransformer.

property functions: dict[str, Function]#

Read-only access to the internal mapping of functions.

classmethod from_sympy(expressions: dict[Symbol, Expr], backend: str, *, use_cse: bool = True, max_complexity: int | None = None) SympyDataTransformer[source]#