-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstart_mlflow.ps1
More file actions
26 lines (21 loc) · 1.12 KB
/
Copy pathstart_mlflow.ps1
File metadata and controls
26 lines (21 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# Start MLflow UI to view experiment results
# This script ensures MLflow points to the correct tracking directory
Write-Host "Starting MLflow UI..." -ForegroundColor Green
# Check if virtual environment exists
if (Test-Path ".venv\Scripts\Activate.ps1") {
Write-Host "Activating virtual environment..." -ForegroundColor Cyan
& ".venv\Scripts\Activate.ps1"
} else {
Write-Host "Warning: Virtual environment not found. Make sure MLflow is installed." -ForegroundColor Yellow
}
# Get absolute path to mlruns
$mlrunsPath = Join-Path $PSScriptRoot "mlruns"
$dbPath = Join-Path $PSScriptRoot "mlflow.db"
Write-Host "MLflow Tracking Directory: $mlrunsPath" -ForegroundColor Cyan
Write-Host "MLflow Database: $dbPath" -ForegroundColor Cyan
Write-Host ""
Write-Host "Access MLflow UI at: http://localhost:5000" -ForegroundColor Yellow
Write-Host "Press Ctrl+C to stop the server" -ForegroundColor Gray
Write-Host ""
# Start MLflow UI with SQLite backend for better reliability
mlflow ui --backend-store-uri "sqlite:///$($dbPath.Replace('\\', '/'))" --default-artifact-root "$($mlrunsPath.Replace('\\', '/'))" --host 127.0.0.1 --port 5000