use builtin int and float (#1850)

This commit is contained in:
Cuong Duong 2021-03-21 04:50:14 +11:00 committed by GitHub
parent 8882c6a3e3
commit 8ffa0e02a6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -403,7 +403,7 @@ class Prophet(object):
cp_indexes = (
np.linspace(0, hist_size - 1, self.n_changepoints + 1)
.round()
.astype(np.int)
.astype(int)
)
self.changepoints = (
self.history.iloc[cp_indexes]['ds'].tail(-1)
@ -436,7 +436,7 @@ class Prophet(object):
t = np.array(
(dates - datetime(1970, 1, 1))
.dt.total_seconds()
.astype(np.float)
.astype(float)
) / (3600 * 24.)
return np.column_stack([
fun((2.0 * (i + 1) * np.pi * t / period))