$ErrorActionPreference = "Continue"
|
|
Write-Host "GeoAI Workbench environment check" -ForegroundColor Cyan
|
Write-Host ""
|
|
Write-Host "Python installations:"
|
py -0p
|
|
$PythonCandidates = @(
|
(Join-Path $env:LOCALAPPDATA "Programs/Python/Python312/python.exe"),
|
(Join-Path $env:LOCALAPPDATA "Programs/Python/Python311/python.exe"),
|
(Join-Path $env:ProgramFiles "Python312/python.exe"),
|
(Join-Path $env:ProgramFiles "Python311/python.exe")
|
)
|
$SupportedPython = $PythonCandidates | Where-Object { Test-Path $_ } | Select-Object -First 1
|
|
Write-Host ""
|
Write-Host "Node:"
|
node --version
|
|
Write-Host ""
|
Write-Host "GPU:"
|
nvidia-smi --query-gpu=name,memory.total,driver_version --format=csv,noheader
|
if ($LASTEXITCODE -ne 0) {
|
Write-Warning "NVIDIA GPU/CUDA is unavailable or cannot be queried. CPU-only demos remain available."
|
}
|
|
Write-Host ""
|
if ($SupportedPython) {
|
Write-Host "Detected: $(& $SupportedPython --version) at $SupportedPython"
|
Write-Host "Python version: ready" -ForegroundColor Green
|
} else {
|
Write-Warning "Install Python 3.11 or 3.12 before running setup.ps1."
|
}
|