shunping commented on code in PR #34709:
URL: https://github.com/apache/beam/pull/34709#discussion_r2054781479


##########
sdks/python/apache_beam/ml/anomaly/transforms.py:
##########
@@ -454,6 +454,13 @@ def _restore_and_convert(
         ])
     return orig_key, (temp_key, result)
 
+  def _select_features(self, elem: Tuple[Any,
+                                         beam.Row]) -> Tuple[Any, beam.Row]:
+    assert self._offline_detector._features is not None
+    k, v = elem
+    row_dict = v._asdict()
+    return k, beam.Row(**{k: row_dict[k] for k in 
self._offline_detector._features})  # pylint: disable=line-too-long

Review Comment:
   Somehow the formatter does not split the original line. Let me see if this 
can be fixed.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to