(self, feat)
| 40 | self.alpha = 0.9 |
| 41 | |
| 42 | def update_features(self, feat): |
| 43 | feat /= np.linalg.norm(feat) |
| 44 | self.curr_feat = feat |
| 45 | if self.smooth_feat is None: |
| 46 | self.smooth_feat = feat |
| 47 | else: |
| 48 | self.smooth_feat = self.alpha * self.smooth_feat + (1 - self.alpha) * feat |
| 49 | self.features.append(feat) |
| 50 | self.smooth_feat /= np.linalg.norm(self.smooth_feat) |
| 51 | |
| 52 | def predict(self): |
| 53 | mean_state = self.mean.copy() |
no outgoing calls
no test coverage detected