Skip to main content
Factory for constructing omics transforms by name.

create_transform

Creates a single omics transform by name.
Transform identifier (case-insensitive). One of "log1p", "expm1", "tpm", "zscore", "subset_columns".
Arguments forwarded to the transform constructor. For example zscore requires mean and std; tpm accepts an optional factor.
Returns: An instantiated OmicsPreprocessor. Raises:
  • BioptimusValueError - With code ErrorCode.INVALID_CONFIG if name is not in the registry, or if kwargs do not match the transform’s constructor signature (e.g. required arguments are missing or unexpected ones are given). It subclasses ValueError, so except ValueError still catches it.

create_pipeline

Builds an OmicsPipeline from a list of step configs. Each config dict must contain a "name" key; remaining entries are passed as keyword arguments to the constructor.
Ordered list of transform specifications, e.g.:
Returns: A pipeline that chains the transforms in order. An empty configs list yields an empty (identity) pipeline. Raises:
  • BioptimusValueError - With code ErrorCode.INVALID_CONFIG if a step config is missing the "name" key, or if a step’s name is unknown or its arguments are invalid (see create_transform). It subclasses ValueError.