File size: 590 Bytes
c2b1b26 | 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 27 28 29 | param(
[string]$Config = "configs/train_2gpu_4090d.json",
[int]$BatchSize = 10,
[int]$Epochs = 500,
[string]$Weights = ""
)
$ErrorActionPreference = "Stop"
$env:CUDA_VISIBLE_DEVICES = "0,1"
$env:PYTHONUTF8 = "1"
$env:USE_LIBUV = "0"
$argsList = @(
"scripts/launch_ddp_no_libuv.py",
"--nproc_per_node=2",
"--master_addr=127.0.0.1",
"--master_port=29500",
"train_seaweed_segmentation.py",
"--config", $Config,
"--batch-size", "$BatchSize",
"--epochs", "$Epochs"
)
if ($Weights -ne "") {
$argsList += @("--weights", $Weights)
}
python @argsList
|