How to run InstantID on a cloud GPU

Rent a GPU on Deploy, then open a terminal in JupyterLab or over SSH. Install InstantID from the official repository, download the checkpoints and the face encoder the README names, run infer.py or gradio_demo/app.py, and copy result.jpg off the instance before you destroy it. Destroying the instance deletes its disk.

The README’s ComfyUI list names cubiq/ComfyUI_InstantID. That node’s own README is the ComfyUI route below. Installing ComfyUI is How to install ComfyUI and ComfyUI-Manager on a cloud GPU. Another face pipeline with its own InsightFace terms: How to run LivePortrait on a cloud GPU. The tunnel for a local web page is How to use SSH port forwarding on a cloud GPU. How published FLUX and SDXL weight sizes are read: How much VRAM do I need for FLUX and SDXL.

The README disclaimer says: “The code of InstantID is released under Apache License for both academic and commercial usage. However, both manual-downloading and auto-downloading face models from insightface are for non-commercial research purposes only according to their license. Our released checkpoints are also for research purposes only. Users are granted the freedom to create images using this tool, but they are obligated to comply with local laws and utilize it responsibly. The developers will not assume any responsibility for potential misuse by users.” LICENSE is the Apache License, Version 2.0, January 2004, and its appendix copyright line is still the unfilled template Copyright [yyyy] [name of copyright owner] (read 2026-11-12). The GitHub license field the same day was Apache-2.0. The model card for InstantX/InstantID the same day had license apache-2.0, gated false, and a shorter paragraph that does not repeat the face-model sentence. The InsightFace README license section says: “The code of InsightFace is released under the MIT License. There is no limitation for both academic and commercial usage.” It then says the training data and the models trained with that data “are available for non-commercial research purposes only”, and that both manual downloads and auto-downloads “follow the above license policy(which is for non-commercial research purposes only).” Read those files before you use the face models.

The commands below are copied from the upstream files named in each step. They were not run on a CloudGPU instance for this page. Anything this page adds around them is marked.

What the README says about memory

The InstantID README does not print a GPU GB figure. Its memory note is this pair of calls, with the heading “To save VRAM”:

pipe.enable_model_cpu_offload()
pipe.enable_vae_tiling()

The model card README fetched the same day also publishes no GB figure. This page did not re-measure a run. GET /v1/public/compute-capabilities does not list GPUs. It returns feature flags. The memory column is vram_gb from gpu-prices.json, updated_at 2026-11-12T23:03:50.976Z. GET /v1/public/gpu-catalog the same day (generated_at 2026-11-12T23:03:51.922Z) listed the same names and the same vram_gb values, plus Ascend 910B at 64, which is not in gpu-prices.json and is not listed here. The catalog response also includes an availability field. This page does not copy it. Every prices row has gpu_count 1. Every vram_gb below is 8 or higher. This page does not mark a row as enough, because the README publishes no GB figure to compare. Which listing you can start is on Deploy.

The catalog template named ComfyUI has id flux-1-dev, category image-gen, recommended_gpu RTX 4090 48G, and min_vram_gb 24. Those are template fields, not an InstantID README line. The template list had no InstantID template.

Catalog name vram_gb
RTX 2080 8
RTX 3080 10
RTX 2080 Ti 11
RTX 3080 Ti 12
V100 16G 16
A30 24
RTX 3090 24
RTX 4090 24
RTX 4090D 24
RTX 4080 SUPER 32G 32
RTX 5090 32
RTX 5090D 32
V100 32G 32
A100 40G 40
A800 40G 40
A40 48
RTX 4090 48G 48
RTX 4090D 48G 48
RTX A6000 48
NVIDIA RTX PRO 5000 72G 72
RTX PRO 5000 72G 72
A100 80G 80
A800 80G 80
H800 80
RTX 6000D 83
H20 96G 96
RTX PRO 6000 96G 96
RTX PRO 6000 Max-Q 96
H20-3e 141G 141

Install and download

On Deploy, choose Raw GPU. The deploy page says “SSH access and root within a dedicated container”. The README does not print a git clone. This page adds the clone, and it was not run:

git clone https://github.com/instantX-research/InstantID
cd InstantID

The commits API on 2026-11-12 listed 2145b67f9607da6234702063692330185f374486 on the default branch main, committed 2024-07-18T04:12:44Z, message “kolor demo”. The 2024/07/18 release note says an adaptation for Kolors is in training and will be open-sourced after that training. That commit is still the latest on main. This page does not add a later status.

The README’s download section prints these calls, then says you can instead run the Gradio download script:

