Spaces:
Paused
Paused
Download scripts/setup.ps1 from adwitiyashukla/gridpulse: direct link, hf CLI and curl.
- Browser
- Download file 875 Bytes
-
https://huggingface.co/spaces/adwitiyashukla/gridpulse/resolve/main/scripts/setup.ps1
- Command line
-
hf download hf://spaces/adwitiyashukla/gridpulse/scripts/setup.ps1
-
curl -L -o setup.ps1 https://huggingface.co/spaces/adwitiyashukla/gridpulse/resolve/main/scripts/setup.ps1
875 Bytes
| $ErrorActionPreference = "Stop" | |
| Set-Location (Split-Path $PSScriptRoot -Parent) | |
| Write-Host "`n=== Creating virtual environment ===" -ForegroundColor Cyan | |
| if (-Not (Test-Path ".venv")) { python -m venv .venv } | |
| & .\.venv\Scripts\Activate.ps1 | |
| Write-Host "`n=== Installing dependencies ===" -ForegroundColor Cyan | |
| python -m pip install --upgrade pip | |
| pip install -r requirements-dev.txt | |
| pip install -r requirements-torch.txt --index-url https://download.pytorch.org/whl/cpu | |
| pip install -e . --no-deps | |
| if (-Not (Test-Path ".env")) { | |
| Copy-Item .env.example .env | |
| Write-Host "`nCreated .env - add your EIA_API_KEY before continuing." -ForegroundColor Yellow | |
| Write-Host "Free key: https://www.eia.gov/opendata/register.php" -ForegroundColor Yellow | |
| } | |
| Write-Host "`n=== Setup complete ===" -ForegroundColor Green | |
| Write-Host "Next: gridpulse probe then gridpulse all" | |