spotforecast2 0.1.1__tar.gz → 0.2.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/PKG-INFO +1 -1
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/pyproject.toml +1 -1
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/processing/n2n_predict.py +8 -1
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/processing/n2n_predict_with_covariates.py +5 -1
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/README.md +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/data/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/data/data.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/data/fetch_data.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/exceptions.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/base.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/metrics.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/recursive/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/recursive/_forecaster_equivalent_date.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/recursive/_forecaster_recursive.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/recursive/_warnings.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/utils.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/bayesian_search.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/grid_search.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/random_search.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/split_base.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/split_one_step.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/split_ts_cv.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/utils_common.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/utils_metrics.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/validation.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/_binner.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/_common.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/_differentiator.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/_rolling.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/curate_data.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/imputation.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/outlier.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/split.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/processing/agg_predict.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/py.typed +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/utils/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/utils/convert_to_utc.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/utils/data_transform.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/utils/forecaster_config.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/utils/generate_holiday.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/utils/validation.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/weather/__init__.py +0 -0
- {spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/weather/weather_client.py +0 -0
|
@@ -210,6 +210,7 @@ def _model_directory_exists(model_dir: Union[str, Path]) -> bool:
|
|
|
210
210
|
|
|
211
211
|
|
|
212
212
|
def n2n_predict(
|
|
213
|
+
data: Optional[pd.DataFrame] = None,
|
|
213
214
|
columns: Optional[List[str]] = None,
|
|
214
215
|
forecast_horizon: int = 24,
|
|
215
216
|
contamination: float = 0.01,
|
|
@@ -233,6 +234,8 @@ def n2n_predict(
|
|
|
233
234
|
Existing models are reused for prediction unless force_train=True.
|
|
234
235
|
|
|
235
236
|
Args:
|
|
237
|
+
data: Optional DataFrame with target time series data. If None, fetches data automatically.
|
|
238
|
+
Default: None.
|
|
236
239
|
columns: List of target columns to forecast. If None, uses all available columns.
|
|
237
240
|
Default: None.
|
|
238
241
|
forecast_horizon: Number of time steps to forecast ahead. Default: 24.
|
|
@@ -314,7 +317,11 @@ def n2n_predict(
|
|
|
314
317
|
print("Fetching data...")
|
|
315
318
|
|
|
316
319
|
# Fetch data
|
|
317
|
-
data
|
|
320
|
+
if data is not None:
|
|
321
|
+
if TARGET is not None:
|
|
322
|
+
data = data[TARGET]
|
|
323
|
+
else:
|
|
324
|
+
data = fetch_data(columns=TARGET)
|
|
318
325
|
|
|
319
326
|
START, END, COV_START, COV_END = get_start_end(
|
|
320
327
|
data=data,
|
|
@@ -727,6 +727,7 @@ def _model_directory_exists(model_dir: Union[str, Path]) -> bool:
|
|
|
727
727
|
|
|
728
728
|
|
|
729
729
|
def n2n_predict_with_covariates(
|
|
730
|
+
data: Optional[pd.DataFrame] = None,
|
|
730
731
|
forecast_horizon: int = 24,
|
|
731
732
|
contamination: float = 0.01,
|
|
732
733
|
window_size: int = 72,
|
|
@@ -763,6 +764,8 @@ def n2n_predict_with_covariates(
|
|
|
763
764
|
Existing models are reused for prediction unless force_train=True.
|
|
764
765
|
|
|
765
766
|
Args:
|
|
767
|
+
data: Optional DataFrame with target time series data. If None, fetches data automatically.
|
|
768
|
+
Default: None.
|
|
766
769
|
forecast_horizon: Number of time steps to forecast ahead. Default: 24.
|
|
767
770
|
contamination: Contamination parameter for outlier detection. Default: 0.01.
|
|
768
771
|
window_size: Rolling window size for gap detection. Default: 72.
|
|
@@ -865,7 +868,8 @@ def n2n_predict_with_covariates(
|
|
|
865
868
|
if verbose:
|
|
866
869
|
print("\n[1/9] Loading and preparing target data...")
|
|
867
870
|
|
|
868
|
-
data
|
|
871
|
+
if data is None:
|
|
872
|
+
data = fetch_data()
|
|
869
873
|
target_columns = data.columns.tolist()
|
|
870
874
|
|
|
871
875
|
if verbose:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/recursive/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/forecaster/recursive/_warnings.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/bayesian_search.py
RENAMED
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/grid_search.py
RENAMED
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/random_search.py
RENAMED
|
File without changes
|
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/split_one_step.py
RENAMED
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/split_ts_cv.py
RENAMED
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/utils_common.py
RENAMED
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/model_selection/utils_metrics.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{spotforecast2-0.1.1 → spotforecast2-0.2.0}/src/spotforecast2/preprocessing/_differentiator.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|