SDV icon indicating copy to clipboard operation
SDV copied to clipboard

PAR Model cannot fit columns with dtype `period`

Open andrewcz opened this issue 2 years ago • 2 comments

Hi All,

I have having a bit trouble with the time series generation module.

image

image

image

It looks to be an issue with the index but I'm not sure how to resolve it. Best, Andrew

andrewcz avatar Jul 13 '21 00:07 andrewcz

Hi @andrewcz, there is an ongoing bug where the PAR model is crashing if the sequence index is anything other than a datetime. You can follow along in #808 for updates as we get to a resolution.

Due to this, I believe the error is caused by the following line:

DF.index = DF.index.to_period('M')

This is changing the column's data type from datetime to period.

Workaround: Is it possible for you to keep it as datetime (ie remove this line)? Verify that you have the supported data types by running the following line:

DF.dtypes

This will provide a list of column names and their dtypes. Make sure you see datetime and not period.

npatki avatar Jun 30 '22 18:06 npatki

Quick update: Seems like this error is occurring during the fit, not the sample. There is a similar issue on this in #465, but the error is different. Let's keep this issue open as a separate bug, as the root cause seems different.

npatki avatar Jul 08 '22 19:07 npatki