Spaces:
Running on Zero
Running on Zero
Download test.sh from richardchencccc/of3gs-demo: direct link, hf CLI and curl.
- Browser
- Download file 1.18 kB
-
https://huggingface.co/spaces/richardchencccc/of3gs-demo/resolve/main/test.sh
- Command line
-
hf download hf://spaces/richardchencccc/of3gs-demo/test.sh
-
curl -L -o test.sh https://huggingface.co/spaces/richardchencccc/of3gs-demo/resolve/main/test.sh
1.18 kB
| set -euo pipefail | |
| GPU_NUM="${GPU_NUM:-4}" | |
| NUM_NODES="${NUM_NODES:-1}" | |
| MASTER_ADDR="${MASTER_ADDR:-localhost}" | |
| MASTER_PORT="${MASTER_PORT:-12345}" | |
| RDZV_ID="${RDZV_ID:-of3gs_test}" | |
| EXPERIMENT="${EXPERIMENT:-dl3dv}" | |
| PRE_OF3GS_PATH="${PRE_OF3GS_PATH:-weights/of3gs.ckpt}" | |
| TEST_OUTPUT_PATH="${TEST_OUTPUT_PATH:-outputs/of3gs}" | |
| COMPUTE_SCORES="${COMPUTE_SCORES:-false}" | |
| WANDB_PROJECT="${WANDB_PROJECT:-of3gs}" | |
| WANDB_ENTITY="${WANDB_ENTITY:-null}" | |
| WANDB_NAME="${WANDB_NAME:-of3gs_test}" | |
| WANDB_MODE="${WANDB_MODE:-offline}" | |
| torchrun \ | |
| --nnodes=$NUM_NODES \ | |
| --nproc_per_node=$GPU_NUM \ | |
| --rdzv_id=$RDZV_ID \ | |
| --rdzv_backend=c10d \ | |
| --rdzv_endpoint=$MASTER_ADDR:$MASTER_PORT \ | |
| -m src.main \ | |
| mode=test \ | |
| model.encoder.mode=test \ | |
| +experiment="$EXPERIMENT" \ | |
| trainer.devices="$GPU_NUM" \ | |
| trainer.num_nodes="$NUM_NODES" \ | |
| wandb.project="$WANDB_PROJECT" \ | |
| wandb.entity="$WANDB_ENTITY" \ | |
| wandb.name="$WANDB_NAME" \ | |
| wandb.mode="$WANDB_MODE" \ | |
| pre_of3gs_path="$PRE_OF3GS_PATH" \ | |
| test.output_path="$TEST_OUTPUT_PATH" \ | |
| test.compute_scores="$COMPUTE_SCORES" \ | |
| +hydra.job.config.store_config=false \ | |
| "$@" | |