You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Few models (e.g. TFT) takes required positional arguments (e.g. input_size). If user passes a config to AutoTFT that does not have this key, training fails with following as the root cause:
importpandasfromneuralforecastimportNeuralForecastfromneuralforecast.autoimportAutoTFTfromrayimporttunefromsktime.datasetsimportload_longleyfromsktime.splitimporttemporal_train_test_splity, X=load_longley()
y_train, y_test, X_train, X_test=temporal_train_test_split(y, X, test_size=4)
algorithm=AutoTFT(
4,
config={"max_steps": tune.choice([5, 10, 15]), "random_seed": tune.choice([0])},
backend="ray",
)
model=NeuralForecast([algorithm], "A-DEC")
train_data= {
"unique_id": 1,
"ds": y_train.index.to_timestamp(freq="A-DEC").to_numpy(),
"y": y_train.to_numpy(),
}
forcolumninX.columns:
train_data[column] =X_train[column].to_numpy()
train_dataset=pandas.DataFrame(data=train_data)
model.fit(df=train_dataset)
# RuntimeError: No best trial found for the given metric: loss. This means that no trial has reported this metric, or all values reported for this metric are NaN. To not ignore NaN values, you can set the `filter_nan_and_inf` arg to False.
It will be helpful to document mandatory keys to be passed in config in the documentation of Auto* models.
If it is possible to allow users to pass few arugments to the underlying model directly without tuning, for __init__ (where tuning is not necessary) or to fit or predict (for example configurations for PyTorch Lighning's trainer), it will be very useful.
Link
No response
The text was updated successfully, but these errors were encountered:
Description
Few models (e.g.
TFT
) takes required positional arguments (e.g.input_size
). If user passes aconfig
toAutoTFT
that does not have this key, training fails with following as the root cause:Here's a reproducible example:
It will be helpful to document mandatory keys to be passed in
config
in the documentation ofAuto*
models.If it is possible to allow users to pass few arugments to the underlying model directly without tuning, for
__init__
(where tuning is not necessary) or tofit
orpredict
(for example configurations for PyTorch Lighning's trainer), it will be very useful.Link
No response
The text was updated successfully, but these errors were encountered: