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

Negative dimensions are not allowed #191

Closed
michael-lambe opened this issue Oct 10, 2019 · 2 comments · Fixed by #193
Closed

Negative dimensions are not allowed #191

michael-lambe opened this issue Oct 10, 2019 · 2 comments · Fixed by #193
Assignees

Comments

@michael-lambe
Copy link

michael-lambe commented Oct 10, 2019

I am feeding the following dataset into auto_arima

Month,0
2016-01-01,129.97783044109778
2016-02-01,306.55148688938147
2016-03-01,143.46609586423057
2016-04-01,385.0286675330632
2016-05-01,80.92959253879673
2016-06-01,1058.2157327421448
2016-07-01,1247.051448666004
2016-08-01,1833.1778915985017
2016-09-01,3338.9587951991443
2016-10-01,2855.8336518614783
2016-11-01,3309.5298524577643
2016-12-01,1351.2789542083938
2017-01-01,1920.2101811761734
2017-02-01,2168.912102232124
2017-03-01,3910.982302744965
2017-04-01,3190.3251082433057
2017-05-01,1374.2227079742736
2017-06-01,1403.1415360040357
2017-07-01,953.1645718609441
2017-08-01,1413.5523140947494
2017-09-01,2821.320862583547
2017-10-01,2467.3544074992637
2017-11-01,2976.3257808230696
2017-12-01,2918.4881247635467
2018-01-01,1980.0
2018-02-01,3962.0
2018-03-01,6944.0
2018-04-01,2720.0
2018-05-01,3172.0
2018-06-01,3877.0
2018-07-01,5234.0
2018-08-01,4493.0
2018-09-01,9407.0
2018-10-01,9079.0
2018-11-01,10435.0
2018-12-01,4934.0
2019-01-01,4598.0
2019-02-01,7364.0
2019-03-01,10836.0
2019-04-01,8119.0
2019-05-01,10854.0
2019-06-01,5149.256744318752
2019-07-01,6820.377809726632
2019-08-01,9176.990725800295
2019-09-01,15991.129595953533
2019-10-01,14868.559905791291

My code is the following

import pandas as pd
from pathlib import Path
import pmdarima as pm

if __name__ == "__main__":
    y = pd.read_csv(Path(Path(__file__).parents[1], "out/" + "data.csv"), index_col="Month")
    model = pm.auto_arima(
        y,
        error_action="warn",
        seasonal=True,
        m=12,
        alpha=0.05,
        suppress_warnings=True,
        trace=True
    )  # m = 12 -> monthly
    # print(model.aic())
    model.fit(y)
    future_forecast = model.predict(n_periods=12)

I am getting the following error

ValueError: negative dimensions are not allowed
From the numeric.py file from numpy core (line 215)

I am running version pmdarima==1.3.0

I am not sure exactly what is the problem. Can you help?

@tgsmith61591
Copy link
Member

I can replicate this, and it's pretty bizarre. Let me look into what's causing it...

@tgsmith61591 tgsmith61591 self-assigned this Oct 13, 2019
@tgsmith61591 tgsmith61591 mentioned this issue Oct 23, 2019
10 tasks
@tgsmith61591
Copy link
Member

I've got a fix for this in #193

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

Successfully merging a pull request may close this issue.

2 participants