mirror of
https://github.com/saymrwulf/prophet.git
synced 2026-11-16 08:38:30 +00:00
Avoid pandas deprecation warning
This commit is contained in:
parent
30e68fd467
commit
69bd5a2aac
1 changed files with 2 additions and 2 deletions
|
|
@ -9,7 +9,7 @@ from __future__ import absolute_import, division, print_function
|
||||||
import logging
|
import logging
|
||||||
from collections import OrderedDict, defaultdict
|
from collections import OrderedDict, defaultdict
|
||||||
from copy import deepcopy
|
from copy import deepcopy
|
||||||
from datetime import timedelta
|
from datetime import timedelta, datetime
|
||||||
|
|
||||||
import numpy as np
|
import numpy as np
|
||||||
import pandas as pd
|
import pandas as pd
|
||||||
|
|
@ -417,7 +417,7 @@ class Prophet(object):
|
||||||
"""
|
"""
|
||||||
# convert to days since epoch
|
# convert to days since epoch
|
||||||
t = np.array(
|
t = np.array(
|
||||||
(dates - pd.datetime(1970, 1, 1))
|
(dates - datetime(1970, 1, 1))
|
||||||
.dt.total_seconds()
|
.dt.total_seconds()
|
||||||
.astype(np.float)
|
.astype(np.float)
|
||||||
) / (3600 * 24.)
|
) / (3600 * 24.)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue