Skip to content

Commit 67209e6

Browse files
LibTorch 2.7.1 and cuda 12.8 upgrade (#1486)
Upgrade to libtorch 2.7.1 and cuda 12.8, create new proj files for the new fragments and change linux cuda and windows cuda jobs to not run in parallel
1 parent b87317e commit 67209e6

File tree

93 files changed

+454
-249
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

93 files changed

+454
-249
lines changed

DEVGUIDE.md

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,8 @@ For this reason, we do the following
110110
1. The head, referenceable packages that deliver a functioning runtime are any of:
111111

112112
libtorch-cpu
113-
libtorch-cuda-12.1-linux-x64
114-
libtorch-cuda-12.1-win-x64
113+
libtorch-cuda-12.8-linux-x64
114+
libtorch-cuda-12.8-win-x64
115115

116116
2. These packages are combo packages that reference multiple parts. The parts are **not** independently useful.
117117
Some parts deliver a single vast file via `primary` and `fragment` packages. A build task is then used to "stitch" these files back together
@@ -120,7 +120,7 @@ For this reason, we do the following
120120
install/detect/link of PyTorch CUDA on all downstream systems, whcih is extremely problematic
121121
for many practical reasons).
122122

123-
For example, the CUDA package fragments are defined in [libtorch-cuda](src/Redist/libtorch-cuda-12.1/libtorch-cuda-12.1.proj). See more details later in this document.
123+
For example, the CUDA package fragments are defined in [libtorch-cuda](src/Redist/libtorch-cuda-12.8/libtorch-cuda-12.8.proj). See more details later in this document.
124124

125125
3. The `libtorch-*` packages are built in Azure DevOps CI
126126
[using this build pipeline](https://donsyme.visualstudio.com/TorchSharp/_build?definitionId=1&_a=summary) but only in main
@@ -166,12 +166,12 @@ version of PyTorch then quite a lot of careful work needs to be done.
166166

167167
To update the version, update this in [Dependencies.props](build/Dependencies.props):
168168

169-
<LibTorchVersion>2.2.0</LibTorchVersion>
169+
<LibTorchVersion>2.7.1</LibTorchVersion>
170170

171171
The libtorch version number is also referenced in source code, in the file 'src/TorchSharp/Torch.cs':
172172

173173
```C#
174-
const string libtorchPackageVersion = "2.2.0.1";
174+
const string libtorchPackageVersion = "2.7.1.0";
175175
```
176176

177177
3. Run these to test downloads and update SHA hashes for the various LibTorch downloads
@@ -183,9 +183,9 @@ On Windows:
183183
dotnet build src\Redist\libtorch-cpu\libtorch-cpu.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Release /t:Build /p:IncludeLibTorchCpuPackages=true
184184
dotnet build src\Redist\libtorch-cpu\libtorch-cpu.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Debug /t:Build /p:IncludeLibTorchCpuPackages=true
185185

186-
dotnet build src\Redist\libtorch-cuda-12.1\libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:TargetOS=linux /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
187-
dotnet build src\Redist\libtorch-cuda-12.1\libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
188-
dotnet build src\Redist\libtorch-cuda-12.1\libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Debug /t:Build /p:IncludeLibTorchCudaPackages=true
186+
dotnet build src\Redist\libtorch-cuda-12.8\libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:TargetOS=linux /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
187+
dotnet build src\Redist\libtorch-cuda-12.8\libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
188+
dotnet build src\Redist\libtorch-cuda-12.8\libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Debug /t:Build /p:IncludeLibTorchCudaPackages=true
189189

190190
On Linux / Mac:
191191

@@ -194,23 +194,23 @@ On Linux / Mac:
194194
dotnet build src/Redist/libtorch-cpu/libtorch-cpu.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Release /t:Build /p:IncludeLibTorchCpuPackages=true
195195
dotnet build src/Redist/libtorch-cpu/libtorch-cpu.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Debug /t:Build /p:IncludeLibTorchCpuPackages=true
196196

197-
dotnet build src/Redist/libtorch-cuda-12.1/libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:TargetOS=linux /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
198-
dotnet build src/Redist/libtorch-cuda-12.1/libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
199-
dotnet build src/Redist/libtorch-cuda-12.1/libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Debug /t:Build /p:IncludeLibTorchCudaPackages=true
197+
dotnet build src/Redist/libtorch-cuda-12.8/libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:TargetOS=linux /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
198+
dotnet build src/Redist/libtorch-cuda-12.8/libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Release /t:Build /p:IncludeLibTorchCudaPackages=true
199+
dotnet build src/Redist/libtorch-cuda-12.8/libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:TargetOS=windows /p:Configuration=Debug /t:Build /p:IncludeLibTorchCudaPackages=true
200200

201201

202-
Each of these will take a **very very long time** depending on your broadband connection. This can't currently be done in CI.
202+
Each of these can take a **very very long time** depending on your broadband connection. This can't currently be done in CI.
203203

204204
If file names in the distribution have changed, or files have been removed, you will get errors saying that files cannot be found. That's okay and will be taken care of in the next step.
205205

206206
4. At this point you must **very very carefully** update the `<File Include= ...` entries under src\Redist projects for
207-
[libtorch-cpu](src/Redist/libtorch-cpu/libtorch-cpu.proj) and [libtorch-cuda](src/Redist/libtorch-cuda-12.1/libtorch-cuda-12.1.proj).
207+
[libtorch-cpu](src/Redist/libtorch-cpu/libtorch-cpu.proj) and [libtorch-cuda](src/Redist/libtorch-cuda-12.8/libtorch-cuda-12.8.proj).
208208

209209
This is the step in the upgrade process that takes the most effort and time. It requires extreme care.
210210

211211
Check the contents of the unzip of the archive, e.g.
212212

213-
dir bin\obj\x64.Release\libtorch-cpu\libtorch-cxx11-abi-shared-with-deps-2.2.0cpu\libtorch\lib\*.so*
213+
dir bin\obj\x64.Release\libtorch-cpu\libtorch-cxx11-abi-shared-with-deps-2.7.1cpu\libtorch\lib\*.so*
214214

215215
You may also need to precisely refactor the binaries into multiple parts so each package ends up under ~300MB. Before release 2.2.0 of libtorch, this really only affected the CUDA packagages, but it is now also affecting the CPU packages on Linux and OSX. Windows CPU is still small enough to be contained in just one package. The NuGet gallery does not allow packages larger than 250MB, so if files are 300MB, after compression, they are likely to be smaller than 250MB. However, you have to look out: if the compression is poor, then packages may end up larger. Note that it is 250 million
216216
bytes that is the limit, **not** 250*1024*1024. In other words, it is 250 MB, not 250 MiB. Note that Windows Explorer will show file sizes in KiB, not thousands of bytes. Use 'dir' from a CMD window to get the exact size in bytes for each file. For example -- the file `libtorch_cpu.so` shows up as 511,872 KB in Windows Explorer, but 524,156,144 bytes in CMD. The 2.4% difference can be significant. Getting the partitioning right requires precision.
@@ -256,7 +256,7 @@ On Linux / Mac:
256256
5. Add the SHA files:
257257

258258
git add src\Redist\libtorch-cpu\*.sha
259-
git add src\Redist\libtorch-cuda-12.1\*.sha
259+
git add src\Redist\libtorch-cuda-12.8\*.sha
260260

261261
After this you may as well submit to CI just to see what happens, though keep going with the other steps below as well.
262262

@@ -290,10 +290,12 @@ On Linux / Mac:
290290
dotnet test -c Debug
291291
dotnet test -c Release
292292

293+
**Note**: The CI does not run tests for the CUDA packages on Linux or Windows, they have to be executed manually.
294+
293295
10. Try building packages locally. The build (including CI) doesn't build `libtorch-*` packages by default, just the managed package. To
294296
get CI to build new `libtorch-*` packages update this version and set `BuildLibTorchPackages` in [azure-pipelines.yml](azure-pipelines.yml):
295297

296-
<LibTorchPackageVersion>2.0.1.1</LibTorchPackageVersion>
298+
<LibTorchPackageVersion>2.7.1.0</LibTorchPackageVersion>
297299

298300
dotnet pack -c Release -v:n /p:SkipNative=true /p:SkipTests=true /p:IncludeTorchSharpPackage=true /p:IncludeLibTorchCpuPackages=true /p:IncludeLibTorchCudaPackages=true
299301
dotnet pack -c Release -v:n /p:SkipNative=true /p:SkipTests=true /p:TargetOS=linux /p:IncludeTorchSharpPackage=true /p:IncludeLibTorchCpuPackages=true /p:IncludeLibTorchCudaPackages=true

Directory.Build.props

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<SourceDir>$(RepoRoot)src/</SourceDir>
2121
<PkgDir>$(RepoRoot)pkg/</PkgDir>
2222

23-
<LibTorchPackageVersion>2.5.1.0</LibTorchPackageVersion>
23+
<LibTorchPackageVersion>2.7.1.0</LibTorchPackageVersion>
2424
<LibTorchPackageVersion Condition="'$(TargetOS)' == 'mac' and '$(TargetArchitecture)' == 'x64'">2.2.2.0</LibTorchPackageVersion>
2525

2626
<!-- when building on local machines the massive downloads get placed up one directory -->
@@ -86,7 +86,7 @@
8686
<!-- use stable versions for libtorch packages based on LibTorch version number scheme-->
8787
<!-- we manually update these -->
8888
<PropertyGroup Condition="'$(MSBuildProjectName.IndexOf(`libtorch-`))' != '-1'">
89-
<LibTorchPackageVersion>2.5.1.0</LibTorchPackageVersion>
89+
<LibTorchPackageVersion>2.7.1.0</LibTorchPackageVersion>
9090
<LibTorchPackageVersion Condition="'$(TargetOS)' == 'mac' and '$(TargetArchitecture)' == 'x64'">2.2.2.0</LibTorchPackageVersion>
9191
<EnablePackageValidation>false</EnablePackageValidation>
9292
<VersionPrefix>$(LibTorchPackageVersion)</VersionPrefix>

Directory.Build.targets

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
<NativeAssemblyReference Include="cudnn_ops64_9" Variant="cuda\" />
4040
<NativeAssemblyReference Include="cufft64_11" Variant="cuda\" />
4141
<NativeAssemblyReference Include="cufftw64_11" Variant="cuda\" />
42-
<NativeAssemblyReference Include="cupti64_2023.1.1" Variant="cuda\" />
42+
<NativeAssemblyReference Include="cupti64_2025.1.0" Variant="cuda\" />
4343
<NativeAssemblyReference Include="curand64_10" Variant="cuda\" />
4444
<NativeAssemblyReference Include="cusolver64_11" Variant="cuda\" />
4545
<NativeAssemblyReference Include="cusolverMg64_11" Variant="cuda\" />
@@ -49,8 +49,9 @@
4949
<NativeAssemblyReference Include="libiompstubs5md" Variant="cuda\" />
5050
<NativeAssemblyReference Include="nvJitLink_120_0" Variant="cuda\" />
5151
<NativeAssemblyReference Include="nvToolsExt64_1" Variant="cuda\" />
52-
<NativeAssemblyReference Include="nvrtc-builtins64_121" Variant="cuda\" />
52+
<NativeAssemblyReference Include="nvrtc-builtins64_128" Variant="cuda\" />
5353
<NativeAssemblyReference Include="nvrtc64_120_0" Variant="cuda\" />
54+
<NativeAssemblyReference Include="nvrtc64_120_0.alt" Variant="cuda\" />
5455
<NativeAssemblyReference Include="torch" Variant="cuda\" />
5556
<NativeAssemblyReference Include="torch_cpu" Variant="cuda\" />
5657
<NativeAssemblyReference Include="torch_cuda" Variant="cuda\" />

RELEASENOTES.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
## TorchSharp Release Notes
22

33
Releases, starting with 9/2/2021, are listed with the most recent release at the top.
4+
# NuGet Version 0.105.2
5+
6+
This release upgrades the libtorch backend to v2.7.1, using CUDA 12.8.
7+
48
# NuGet Version 0.105.1
59

610
__Bug Fixes__:

TorchSharp.sln

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "TorchSharp", "TorchSharp",
3434
pkg\TorchSharp\TorchSharp.symbols.nupkgproj = pkg\TorchSharp\TorchSharp.symbols.nupkgproj
3535
EndProjectSection
3636
EndProject
37-
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "LibTorchSharp", "bin\obj\x64.Debug\Native\LibTorchSharp\LibTorchSharp.vcxproj", "{CAD9DB7F-3223-3324-884D-FA2381593DA7}"
37+
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "LibTorchSharp", "bin\obj\x64.Debug\Native\LibTorchSharp\LibTorchSharp.vcxproj", "{E7467DDF-893C-38A8-8E19-6B4E3FB10F55}"
3838
EndProject
3939
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "LibTorchSharp", "bin\obj\x64.Release\Native\LibTorchSharp\LibTorchSharp.vcxproj", "{BB811429-0DF1-3D22-B664-09C2F5A9E0AB}"
4040
EndProject
@@ -46,7 +46,7 @@ EndProject
4646
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Redist", "Redist", "{D8C60CD8-8429-45F2-A755-47B6CD10FDF8}"
4747
ProjectSection(SolutionItems) = preProject
4848
src\Redist\libtorch-cpu\libtorch-cpu.proj = src\Redist\libtorch-cpu\libtorch-cpu.proj
49-
src\Redist\libtorch-cuda-12.1\libtorch-cuda-12.1.proj = src\Redist\libtorch-cuda-12.1\libtorch-cuda-12.1.proj
49+
src\Redist\libtorch-cuda-12.8\libtorch-cuda-12.8.proj = src\Redist\libtorch-cuda-12.8\libtorch-cuda-12.8.proj
5050
EndProjectSection
5151
EndProject
5252
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Native-Release", "Native-Release", "{4DB9E84D-324C-408F-87A6-246E86205540}"
@@ -107,14 +107,10 @@ Global
107107
{42B45168-476D-4BFA-87B8-81A34E6295CD}.Release|Any CPU.Build.0 = Release|Any CPU
108108
{42B45168-476D-4BFA-87B8-81A34E6295CD}.Release|x64.ActiveCfg = Release|Any CPU
109109
{42B45168-476D-4BFA-87B8-81A34E6295CD}.Release|x64.Build.0 = Release|Any CPU
110-
{CAD9DB7F-3223-3324-884D-FA2381593DA7}.Debug|Any CPU.ActiveCfg = Debug|x64
111-
{CAD9DB7F-3223-3324-884D-FA2381593DA7}.Debug|x64.ActiveCfg = Debug|x64
112-
{CAD9DB7F-3223-3324-884D-FA2381593DA7}.Release|Any CPU.ActiveCfg = Release|x64
113-
{CAD9DB7F-3223-3324-884D-FA2381593DA7}.Release|x64.ActiveCfg = Release|x64
114-
{E4C0DBEE-0815-311B-9065-137BB50BD793}.Debug|Any CPU.ActiveCfg = Debug|x64
115-
{E4C0DBEE-0815-311B-9065-137BB50BD793}.Debug|x64.ActiveCfg = Debug|x64
116-
{E4C0DBEE-0815-311B-9065-137BB50BD793}.Release|Any CPU.ActiveCfg = Release|x64
117-
{E4C0DBEE-0815-311B-9065-137BB50BD793}.Release|x64.ActiveCfg = Release|x64
110+
{E7467DDF-893C-38A8-8E19-6B4E3FB10F55}.Debug|Any CPU.ActiveCfg = Debug|x64
111+
{E7467DDF-893C-38A8-8E19-6B4E3FB10F55}.Debug|x64.ActiveCfg = Debug|x64
112+
{E7467DDF-893C-38A8-8E19-6B4E3FB10F55}.Release|Any CPU.ActiveCfg = Release|x64
113+
{E7467DDF-893C-38A8-8E19-6B4E3FB10F55}.Release|x64.ActiveCfg = Release|x64
118114
{DD652544-711E-4029-83FF-DA4A9600E6E7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
119115
{DD652544-711E-4029-83FF-DA4A9600E6E7}.Debug|Any CPU.Build.0 = Debug|Any CPU
120116
{DD652544-711E-4029-83FF-DA4A9600E6E7}.Debug|x64.ActiveCfg = Debug|Any CPU
@@ -180,7 +176,7 @@ Global
180176
{6C323B05-9028-4B09-911C-3C03AE058BEE} = {AED9C836-31E3-4F3F-8ABC-929555D3F3C4}
181177
{42B45168-476D-4BFA-87B8-81A34E6295CD} = {09EADF06-BE25-4228-AB53-95AE3E15B530}
182178
{567456AD-B026-4CB6-B98D-4FC930C90223} = {D3D38B03-B557-484D-8348-8BADEE4DF592}
183-
{CAD9DB7F-3223-3324-884D-FA2381593DA7} = {CF2C1A9E-3A8A-4329-8A6E-7880C15AAC3D}
179+
{E7467DDF-893C-38A8-8E19-6B4E3FB10F55} = {CF2C1A9E-3A8A-4329-8A6E-7880C15AAC3D}
184180
{BB811429-0DF1-3D22-B664-09C2F5A9E0AB} = {4DB9E84D-324C-408F-87A6-246E86205540}
185181
{CF2C1A9E-3A8A-4329-8A6E-7880C15AAC3D} = {09EADF06-BE25-4228-AB53-95AE3E15B530}
186182
{D8C60CD8-8429-45F2-A755-47B6CD10FDF8} = {09EADF06-BE25-4228-AB53-95AE3E15B530}

azure-pipelines.yml

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@ parameters:
99
# push them to the artifacts feed of the Azure CI project
1010
- name: BuildLibTorchPackages
1111
type: boolean
12-
default: false
12+
default: true
1313
- name: PushPackagesToFeed
1414
type: boolean
1515
default: false
16+
1617
# Set which source branch to build libtorch-* packages.
1718
# The build-libtorch jobs are only run if the source branch is the same as this value.
1819
# The default is 'main' branch.
@@ -117,7 +118,7 @@ jobs:
117118
condition: eq('${{ parameters.BuildLibTorchPackages }}', true)
118119
displayName: Download libtorch native binaries
119120

120-
- script: dotnet build -c $(BuildConfig) src/Redist/libtorch-cuda-12.1/libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:SkipTests=true /p:TargetOS=linux /t:Build /p:IncludeLibTorchCudaPackages=true
121+
- script: dotnet build -c $(BuildConfig) src/Redist/libtorch-cuda-12.8/libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:SkipTests=true /p:TargetOS=linux /t:Build /p:IncludeLibTorchCudaPackages=true
121122
condition: eq('${{ parameters.BuildLibTorchPackages }}', true)
122123
displayName: Download libtorch native CUDA binaries
123124

@@ -157,7 +158,7 @@ jobs:
157158
- script: dotnet build -c $(BuildConfig) src/Redist/libtorch-cpu/libtorch-cpu.proj /p:UpdateSHA=true /p:SkipTests=true /p:TargetOS=windows /t:Build /p:IncludeLibTorchCpuPackages=true
158159
displayName: Download libtorch native binaries
159160

160-
- script: dotnet build -c $(BuildConfig) src/Redist/libtorch-cuda-12.1/libtorch-cuda-12.1.proj /p:UpdateSHA=true /p:SkipTests=true /p:TargetOS=windows /t:Build /p:IncludeLibTorchCudaPackages=true
161+
- script: dotnet build -c $(BuildConfig) src/Redist/libtorch-cuda-12.8/libtorch-cuda-12.8.proj /p:UpdateSHA=true /p:SkipTests=true /p:TargetOS=windows /t:Build /p:IncludeLibTorchCudaPackages=true
161162
condition: eq('${{ parameters.BuildLibTorchPackages }}', true)
162163
displayName: Download libtorch native CUDA binaries
163164

@@ -348,9 +349,10 @@ jobs:
348349
# Only run if BuildLibTorchPackages is true
349350
- job: Build_libtorch_cuda_win_Packages
350351
################################################################################
351-
condition: and(ne(variables['system.pullrequest.isfork'], true), eq(variables['build.sourcebranchname'], '${{ parameters.SourceBranchName }}'), eq('${{ parameters.BuildLibTorchPackages }}', true))
352+
condition: and(succeeded(), ne(variables['system.pullrequest.isfork'], true), eq(variables['build.sourcebranchname'], '${{ parameters.SourceBranchName }}'), eq('${{ parameters.BuildLibTorchPackages }}', true))
352353
dependsOn:
353354
- Windows_Native_Build_For_Packages
355+
- Build_TorchSharp_And_libtorch_cpu_Packages
354356
variables:
355357
BuildConfig: Release
356358
OfficialBuildId: $(BUILD.BUILDNUMBER)
@@ -382,7 +384,7 @@ jobs:
382384
- script: dotnet restore pkg/pack.proj /p:Configuration=Release
383385
displayName: Restore package projects
384386

385-
- script: dotnet pack -c $(BuildConfig) --no-build -v:n /p:SkipNative=true /p:SkipTests=true /p:IncludeTorchSharpPackage=false /p:IncludeLibTorchCpuPackages=false /p:IncludeLibTorchCudaPackages=true pkg/pack.proj
387+
- script: dotnet pack -c $(BuildConfig) --no-build -v:n /p:SkipNative=true /p:SkipTests=true /p:IncludeTorchSharpPackage=false /p:IncludeLibTorchCpuPackages=false /p:IncludeLibTorchCudaPackages=true /p:TargetOS=windows pkg/pack.proj
386388
displayName: Create Packages
387389

388390
# We are 10GB space-constrained on the Azure Pipelines CI system so clean up what we can
@@ -403,9 +405,10 @@ jobs:
403405
################################################################################
404406
- job: Build_libtorch_cuda_linux_Packages
405407
################################################################################
406-
condition: and(ne(variables['system.pullrequest.isfork'], true), eq(variables['build.sourcebranchname'], '${{ parameters.SourceBranchName }}'), eq('${{ parameters.BuildLibTorchPackages }}', true))
408+
condition: and(succeeded(), ne(variables['system.pullrequest.isfork'], true), eq(variables['build.sourcebranchname'], '${{ parameters.SourceBranchName }}'), eq('${{ parameters.BuildLibTorchPackages }}', true))
407409
dependsOn:
408410
- Linux_Native_Build_For_Packages
411+
- Build_libtorch_cuda_win_Packages
409412
variables:
410413
BuildConfig: Release
411414
OfficialBuildId: $(BUILD.BUILDNUMBER)
@@ -448,7 +451,7 @@ jobs:
448451
- script: dotnet restore pkg/pack.proj /p:Configuration=Release
449452
displayName: Restore package projects
450453

451-
- script: dotnet pack -c $(BuildConfig) --no-build -v:n /p:SkipNative=true /p:SkipTests=true /p:ApiCompatGenerateSuppressionFile=true /p:IncludeTorchSharpPackage=false /p:IncludeLibTorchCpuPackages=false /p:IncludeLibTorchCudaPackages=true pkg/pack.proj
454+
- script: dotnet pack -c $(BuildConfig) --no-build -v:n /p:SkipNative=true /p:SkipTests=true /p:ApiCompatGenerateSuppressionFile=true /p:IncludeTorchSharpPackage=false /p:IncludeLibTorchCpuPackages=false /p:IncludeLibTorchCudaPackages=true /p:TargetOS=linux pkg/pack.proj
452455
displayName: Create Packages
453456

454457
# We are 10GB space-constrained on the Azure Pipelines CI system so clean up what we can
@@ -859,4 +862,4 @@ jobs:
859862
publishVstsFeed: 'TorchSharp/TestPackages'
860863
allowPackageConflicts: true
861864
# often fails - try but ignore the error until we sort it out
862-
continueOnError: true
865+
continueOnError: true

build/BranchInfo.props

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<PropertyGroup>
33
<MajorVersion>0</MajorVersion>
44
<MinorVersion>105</MinorVersion>
5-
<PatchVersion>1</PatchVersion>
6-
<PreviousPackageVersion>0.105.0</PreviousPackageVersion>
5+
<PatchVersion>2</PatchVersion>
6+
<PreviousPackageVersion>0.105.1</PreviousPackageVersion>
77
</PropertyGroup>
88
</Project>

0 commit comments

Comments
 (0)