from huggingface_hub import hf_hub_download
hf_hub_download(repo_id="InstantX/InstantID", filename="ControlNetModel/config.json", local_dir="./checkpoints")
hf_hub_download(repo_id="InstantX/InstantID", filename="ControlNetModel/diffusion_pytorch_model.safetensors", local_dir="./checkpoints")
hf_hub_download(repo_id="InstantX/InstantID", filename="ip-adapter.bin", local_dir="./checkpoints")
pip install -r gradio_demo/requirements.txt
python gradio_demo/download_models.py

gradio_demo/requirements.txt pins diffusers==0.25.1, torch==2.0.0, torchvision==0.15.1, transformers==4.37.1, and huggingface-hub==0.20.2. gradio and insightface are listed without a version. It does not pin a Python version. gradio_demo/download_models.py requests the three InstantX files above, plus latent-consistency/lcm-lora-sdxl file pytorch_lora_weights.safetensors into ./checkpoints, then downloads a zip with gdown into ./models/ and unzips antelopev2.zip there. The README’s face-encoder sentence says to manually download via the URL printed in that sentence into models/antelopev2, “as the default link is invalid.” This page does not paste that issue-comment URL. Copy it from the README if you use the manual download. The folder tree the README prints after that sentence is models, checkpoints, ip_adapter, pipeline_stable_diffusion_xl_instantid.py, and README.md.

How to download a Hugging Face model is the token reference. The README also prints an HF_ENDPOINT mirror export. This page does not repeat it.

Run infer.py

The README says infer.py is the quick path and infer_full.py is the path for paper results. infer.py ends with image.save('result.jpg'). The usage block in the README sets the face encoder and the base model as follows. The base-model string is the README’s example, and the comment points at a CivitAI page:

app = FaceAnalysis(name='antelopev2', root='./', providers=['CUDAExecutionProvider', 'CPUExecutionProvider'])
app.prepare(ctx_id=0, det_size=(640, 640))
base_model = 'wangqixun/YamerMIX_v8'

The same block loads ./checkpoints/ip-adapter.bin and ./checkpoints/ControlNetModel. The usage tips say only the largest face is used, and that a different base model changes the style. This page did not run infer.py.

Gradio demo and SSH

The README prints:

python gradio_demo/app.py

and, for the MultiControlNet file, this line with no python prefix:

gradio_demo/app-multicontrolnet.py

gradio_demo/app.py calls demo.launch() with no arguments. generate_image returns the image to a gr.Image component and does not call save. gradio is not pinned in gradio_demo/requirements.txt, so this page does not name a port and does not claim a bind address. Use the URL the process prints. The tunnel command is not in the InstantID README. It is the form in how to use SSH port forwarding on a cloud GPU, with that printed port:

ssh -N -L <port>:127.0.0.1:<port> -p <ssh-port> <ssh-user>@<ssh-host>

Then open http://127.0.0.1:<port> on your computer. This page did not run app.py.

To keep that process after the SSH session closes, this page wraps the README command in tmux. The README does not print tmux:

tmux new -s instantid
cd InstantID
python gradio_demo/app.py

ComfyUI route, from the node README

The InstantID README’s community list names three ComfyUI repositories: cubiq/ComfyUI_InstantID, ZHO-ZHO-ZHO/ComfyUI-InstantID, and huxiuhan/ComfyUI-InstantID. This page follows cubiq/ComfyUI_InstantID because that is the repository named ComfyUI_InstantID. It does not copy the other two install procedures.

The cubiq README says to upgrade ComfyUI, then “Download or git clone this repository into the ComfyUI/custom_nodes/ directory or use the Manager.” It does not print the full git command. This page adds the clone, and it was not run:

cd ComfyUI/custom_nodes
git clone https://github.com/cubiq/ComfyUI_InstantID

requirements.txt in that repository is:

insightface
onnxruntime
onnxruntime-gpu; sys_platform != 'darwin' and platform_machine == 'x86_64'

The README says InstantID requires insightface together with onnxruntime and onnxruntime-gpu. How to install onnxruntime-gpu on a cloud GPU is that install. The face model it names is antelopev2, not buffalo_l. It says to unzip the models into ComfyUI/models/insightface/models/antelopev2. InstantID.py sets INSIGHTFACE_DIR to folder_paths.models_dir joined with insightface, and calls FaceAnalysis(name="antelopev2", root=INSIGHTFACE_DIR, ...). The main file ip-adapter.bin goes in ComfyUI/models/instantid. The controlnet file diffusion_pytorch_model.safetensors goes in the ComfyUI controlnet directory. The README says “Remember at the moment this is only for SDXL.”

