mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
fix python version error (#71021)
Summary: if python3 is the one running the tests but there exists a "python" installed as python2.7 the test will fail with a syntax issue Pull Request resolved: https://github.com/pytorch/pytorch/pull/71021 Reviewed By: zou3519 Differential Revision: D33667073 Pulled By: albanD fbshipit-source-id: 8e489b491439be1740fc32ca5c7cdceb2145771e (cherry picked from commit 5adfece429fcfe6ace778dd67f060d04a3d54699)
This commit is contained in:
committed by
PyTorch MergeBot
parent
e2dc2aca93
commit
76fd3cfd38
@ -17,7 +17,8 @@ class TestFunctionalAutogradBenchmark(TestCase):
|
||||
# is not allowed to open it again. As this is a simple smoke test, we choose for now
|
||||
# not to run this on windows and keep the code here simple.
|
||||
with tempfile.NamedTemporaryFile() as out_file:
|
||||
cmd = ['python', '../benchmarks/functional_autograd_benchmark/functional_autograd_benchmark.py']
|
||||
cmd = ['python3',
|
||||
'../benchmarks/functional_autograd_benchmark/functional_autograd_benchmark.py']
|
||||
# Only run the warmup
|
||||
cmd += ['--num-iters', '0']
|
||||
# Only run the vjp task (fastest one)
|
||||
|
Reference in New Issue
Block a user