Archived
LoRA for image and video generators: - civitai and Hugging Face adapter files as published: kohya, ComfyUI and diffusers/PEFT key names; LoRA, LoCon, LoHa, LoKr and full-weight diffs; DoRA, OFT and Tucker are refused by name - stacked per request with a strength each, through the `loras` field or <lora:name:strength> tags in the prompt; --lora-dir serves every file in a directory, GET /v1/loras lists them, and --max-loras / --max-lora-rank size the slots on the card (generators default to rank 64) - Krea 2, Qwen-Image 2.1, FLUX.3 [klein], MiniMax H3, LTX-2.5, Anima and SDXL New models: - Anima (base, aesthetic and turbo): Cosmos-Predict2 DiT with the Qwen3-0.6B text encoder and the Qwen-Image VAE, on one card - Stable Diffusion XL and its single-file finetunes (Illustrious, NoobAI including V-Pred, Pony), read as civitai ships them, with the Euler, Euler a and DPM++ 2M samplers Recipes: - q38-27b-mxfp4-df2: any bf16 Qwen3.8-27B or finetune at MXFP4 with the DFlash2 drafter - Krea 2 finetunes from civitai: scripts/krea2_native.py reads Krea's own key names, and krea-2-fp8-unscaled keeps a plain-fp8 file's codes exactly Changes: --max-num-batched-tokens defaults to 2048 (was 8192). Plugin ABI 25: out-of-tree plugins must be rebuilt.
32 lines
2.1 KiB
Plaintext
32 lines
2.1 KiB
Plaintext
# anima-fp8.recipe -- Anima (Base, Aesthetic or Turbo) with block-scaled fp8 linears.
|
|
#
|
|
# rad-convert <Anima>/split_files/diffusion_models/anima-aesthetic-v1.1.safetensors \
|
|
# --add <Anima>/split_files/text_encoders/qwen_3_06b_base.safetensors \
|
|
# --add <Anima>/split_files/vae/qwen_image_vae.safetensors \
|
|
# --config <Qwen/Qwen3-0.6B-Base> --tokenizer2 <ComfyUI>/comfy/text_encoders/t5_tokenizer/tokenizer.json \
|
|
# --arch anima --set anima.variant=aesthetic \
|
|
# --recipe data/recipes/anima-fp8.recipe -o anima-aesthetic-fp8.rad
|
|
#
|
|
# Every linear of the text encoder and of the DiT's 28 blocks (self- and cross-attention, MLP)
|
|
# becomes E4M3 codes with a bf16 scale a 128 x 128 block, read by the fp8a8 GEMMs over activations
|
|
# quantised the same way. The LLM adapter, the embeddings, the modulation linears, the final layer
|
|
# and the VAE stay bf16. The patch embedding (without its padding-mask columns) and the VAE's causal
|
|
# convolutions (at their last temporal tap) are computed at convert and stored bf16.
|
|
|
|
te.blk.*.attn_qkv.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
te.blk.*.attn_output.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
te.blk.*.ffn_gate_up.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
te.blk.*.ffn_down.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.attn_qkv.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.attn_output.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.cross_q.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.cross_k.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.cross_v.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.cross_output.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.mlp_layer1.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
dit.blk.*.mlp_layer2.weight rtn codes=fp8_e4m3 block=128x128 scale=bf16
|
|
|
|
dit.x_embed.weight cast dtype=bf16
|
|
decoder.* cast dtype=bf16
|
|
conv2.* cast dtype=bf16
|