MultiSegmentModelMixin

class MultiSegmentModelMixin(base_model: Any)[source]

Bases: etna.models.mixins.ModelForecastingMixin

Mixin for holding methods for multi-segment prediction.

It currently isn’t working with prediction intervals and context.

Init MultiSegmentModel.

Parameters

base_model (Any) – Internal model which will be used to forecast segments, expected to have fit/predict interface

Inherited-members

Methods

fit(ts)

Fit model.

get_model()

Get internal model that is used inside etna class.

fit(ts: etna.datasets.tsdataset.TSDataset) etna.models.mixins.MultiSegmentModelMixin[source]

Fit model.

Parameters

ts (etna.datasets.tsdataset.TSDataset) – Dataset with features

Returns

Model after fit

Return type

etna.models.mixins.MultiSegmentModelMixin

get_model() Any[source]

Get internal model that is used inside etna class.

Internal model is a model that is used inside etna to forecast segments, e.g. catboost.CatBoostRegressor or sklearn.linear_model.Ridge.

Returns

Internal model

Return type

Any