The same README says basic workflows are in the examples directory, that a resolution slightly different from 1024x1024 such as 1016x1016 is what it uses for watermarks, and that CFG should be lowered to at least 4/5 or the RescaleCFG node used. The default Apply InstantID node “automatically injects 35% noise”, and the advanced node includes a noise option. apply_instantid defaults noise to 0.35. Those are the node’s figures. This page did not run the workflow.

The cubiq README’s important note dated 2025.04.14 says the repository is in “maintenance only” mode. The commits API on 2026-11-12 listed 72495e806bc2ab9c41581e15ccaa1bcf83c477e8 on main, committed 2025-04-14T07:49:57Z, message “maintenance mode”. Its LICENSE is the Apache License, Version 2.0, January 2004, and the appendix copyright line is the unfilled template. The ComfyUI node does not write an image file itself. ComfyUI folder_paths.py on commit c1eece62cbf1805d4f64286d7f5592e6a215e6ba (2026-11-12T20:46:52Z) sets output_directory to base_path joined with output. The ComfyUI examples top-level list on 2026-11-12 had no InstantID directory. Commit f9431bb000ce792094ff345446e22cac1ea6cef3 was the latest on that repository, committed 2025-11-26T20:33:58Z.

When it fails

CUDA out of memory. The README’s documented response is enable_model_cpu_offload() and enable_vae_tiling(). It does not print a GB target. If the process raises that error, use how to fix CUDA out of memory on a cloud GPU.

“CUDA error: no kernel image is available for execution on the device” on an RTX 5090. gradio_demo/requirements.txt pins torch==2.0.0. The README does not name compute capability 12.0. The RTX 5090 guide says that card is compute capability 12.0 (sm_120) and needs a PyTorch build for CUDA 12.8 or newer. This page did not install a torch wheel and did not re-test InstantID on an RTX 5090. Catalog RTX 5090 and RTX 5090D are 32. That is the catalog number only.

No face in the image. gradio_demo/app.py raises Cannot find any face in the image! Please upload another person image when app.get returns an empty list. The README says it has not supported multi-person, and that it uses the largest face.

Save the images, then destroy

infer.py writes result.jpg in the working directory. The Gradio script returns the image to the page and does not call save in generate_image. A ComfyUI save node writes under the output directory above. Copy those files off before you destroy the instance. Save your work before you destroy a cloud GPU is the checklist. The terms say data on local instance storage is permanently deleted when the instance is destroyed.

The pricing page FAQ states the billing rule in these words:

Per-minute options have a 1-minute minimum; unused prepaid minutes are refunded when you destroy the instance. Some configurations use whole-hour billing with a 1-hour minimum; unused time within a charged hour is not refunded on voluntary stop. The billing period, minimum charge and initial prepayment are shown before confirmation. No subscription.

Prices are not copied here.

Frequently asked questions

How much VRAM does the InstantID README publish?

The InstantID README and the InstantX/InstantID model card publish no GB figure. The README memory note is pipe.enable_model_cpu_offload() and pipe.enable_vae_tiling(). Every vram_gb in https://cloudgpu.app/gpu-prices.json (updated_at 2026-11-12T23:03:50.976Z) is 8 or higher. This page does not mark a row as enough. The catalog template named ComfyUI has id flux-1-dev, recommended_gpu RTX 4090 48G, and min_vram_gb 24. Those are template fields, not an InstantID README line. Which listing you can start is on https://cloudgpu.app/deploy.

What license applies to the code, the checkpoints, and the face models?

The README says the code is under the Apache License for both academic and commercial usage, that manual and automatic downloads of InsightFace face models are for non-commercial research purposes only, and that the released checkpoints are also for research purposes only. LICENSE is the Apache License, Version 2.0, January 2004, and the appendix copyright line is still the unfilled template. The InsightFace README says the InsightFace code is under the MIT License with no limitation for academic and commercial usage, and that the training data and the models trained with that data are for non-commercial research purposes only. Read those files before you use the face models.

How do I open the Gradio demo through SSH?

The README says to run python gradio_demo/app.py. app.py calls demo.launch() with no arguments. gradio is not pinned in gradio_demo/requirements.txt, so this page does not name a port. Use the URL the process prints, and forward that port to 127.0.0.1 with the SSH tunnel. generate_image returns the image to the page and does not call save. This page did not run app.py.

Do the images stay on the instance after I destroy it?

No. infer.py writes result.jpg in the working directory. A ComfyUI save node writes under the output directory, which folder_paths.py joins to base_path. Copy those files off before you destroy the instance. The terms say data on local instance storage is permanently deleted when the instance is destroyed.

Sources (read 2026-11-12, Asia/Shanghai)


Cards you can start are on the Deploy page. Prices are on https://cloudgpu.app/pricing and are not repeated here.

Last updated: 2026-11-12 (Asia/Shanghai).