agvdndor commented on code in PR #23094:
URL: https://github.com/apache/beam/pull/23094#discussion_r970810420


##########
sdks/python/apache_beam/examples/ml-orchestration/kfp/components/train/src/train.py:
##########
@@ -0,0 +1,62 @@
+"""Dummy training function that loads a pretrained model from the torch hub 
and saves it."""
+
+import argparse
+from pathlib import Path
+import time
+
+import torch
+
+
+def parse_args():
+  """Parse ingestion arguments."""
+  parser = argparse.ArgumentParser()
+  parser.add_argument(
+    "--preprocessed-dataset-path", type=str,
+    help="Path to the preprocessed dataset.")
+  parser.add_argument(
+    "--trained-model-path", type=str,
+    help="Output path to the trained model.")
+  parser.add_argument(
+    "--base-artifact-path", type=str,
+    help="Base path to store pipeline artifacts.")
+  return parser.parse_args()
+
+
+def train_model(

Review Comment:
   We could, but the workflow's focus is really on the preprocessing step. So 
I'm not sure if including this stub implementation for the train step will be 
of value to readers or if it will just clutter the docs. I do explicitly link 
to the full example in the docs so they know where to find it. What do you 
think?



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to