Can you please assist me on this error? I am tryin...
# neural-forecast
v
Can you please assist me on this error? I am trying to replicate Automatic Hyperparameter Tuning using my dataset.
f
Seems like you have different data types. Have you checked the types in your input data?
v
ds = object
how do i convert the data type to be readable?
f
I don't know your whole code and data but in Pandas you can do
df['ds'] = pd.to_datetime(df['ds'])
v
still has an error. i am attaching my data....
f
In that case you shouldn't actually have to convert anything. Not sure why you are not getting the right data type. Are you sure you had a fresh start in your notebook and didn't load any other libraries?
This is what I got right now:
If you do that you should get a date type to begin with. The data is already properly formatted.
v
I made a fresh start and same problem...
f
Make sure you have the right package versions in your env. If a fresh start with only those lines of code (and nothing else) is still giving you an object type instead of datetime type, then your packages are not working properly. Perhaps you have installed a package in your env recently that has updated some shared dependencies with the neuralforecast and now things are not working. A freshly installed package with that code should work. I just tested on Mac with Python 3.10.6 and neuralforecast==1.4.0
c
Hi @virgilio espina. If the
<http://pd.to|pd.to>_datetime
fails then there is an issue with the data. Maybe inconsistent dates formats. Can you try specifying the format (eg. YYYY-dd-mm)? You also need to specify the correct frequency when you instantiate the
NeuralForecast
class.
Month end in this case