@@ -34,72 +34,40 @@ parameters:
34
34
- 11.8
35
35
- 12.2
36
36
37
- stages :
38
- - stage : Python_Packaging
39
- dependsOn : []
40
- variables :
41
- - name : docker_base_image
42
- ${{ if eq(parameters.cuda_version, '11.8') }} :
43
- value : nvidia/cuda:11.8.0-cudnn8-devel-ubi8
44
- ${{ if eq(parameters.cuda_version, '12.2') }} :
45
- value : nvidia/cuda:12.2.2-cudnn8-devel-ubi8
46
- - name : linux_trt_version
47
- ${{ if eq(parameters.cuda_version, '11.8') }} :
48
- value : 8.6.1.6-1.cuda11.8
49
- ${{ if eq(parameters.cuda_version, '12.2') }} :
50
- value : 8.6.1.6-1.cuda12.0
51
- - name : win_trt_home
52
- ${{ if eq(parameters.cuda_version, '11.8') }} :
53
- value : $(Agent.TempDirectory)\TensorRT-8.6.1.6.Windows10.x86_64.cuda-11.8
54
- ${{ if eq(parameters.cuda_version, '12.2') }} :
55
- value : $(Agent.TempDirectory)\TensorRT-8.6.1.6.Windows10.x86_64.cuda-12.0
56
- - name : win_cuda_home
57
- ${{ if eq(parameters.cuda_version, '11.8') }} :
58
- value : $(Agent.TempDirectory)\v11.8
59
- ${{ if eq(parameters.cuda_version, '12.2') }} :
60
- value : $(Agent.TempDirectory)\v12.2
61
- jobs :
62
- - ${{ if eq(parameters.enable_windows_gpu, true) }} :
63
- - template : ../templates/py-win-gpu.yml
64
- parameters :
65
- MACHINE_POOL : ' onnxruntime-Win2022-GPU-T4'
66
- PYTHON_VERSION : ' 3.8'
67
- EP_BUILD_FLAGS : --use_tensorrt --tensorrt_home=${{ variables.win_trt_home }} --cuda_home=${{ variables.win_cuda_home }} --cmake_extra_defines "CMAKE_CUDA_ARCHITECTURES=52;60;61;70;75;80"
68
- EP_NAME : gpu
69
- CudaVersion : ${{ parameters.cuda_version }}
70
-
71
- - template : ../templates/py-win-gpu.yml
72
- parameters :
73
- MACHINE_POOL : ' onnxruntime-Win2022-GPU-T4'
74
- PYTHON_VERSION : ' 3.9'
75
- EP_BUILD_FLAGS : --use_tensorrt --tensorrt_home=${{ variables.win_trt_home }} --cuda_home=${{ variables.win_cuda_home }} --cmake_extra_defines "CMAKE_CUDA_ARCHITECTURES=52;60;61;70;75;80"
76
- EP_NAME : gpu
77
- CudaVersion : ${{ parameters.cuda_version }}
37
+ - name : SpecificArtifact
38
+ displayName : Use Specific Artifact
39
+ type : boolean
40
+ default : false
78
41
79
- - template : ../templates/py-win-gpu.yml
80
- parameters :
81
- MACHINE_POOL : ' onnxruntime-Win2022-GPU-T4'
82
- PYTHON_VERSION : ' 3.10'
83
- EP_BUILD_FLAGS : --use_tensorrt --tensorrt_home=${{ variables.win_trt_home }} --cuda_home=${{ variables.win_cuda_home }} --cmake_extra_defines "CMAKE_CUDA_ARCHITECTURES=52;60;61;70;75;80"
84
- EP_NAME : gpu
85
- CudaVersion : ${{ parameters.cuda_version }}
42
+ - name : BuildId
43
+ displayName : Specific Artifact's BuildId
44
+ type : string
45
+ default : ' 0'
86
46
87
- - template : ../templates/py-win-gpu.yml
88
- parameters :
89
- MACHINE_POOL : ' onnxruntime-Win2022-GPU-T4'
90
- PYTHON_VERSION : ' 3.11'
91
- EP_BUILD_FLAGS : --use_tensorrt --tensorrt_home=${{ variables.win_trt_home }} --cuda_home=${{ variables.win_cuda_home }} --cmake_extra_defines "CMAKE_CUDA_ARCHITECTURES=52;60;61;70;75;80"
92
- EP_NAME : gpu
93
- CudaVersion : ${{ parameters.cuda_version }}
47
+ - name : PythonVersions
48
+ type : object
49
+ displayName : ' Python versions to build'
50
+ default :
51
+ - ' 3.8'
52
+ - ' 3.9'
53
+ - ' 3.10'
54
+ - ' 3.11'
55
+ - ' 3.12'
94
56
57
+ stages :
58
+ - ${{ if eq(parameters.enable_windows_gpu, true) }} :
59
+ - ${{ each python_version in parameters.PythonVersions }} :
95
60
- template : ../templates/py-win-gpu.yml
96
61
parameters :
97
- MACHINE_POOL : ' onnxruntime-Win2022-GPU-T4'
98
- PYTHON_VERSION : ' 3.12'
99
- EP_BUILD_FLAGS : --use_tensorrt --tensorrt_home=${{ variables.win_trt_home }} --cuda_home=${{ variables.win_cuda_home }} --cmake_extra_defines "CMAKE_CUDA_ARCHITECTURES=52;60;61;70;75;80"
62
+ PYTHON_VERSION : ${{ python_version }}
100
63
EP_NAME : gpu
101
64
CudaVersion : ${{ parameters.cuda_version }}
102
-
65
+ SpecificArtifact : ${{ parameters.SpecificArtifact }}
66
+ BuildId : ${{ parameters.BuildId }}
67
+ ${{ if eq(parameters.cuda_version, '11.8') }} :
68
+ EP_BUILD_FLAGS : --use_tensorrt --tensorrt_home=$(Agent.TempDirectory)\TensorRT-8.6.1.6.Windows10.x86_64.cuda-11.8 --cuda_home=$(Agent.TempDirectory)\v11.8 --cmake_extra_defines "CMAKE_CUDA_ARCHITECTURES=52;60;61;70;75;80"
69
+ ${{ if eq(parameters.cuda_version, '12.2') }} :
70
+ EP_BUILD_FLAGS : --use_tensorrt --tensorrt_home=$(Agent.TempDirectory)\TensorRT-8.6.1.6.Windows10.x86_64.cuda-12.0 --cuda_home=$(Agent.TempDirectory)\v12.2 --cmake_extra_defines "CMAKE_CUDA_ARCHITECTURES=52;60;61;70;75;80"
103
71
104
72
- ${{ if eq(parameters.enable_linux_gpu, true) }} :
105
73
- template : ../templates/py-linux-gpu.yml
@@ -108,6 +76,10 @@ stages:
108
76
machine_pool : ' onnxruntime-Ubuntu2204-AMD-CPU'
109
77
extra_build_arg : ${{ parameters.build_py_parameters }}
110
78
cmake_build_type : ${{ parameters.cmake_build_type }}
111
- docker_base_image : ${{ variables.docker_base_image }}
112
- trt_version : ${{ variables.linux_trt_version }}
113
79
cuda_version : ${{ parameters.cuda_version }}
80
+ ${{ if eq(parameters.cuda_version, '11.8') }} :
81
+ docker_base_image : nvidia/cuda:11.8.0-cudnn8-devel-ubi8
82
+ trt_version : 8.6.1.6-1.cuda11.8
83
+ ${{ if eq(parameters.cuda_version, '12.2') }} :
84
+ docker_base_image : nvidia/cuda:12.2.2-cudnn8-devel-ubi8
85
+ trt_version : 8.6.1.6-1.cuda12.0
0 commit comments