If you seeDocumentation Index
Fetch the complete documentation index at: https://wb-21fd5541-style-guide-support-models-articles-20260527-00.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Cuda out of memory during a sweep, refactor your code to use process-based execution. Rewrite your code as a Python script and call the sweep agent from the CLI instead of the Python SDK.
-
Add your training logic to a Python script (for example,
train.py): -
Reference the script in your YAML sweep configuration:
-
Initialize the sweep with the CLI:
-
Start the sweep agent with the CLI. Replace
[SWEEP-ID]with the ID returned in the previous step:
wandb agent) runs each run as a separate process with its own memory allocation, which prevents CUDA memory from accumulating across runs. The Python SDK (wandb.agent) doesn’t provide this process isolation.
For more information, see Sweeps troubleshooting.
Sweeps Run Crashes