Back to Skills

nv-generate-vae-finetune

Used for finetuning the NV-Generate-CTMR MAISI VAE from CT/MRI NIfTI datalists. Not for clinical or production data approval.

2,791stars324forksUpdated 8/5/2026

Security Assessment

Safe(91/100)
Security Score91/100

About nv-generate-vae-finetune

This NVIDIA MedTech skill wraps the finetuning of the NV-Generate-CTMR MAISI VAE (variational autoencoder) from user-supplied CT or MRI NIfTI training volumes. It solves the problem of running an upstream training workflow that is otherwise only documented in a tutorial notebook: rather than executing the notebook, the wrapper stages the required config and datalist glue locally and calls upstream helper APIs, exposing the most-tuned training fields as CLI flags. Inputs are a MONAI-style datalist and a data base directory; outputs are autoencoder and discriminator checkpoints plus a result JSON.

The primary entrypoint, `run_vae_finetune.py`, accepts a datalist, data base directory, output directory, and flags for epochs, modality, patch size, and a `--preflight` mode. The skill strongly recommends running `--preflight` first to validate a new datalist without a GPU or training, removing it only when the user explicitly wants to launch GPU finetuning. Prerequisites include an explicit `NV_GENERATE_ROOT` pointing at a local upstream checkout (or an automatic search of a workbench cache), an optional `CUDA_VISIBLE_DEVICES`, a CUDA GPU for real training, upstream Python requirements plus `lpips`, and downloaded VAE weights unless training from scratch. Documented side effects are writing staged configs, checkpoints, TensorBoard logs, and summaries under the output directory, caching under the upstream checkout and the Hugging Face/torch caches, and contacting huggingface.co, github.com, and download.pytorch.org during setup. The included skill card marks it research-and-development only with no required credentials.

Target users are developers and medical-imaging engineers finetuning the MAISI VAE for image-synthesis research. The skill states it is not for clinical interpretation, regulatory use, or approving synthetic data for production training.

FAQ

What is the recommended first step?

Run with `--preflight` to validate and stage a finetune check from an input bundle. This requires no GPU and no training; you remove `--preflight` only when explicitly launching real GPU finetuning.

What inputs and outputs does it use?

Inputs are a MONAI-style datalist JSON (with non-empty training and validation/testing entries) and a data base directory. Outputs are autoencoder and discriminator checkpoints plus a result JSON.

What are the runtime requirements?

For real training it needs a CUDA GPU, the upstream requirements plus `lpips`, downloaded VAE weights (unless `--train-from-scratch`), and a `NV_GENERATE_ROOT` checkout containing the MAISI VAE train config and helper scripts.

Does it need API keys or credentials?

The skill card lists no required API key or credential. It advises not including secrets in prompts, logs, or output and using least-privilege credentials.

Is it safe for clinical or production use?

No. It is research-and-development only and is explicitly not for clinical interpretation, regulatory use, or approving synthetic data for production training.

All Files

13 files
evals/evals.json1.2 KB
View
skill-card.md4.0 KB
View
fixtures/preflight_datalist.json0.2 KB
View
SKILL.md12.2 KB
View
fixtures/preflight_dataset/imagesTr/placeholder_mri_train.txt0.0 KB
View
skill.oms.sig6.4 KB
View
fixtures/preflight_dataset/imagesVal/placeholder_mri_val.txt0.0 KB
View
tests/test_run_vae_finetune.py5.6 KB
View
fixtures/README.md0.2 KB
View
validators/output_schema.json4.0 KB
View
scripts/run_vae_finetune.py32.1 KB
View
BENCHMARK.md4.0 KB
View
skill_manifest.yaml6.2 KB
View

Install nv-generate-vae-finetune

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill

Repository

nvidia/skills