Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
numpy==1.24.3
numpy
scipy
scikit-learn
matplotlib
Expand Down
5 changes: 2 additions & 3 deletions ssmlearnpy/reduced_dynamics/shift_or_differentiate.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import logging
import numpy as np
#from ssmlearnpy.utils.finite_time_differences import finite_time_differences
from findiff import FinDiff

#logger = logging.getlogger("shift_or_differentiate")
Expand All @@ -20,8 +19,8 @@ def shift_or_differentiate(x, t, type, accuracy = 4):
#logger.info("Differentiate data for continuous time dynamical system")
X, y = [], []
for i_traj in range(len(x)):
# create finite difference object
fd = FinDiff(1, t[i_traj][1] - t[i_traj][0], 1, acc = accuracy) # first order differential with given accuracy
# create finite difference object
fd = FinDiff(1, float(t[i_traj][1] - t[i_traj][0]), 1, acc=accuracy) # first order differential with given accuracy
dx_dt_traj = fd(np.array(x[i_traj])) # findiff differentiates along axis 0.
X.append(x[i_traj])
y.append( dx_dt_traj)
Expand Down
1 change: 0 additions & 1 deletion ssmlearnpy/utils/ridge.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@


import numpy as np
from numpy.lib.arraysetops import isin
from sklearn.preprocessing import StandardScaler
from sklearn.preprocessing import PolynomialFeatures, FunctionTransformer
from sklearn.gaussian_process.kernels import Kernel
Expand Down