Search code examples
deep-learningneural-networkforecastfacebook-prophet

How to set the optimizer in neural prophet to SDG instead of AdamW?


Why I am I getting this error?

My guess is that I am using parameters that don't work together. This is my code and that's the error I am getting:

The dataframe is 'L12M' and it has only two columns, ds and y. The data resolution 5 mins and it has about 12 months' worth of data:

enter image description here

m = NeuralProphet(n_forecasts=(2*24*12),
n_lags=(2*7*24*12),
yearly_seasonality="auto",
weekly_seasonality="auto",  
daily_seasonality="auto", 
growth="off", seasonality_reg= 0.5, optimizer = 'SDG',
learning_rate = 0.1, n_changepoints="auto", changepoints_range = "auto" )
m.add_country_holidays("US", mode="additive") # lower_window=-1, upper_window=1
metrics = m.fit(L12M, freq="5min")

enter image description here


Solution

  • Thanks to @desertnaut. He noticed that there is a typo in the Neural Prophet documentation. So it should be "SGD" not "SDG." Cheers!