@@ -45,15 +45,10 @@ stages:
4545 ort.version : ' 1.18.1'
4646
4747 steps :
48- - task : DownloadGitHubRelease@0
49- inputs :
50- connection : ' microsoft'
51- userRepository : ' microsoft/onnxruntime'
52- defaultVersionType : ' specificTag'
53- version : ' v$(ort.version)'
54- itemPattern : ' *-linux-x64-$(ort.version)*'
55- downloadPath : ' $(Build.SourcesDirectory)'
56- displayName : Download the ONNXRuntime prebuilt package.
48+ - template : templates/download-file.yml
49+ parameters :
50+ url : " https://github.com/microsoft/onnxruntime/releases/download/v$(ort.version)/onnxruntime-linux-x64-$(ort.version).tgz"
51+ outputFilePath : " $(Build.SourcesDirectory)/onnxruntime-linux-x64-$(ort.version).tgz"
5752
5853 - task : ExtractFiles@1
5954 inputs :
@@ -234,15 +229,10 @@ stages:
234229 - script : brew install libomp
235230 displayName : ' Install omp'
236231
237- - task : DownloadGitHubRelease@0
238- inputs :
239- connection : ' microsoft'
240- userRepository : ' microsoft/onnxruntime'
241- defaultVersionType : ' specificTag'
242- version : ' v$(ort.version)'
243- itemPattern : ' $(ort.dirname)*'
244- downloadPath : ' $(Build.SourcesDirectory)'
245- displayName : Download the ONNXRuntime prebuilt package.
232+ - template : templates/download-file.yml
233+ parameters :
234+ url : " https://github.com/microsoft/onnxruntime/releases/download/v$(ort.version)/onnxruntime-osx-x86_64-$(ort.version).tgz"
235+ outputFilePath : " $(Build.SourcesDirectory)/onnxruntime-osx-x86_64-$(ort.version).tgz"
246236
247237 - task : ExtractFiles@1
248238 inputs :
@@ -353,15 +343,18 @@ stages:
353343 ort.version : ' 1.15.1'
354344
355345 steps :
356- - task : DownloadGitHubRelease @0
346+ - task : UsePythonVersion @0
357347 inputs :
358- connection : ' microsoft'
359- userRepository : ' microsoft/onnxruntime'
360- defaultVersionType : ' specificTag'
361- version : ' v$(ort.version)'
362- itemPattern : ' *-win-x64-$(ort.version)*'
363- downloadPath : ' $(Build.SourcesDirectory)'
364- displayName : Download the ONNXRuntime prebuilt package.
348+ versionSpec : ' 3.12'
349+ disableDownloadFromRegistry : true
350+ addToPath : true
351+ architecture : ' x64'
352+ displayName : Use ADO python task
353+
354+ - template : templates/download-file.yml
355+ parameters :
356+ url : " https://github.com/microsoft/onnxruntime/releases/download/v$(ort.version)/onnxruntime-win-x64-$(ort.version).zip"
357+ outputFilePath : " $(Build.SourcesDirectory)/onnxruntime-win-x64-$(ort.version).zip"
365358
366359 - task : ExtractFiles@1
367360 inputs :
@@ -506,6 +499,14 @@ stages:
506499 ORT_VERSION : ' 1.17.1'
507500 timeoutInMinutes : 120
508501 steps :
502+ - task : UsePythonVersion@0
503+ inputs :
504+ versionSpec : ' 3.12'
505+ disableDownloadFromRegistry : true
506+ addToPath : true
507+ architecture : ' x64'
508+ displayName : Use ADO python task
509+
509510 - template : templates/set_winenv.yml
510511 parameters :
511512 EnvSetupScript : ' set_env_cuda.bat'
@@ -517,15 +518,10 @@ stages:
517518 where nvcc
518519 displayName: check cuda version
519520
520- - task : DownloadGitHubRelease@0
521- inputs :
522- connection : ' microsoft'
523- userRepository : ' microsoft/onnxruntime'
524- defaultVersionType : ' specificTag'
525- version : ' v$(ORT_VERSION)'
526- itemPattern : ' *-win-x64-gpu-$(ORT_VERSION)*'
527- downloadPath : ' $(Build.SourcesDirectory)'
528- displayName : Download the ONNXRuntime prebuilt package.
521+ - template : templates/download-file.yml
522+ parameters :
523+ url : " https://github.com/microsoft/onnxruntime/releases/download/v$(ORT_VERSION)/onnxruntime-win-x64-gpu-$(ORT_VERSION).zip"
524+ outputFilePath : " $(Build.SourcesDirectory)/onnxruntime-win-x64-gpu-$(ORT_VERSION).zip"
529525
530526 - task : ExtractFiles@1
531527 inputs :
@@ -548,14 +544,6 @@ stages:
548544 ctest -C RelWithDebInfo --output-on-failure
549545 displayName: Run C++ native tests
550546
551- - task : UsePythonVersion@0
552- inputs :
553- versionSpec : ' 3.12'
554- disableDownloadFromRegistry : true
555- addToPath : true
556- architecture : ' x64'
557- displayName : Use ADO python task
558-
559547 - script : |
560548 set CUDA_PATH=$(Agent.TempDirectory)\v11.8
561549 python -m pip install --upgrade setuptools pip
@@ -604,15 +592,10 @@ stages:
604592 versionSpec : ' 3.12'
605593 addToPath : true
606594
607- - task : DownloadGitHubRelease@0
608- inputs :
609- connection : ' microsoft'
610- userRepository : ' microsoft/onnxruntime'
611- defaultVersionType : ' specificTag'
612- version : ' v$(ORT_VERSION)'
613- itemPattern : ' *-linux-x64-gpu-$(ORT_VERSION)*'
614- downloadPath : ' $(Build.SourcesDirectory)'
615- displayName : Download the ONNXRuntime prebuilt package.
595+ - template : templates/download-file.yml
596+ parameters :
597+ url : " https://github.com/microsoft/onnxruntime/releases/download/v$(ORT_VERSION)/onnxruntime-linux-x64-gpu-$(ORT_VERSION).tgz"
598+ outputFilePath : " $(Build.SourcesDirectory)/onnxruntime-linux-x64-gpu-$(ORT_VERSION).tgz"
616599
617600 - task : ExtractFiles@1
618601 inputs :
0 commit comments