Converter for scikit-learn PolynomialFeatures.

class*args: Any, **kwargs: Any)[source]

Bases: PhysicalOperator, Module

Class implementing PolynomialFeatures operators in PyTorch.

# TODO extend this class to support higher orders

_abc_impl = <_abc_data object>
forward(x)[source], device, extra_config)[source]

Converter for sklearn.preprocessing.PolynomialFeatures

Currently this supports only degree 2, and does not support interaction_only


operator: An operator wrapping a sklearn.preprocessing.PolynomialFeatures model device: String defining the type of device the converted operator should be run on extra_config: Extra configuration used to select the best conversion strategy


A PyTorch model