From 74c7e723c2cd86834c243718ee769edd34172f65 Mon Sep 17 00:00:00 2001 From: XXXXRT666 <157766680+XXXXRT666@users.noreply.github.com> Date: Mon, 12 May 2025 18:15:24 +0100 Subject: [PATCH] WIP --- .github/build_windows_packages.ps1 | 31 ++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/.github/build_windows_packages.ps1 b/.github/build_windows_packages.ps1 index 57a40742..8bc20d6b 100644 --- a/.github/build_windows_packages.ps1 +++ b/.github/build_windows_packages.ps1 @@ -16,6 +16,23 @@ Remove-Item "$srcDir\.git" -Recurse -Force -ErrorAction SilentlyContinue Write-Host "[INFO] Creating tmp dir..." New-Item -ItemType Directory -Force -Path $tmpDir | Out-Null +Write-Host "[INFO] Downloading Python..." +$pyUrl = "https://github.com/astral-sh/python-build-standalone/releases/download/20250409/cpython-3.11.12+20250409-x86_64-pc-windows-msvc-pgo-full.tar.zst" +$zst = "$tmpDir\python.tar.zst" +Invoke-WebRequest $pyUrl -OutFile $zst +Get-ChildItem +Get-ChildItem $tmpDir +Write-Host "0000" +& "C:\Program Files\7-Zip\7z.exe" e $zst -o$tmpDir -aoa | Out-Null +Get-ChildItem $tmpDir +Write-Host "11111" +$tar = Get-ChildItem "$tmpDir" -Filter "*.tar" | Select-Object -First 1 +Get-ChildItem $tmpDir +Write-Host "222222" +& "C:\Program Files\7-Zip\7z.exe" x $tar.FullName -o$tmpDir\extracted -aoa | Out-Null +Get-ChildItem $tmpDir +Move-Item "$tmpDir\extracted\python\install" "$srcDir\runtime" + $baseHF = "https://huggingface.co/XXXXRT/GPT-SoVITS-Pretrained/resolve/main" $PRETRAINED_URL = "$baseHF/pretrained_models.zip" $G2PW_URL = "$baseHF/G2PWModel.zip" @@ -57,20 +74,6 @@ Move-Item "$($ffDir.FullName)\bin\ffprobe.exe" "$srcDir" Remove-Item $ffZip Remove-Item $ffDir.FullName -Recurse -Force -Write-Host "[INFO] Downloading Python..." -$pyUrl = "https://github.com/astral-sh/python-build-standalone/releases/download/20250409/cpython-3.11.12+20250409-x86_64-pc-windows-msvc-pgo-full.tar.zst" -$zst = "$tmpDir\python.tar.zst" -Invoke-WebRequest $pyUrl -OutFile $zst -Get-ChildItem -Get-ChildItem $tmpDir -& "C:\Program Files\7-Zip\7z.exe" e $zst -o$tmpDir -aoa | Out-Null -Get-ChildItem $tmpDir -Write-Host "11111" -$tar = Get-ChildItem "$tmpDir" -Filter "*.tar" | Select-Object -First 1 -Get-ChildItem $tmpDir -& "C:\Program Files\7-Zip\7z.exe" x $tar.FullName -o$tmpDir\extracted -aoa | Out-Null -Move-Item "$tmpDir\extracted\python\install" "$srcDir\runtime" - Write-Host "[INFO] Installing PyTorch..." $torchCmd = switch ($cuda) { "cu124" { "pip install torch==2.5.1 torchaudio==2.5.1 --index-url https://download.pytorch.org/whl/cu124" }