colab-run
Run a Python script on a fresh Google Colab VM and automatically release it upon completion. tldr-pages
On several platforms
Several platforms
Run a local script on a fresh CPU VM and release the VM upon completion
colab run path/to/script.pyIdentifyRun a local script on a GPU runtime
colab run --gpu T4 path/to/script.pyIdentifyRun a local script on a TPU runtime
colab run --tpu v5e1 path/to/script.pyIdentifyRun a script with forwarded command-line arguments
colab run path/to/script.py argument1 argument2 ...IdentifyRun a script on a GPU and keep the session active after completion
colab run --gpu T4 --keep path/to/script.pyIdentifyRun a script on a named session with a custom timeout
colab run --session session_name --timeout 60.0 path/to/script.pyIdentify