yeandy commented on code in PR #22795: URL: https://github.com/apache/beam/pull/22795#discussion_r953009585
########## sdks/python/apache_beam/examples/snippets/transforms/elementwise/runinference_test.py: ########## @@ -44,10 +44,10 @@ def check_torch_keyed_model_handler(): expected = '''[START torch_keyed_model_handler] -('first_question', PredictionResult(example=tensor([105.]), inference=tensor([523.6982], grad_fn=<UnbindBackward>))) -('second_question', PredictionResult(example=tensor([108.]), inference=tensor([538.5867], grad_fn=<UnbindBackward>))) -('third_question', PredictionResult(example=tensor([1000.]), inference=tensor([4965.4019], grad_fn=<UnbindBackward>))) -('fourth_question', PredictionResult(example=tensor([1013.]), inference=tensor([5029.9180], grad_fn=<UnbindBackward>))) +('first_question', PredictionResult(example=tensor([105.]), inference=tensor([523.6982]))) Review Comment: PyTorch's default sig fig [level](https://pytorch.org/docs/stable/generated/torch.set_printoptions.html) is 4. I think given the weights of the model that we've saved to GCS, this should be fine. Also, here, we're asserting that the std out (strings) match, which may make it harder to do asserts using an error bound that would typically easily be done with floats. -- 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