INNER CODE UNIT · Python
predict
aimclub/FEDOT · fedot/api/main.py:267
def predict(self,
features: FeaturesType,
in_sample: bool = True,
validation_blocks: Optional[int] = None,
path_to_save: Optional[PathType] = None) -> np.ndarray:
"""Predicts new target using already fitted model.
For time-series performs forecast with depth ``forecast_length`` if ``in_sample=False``.
If ``in_sample=True`` performs in-sample forecast using features as sample.
Args:
features: an array with features of test data.
in_sample: used while time-series prediction. If ``in_sample=True`` performs in-sample forecast using
features with number if iterations specified in ``validation_blocks``.
validation_blocks: number of validation blocks for in-sample forecast.
path_to_save: if specified, path to save prediction to.
Returns: