Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Loading META Prophet model gives a tz, datetime error #2581

Open
Emile-Reyn opened this issue May 8, 2024 · 1 comment
Open

Loading META Prophet model gives a tz, datetime error #2581

Emile-Reyn opened this issue May 8, 2024 · 1 comment

Comments

@Emile-Reyn
Copy link

Emile-Reyn commented May 8, 2024

Good day,

Thank you for the help in advance. I have saved a meta model using

from prophet.serialize import model_to_json, model_from_json

with open('serialized_model.json', 'w') as fout:
    fout.write(model_to_json(m))  # Save model

The model's inputs and outputs are irrelevant.

Then, when trying to load the model using:


with open('serialized_model.json', 'r') as fin:
    m = model_from_json(fin.read())  # Load model

the following error pops up:

ValueError: cannot supply both a tz and a timezone-naive dtype (i.e. datetime64[ns]): Error while type casting for column 'ds'

Any thoughts?

@Emile-Reyn
Copy link
Author

Here is the full error stack

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant