b7eb836b40893bc25e782658cfec6f7bd6c4c451,seglearn/segment.py,Segment,transform,#Segment#Any#,26
Before Change
def transform(self, X):
check_is_fitted(self, "step")
if type(X) is np.recarray:
X_new = self._transform_recarray(X)
else:
X_new = self._transform(X)
After Change
def transform(self, X):
check_is_fitted(self, "step")
Xt = np.array([sliding_tensor(X["ts"][i], self.width, self.step) for i in range(len(X))])
h_names = [h for h in X.dtype.names if h != "ts"]
Xh = [X[h] for h in h_names]
X_new = np.core.records.fromarrays([Xt] + Xh, names=["ts"] + h_names)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 9
Instances
Project Name: dmbee/seglearn
Commit Name: b7eb836b40893bc25e782658cfec6f7bd6c4c451
Time: 2018-03-06
Author: david.mo.burns@gmail.com
File Name: seglearn/segment.py
Class Name: Segment
Method Name: transform
Project Name: dmbee/seglearn
Commit Name: 56fb5f5ecfdaafc57b67db632004c6272f068e2e
Time: 2018-03-08
Author: david.mo.burns@gmail.com
File Name: seglearn/util.py
Class Name:
Method Name: check_ts_data
Project Name: reinforceio/tensorforce
Commit Name: af2bcf3e70928d379feaf46cdae1aeba71d0e424
Time: 2017-11-26
Author: aok25@cl.cam.ac.uk
File Name: tensorforce/contrib/openai_gym.py
Class Name: OpenAIGym
Method Name: execute