{
  "source_file": "0930",
  "source_platform": "研究机构",
  "author": "Hugging Face Blog",
  "title_listed": "Fast LoRA inference for Flux with Diffusers and PEFT",
  "keywords": "LoRA,Flux,推理",
  "domain": "图像处理",
  "content_type": "教程",
  "is_paid_flag": "否",
  "url": "https://huggingface.co/blog/lora-fast",
  "publish_date": "2025-07",
  "corpus_stage": "推理部署",
  "notes": "Flux的快速LoRA推理",
  "id": "cde2fe77d1be",
  "collected_at": "2026-10-02T15:24:31",
  "title": "Fast LoRA inference for Flux with Diffusers and PEFT",
  "body_markdown": "Back to Articles\nFast LoRA inference for Flux with Diffusers and PEFT\nPublished\n\t\t\t\t\tJuly 23, 2025\nUpdate on GitHub\nUpvote\n56\n+50\nSayak Paul\nsayakpaul\nFollow\nBenjamin Bossan\nBenjaminB\nFollow\nLoRA adapters provide a great deal of customization for models of all shapes and sizes. When it comes to image generation, they can empower the models with\ndifferent styles, different characters, and much more\n. Sometimes, they can also be leveraged\nto reduce inference latency\n. Hence, their importance is paramount, particularly when it comes to customizing and fine-tuning models.\nIn this post, we take the\nFlux.1-Dev model\nfor text-to-image generation because of its widespread popularity and adoption, and how to optimize its inference speed when using LoRAs (~2.3x). It has over 30k adapters trained with it (\nas reported\non the Hugging Face Hub platform). Therefore, its importance to the community is significant.\nNote that even though we demonstrate speedups with Flux, our belief is that our recipe is generic enough to be applied to other models as well.\nIf you cannot wait to get started with the code, please check out the\naccompanying code repository\n.\nTable of contents\nHurdles in optimizing LoRA inference\nOptimization recipe\nOptimized LoRA inference on a consumer GPU\nConclusion\nHurdles in optimizing LoRA inference\nWhen serving LoRAs, it is common to hotswap (swap in and swap out different LoRAs) them. A LoRA changes the base model architecture. Additionally, LoRAs can be different from one another – each one of them could have varying ranks and different layers they target for adaptation. To account for these dynamic properties of LoRAs, we must take necessary steps to ensure the optimizations we apply are robust.\nFor example, we can apply\ntorch.compile\non a model loaded with a particular LoRA to obtain speedups on inference latency. However, the moment we swap out the LoRA with a different one (with a potentially different configuration), we will run into recompilation issues, causing slowdowns in inference.\nOne can also fuse the LoRA parameters into the base model parameters, run compilation, and unfuse the LoRA parameters when loading new ones. However, this approach will again encounter the problem of recompilation whenever inference is run, due to potential architecture-level changes.\nOur optimization recipe takes into account the above-mentioned situations to be as realistic as possible. Below are the key components of our optimization recipe:\nFlash Attention 3 (FA3)\ntorch.compile\nFP8 quantization from TorchAO\nHotswapping-ready\nNote that amongst the above-mentioned, FP8 quantization is lossy but often provides the most formidable speed-memory trade-off. Even though we tested the recipe primarily using NVIDIA GPUs, it should work on AMD GPUs, too.\nOptimization recipe\nIn our previous blog posts (\npost 1\nand\npost 2\n), we have already discussed the benefits of using the first three components of our optimization recipe. Applying them one by one is just a few lines of code:\nfrom\ndiffusers\nimport\nDiffusionPipeline, TorchAoConfig\nfrom\ndiffusers.quantizers\nimport\nPipelineQuantizationConfig\nfrom\nutils.fa3_processor\nimport\nFlashFluxAttnProcessor3_0\nimport\ntorch\n# quantize the Flux transformer with FP8\npipe = DiffusionPipeline.from_pretrained(\n\"black-forest-labs/FLUX.1-dev\"\n,\n    torch_dtype=torch.bfloat16,\n    quantization_config=PipelineQuantizationConfig(\n        quant_mapping={\n\"transformer\"\n: TorchAoConfig(\n\"float8dq_e4m3_row\"\n)}\n    )\n).to(\n\"cuda\"\n)\n# use Flash-attention 3\npipe.transformer.set_attn_processor(FlashFluxAttnProcessor3_0())\n# use torch.compile()\npipe.transformer.\ncompile\n(fullgraph=\nTrue\n, mode=\n\"max-autotune\"\n)\n# perform inference\npipe_kwargs = {\n\"prompt\"\n:\n\"A cat holding a sign that says hello world\"\n,\n\"height\"\n:\n1024\n,\n\"width\"\n:\n1024\n,\n\"guidance_scale\"\n:\n3.5\n,\n\"num_inference_steps\"\n:\n28\n,\n\"max_sequence_length\"\n:\n512\n,\n}\n# first time will be slower, subsequent runs will be faster\nimage = pipe(**pipe_kwargs).images[\n0\n]\nThe FA3 processor comes from\nhere\n.\nThe problems start surfacing when we try to swap in and swap out LoRAs into a compiled diffusion transformer (\npipe.transformer\n) without triggering recompilation.\nNormally, loading and unloading LoRAs will require recompilation, which defeats any speed advantage gained from compilation. Thankfully, there is a way to avoid the need for recompilation. By passing\nhotswap=True\n, diffusers will leave the model architecture unchanged and only exchange the weights of the LoRA adapter itself, which does not necessitate recompilation.\npipe.enable_lora_hotswap(target_rank=max_rank)\npipe.load_lora_weights(<lora-adapter-name1>)\n# compile *after* loading the first LoRA\npipe.transformer.\ncompile\n(mode=\n\"max-autotune\"\n, fullgraph=\nTrue\n)\nimage = pipe(**pipe_kwargs).images[\n0\n]\n# from this point on, load new LoRAs with `hotswap=True`\npipe.load_lora_weights(<lora-adapter-name2>, hotswap=\nTrue\n)\nimage = pipe(**pipe_kwargs).images[\n0\n]\n(As a reminder, the first call to\npipe\nwill be slow as\ntorch.compile\nis a just-in-time compiler. However, the subsequent calls should be significantly faster.)\nThis generally allows for swapping LoRAs without recompilation, but there are limitations:\nWe need to provide the maximum rank among all LoRA adapters ahead of time. Thus, if we have one adapter with rank 16 and another with 32, we need to pass\nmax_rank=32\n.\nLoRA adapters that are hotswapped in can only target the same layers, or a subset of layers, that the first LoRA targets.\nTargeting the text encoder is not supported yet.\nFor more information on hotswapping in Diffusers and its limitations, visit the\nhotswapping section of the documentation\n.\nThe benefits of this workflow become evident when we look at the inference latency without using compilation with hotswapping.\nOption\nTime (s) ⬇️\nSpeedup (vs baseline) ⬆️\nNotes\nbaseline\n7.8910\n–\nBaseline\noptimized\n3.5464\n2.23×\nHotswapping + compilation without recompilation hiccups (FP8 on by default)\nno_fp8\n4.3520\n1.81×\nSame as optimized, but with FP8 quantization disabled\nno_fa3\n4.3020\n1.84×\nDisable FA3 (flash‑attention v3)\nbaseline + compile\n5.0920\n1.55×\nCompilation on, but suffers from intermittent recompilation stalls\nno_fa3_fp8\n5.0850\n1.55×\nDisable FA3 and FP8\nno_compile_fp8\n7.5190\n1.05×\nDisable FP8 quantization and compilation\nno_compile\n10.4340\n0.76×\nDisable compilation: the slowest setting\nKey takeaways\n:\nThe “regular + compile” option provides a decent speedup over the regular option, but it incurs recompilation issues, which increase the overall execution time. In our benchmarks, we don’t present the compilation time.\nWhen recompilation problems are eliminated through hotswapping (also known as the “optimized” option), we achieve the highest speedup.\nIn the “optimized” option, FP8 quantization is enabled, which can lead to quality loss. Even without using FP8, we get a decent amount of speedup (“no_fp8” option).\nFor demonstration purposes, we use a pool of two LoRAs for hotswapping with compilation. For the full code, please refer to the accompanying\ncode repository\n.\nThe optimization recipe we have discussed so far assumes access to a powerful GPU like H100. However, what can we do when we’re limited to using consumer GPUs such as RTX 4090? Let’s find out.\nOptimized LoRA inference on a consumer GPU\nFlux.1-Dev (without any LoRA), using the Bfloat16 data-type, takes ~33GB of memory to run. Depending on the size of the LoRA module, and without using any optimization, this memory footprint can increase even further. Many consumer GPUs like the RTX 4090 only have 24GB. Throughout the rest of this section, we will consider an RTX 4090 machine as our testbed.\nFirst, to enable end-to-end execution of Flux.1-Dev, we can apply CPU offloading wherein components that are not needed to execute the current computation are offloaded to the CPU to free more accelerator memory. Doing so allows us to run the entire pipeline in ~22GB in\n35.403 seconds\non an RTX 4090. Enabling compilation can reduce the latency down to\n31.205 seconds\n(1.12x speedup). In terms of code, it’s just a few lines:\npipe = DiffusionPipeline.from_pretrained(\n\"black-forest-labs/FLUX.1-dev\"\n, torch_dtype=torch.bfloat16,\n)\npipe.enable_model_cpu_offload()\n# Instead of full compilation, we apply regional compilation\n# here to take advantage of `fullgraph=True` and also to reduce\n# compilation time. More details can be found here:\n# https://hf.co/docs/diffusers/main/en/optimization/fp16#regional-compilation\npipe.transformer.compile_repeated_blocks(fullgraph=\nTrue\n)\nimage = pipe(**pipe_kwargs).images[\n0\n]\nNotice that we didn’t apply the FP8 quantization here because it’s not supported with CPU offloading and compilation (supporting\nissue thread\n). Therefore, just applying FP8 quantization to the Flux Transformer isn’t enough to mitigate the memory exhaustion problem, either. In this instance, we decided to remove it.\nTherefore, to take advantage of the FP8 quantization scheme, we need to find a way to do it without CPU offloading. For Flux.1-Dev, if we additionally apply quantization to the T5 text encoder, we should be able to load and run the complete pipeline in 24GB. Below is a comparison of the results with and without the T5 text encoder being quantized (NF4 quantization from\nbitsandbytes\n).\nAs we can notice in the figure above, quantizing the T5 text encoder doesn’t incur too much of a quality loss. Combining the quantized T5 text encoder and FP8-quantized Flux Transformer with\ntorch.compile\ngives us somewhat reasonable results –\n9.668 seconds\nfrom 32.27 seconds (a massive ~3.3x speedup) without a noticeable quality drop.\nIt is possible to generate images with 24 GB of VRAM even without quantizing the T5 text encoder, but that would have made our generation pipeline slightly more complicated.\nWe now have a way to run the entire Flux.1-Dev pipeline with FP8 quantization on an RTX 4090. We can apply the previously established optimization recipe for optimizing LoRA inference on the same hardware. Since FA3 isn’t supported on RTX 4090, we will stick to the following optimization recipe with T5 quantization newly added to the mix:\nFP8 quantization\ntorch.compile\nHotswapping-ready\nT5 quantization (with NF4)\nIn the table below, we show the inference latency numbers with different combinations of the above components applied.\nOption\nKey args flags\nTime (s) ⬇️\nSpeedup (vs baseline) ⬆️\nbaseline\ndisable_fp8=False disable_compile=True\nquantize_t5=True offload=False\n23.6060\n–\noptimized\ndisable_fp8=False disable_compile=False\nquantize_t5=True offload=False\n11.5715\n2.04×\nQuick notes\n:\nCompilation provides a massive 2x speedup over the baseline.\nThe other options yielded OOM errors even with offloading enabled.\nTechnical details of hotswapping\nTo enable hotswapping without triggering recompilation, two hurdles have to be overcome. First, the LoRA scaling factor has to be converted into torch tensors from floats, which is achieved fairly easily. Second, the shape of the LoRA weights needs to padded to the largest required shape. That way, the data in the weights can be replaced without the need to reassign the whole attribute. This is why the\nmax_rank\nargument discussed above is crucial. As we pad the values with zeros, the results remain unchanged, although the computation is slowed down a bit depending on how large the padding is.\nSince no new LoRA attributes are added, this also requires that each LoRA after the first one can only target the same layers, or a subset of layers, that the first one targets. Thus, choose the order of loading wisely. If LoRAs target disjoint layers, there is the possibility to create a dummy LoRA that targets the union of all target layers.\nTo see the nitty-gritty of this implementation, visit the\nhotswap.py\nfile in PEFT\n.\nConclusion\nThis post outlined an optimization recipe for fast LoRA inference with Flux, demonstrating significant speedups. Our approach combines Flash Attention 3,\ntorch.compile\n, and FP8 quantization while ensuring hotswapping capabilities without recompilation issues. On high-end GPUs like the H100, this optimized setup provides a 2.23x speedup over the baseline.\nFor consumer GPUs, specifically the RTX 4090, we tackled memory limitations by introducing T5 text encoder quantization (NF4) and leveraging regional compilation. This comprehensive recipe achieved a substantial 2.04x speedup, making LoRA inference on Flux viable and performant even with limited VRAM. The key insight is that by carefully managing compilation and quantization, the benefits of LoRA can be fully realized across different hardware configurations.\nHopefully, the recipes from this post will inspire you to optimize your\nLoRA-based use cases, benefitting from speedy inference.\nResources\nBelow is a list of the important resources that we cited throughout this post:\nPresenting Flux Fast: Making Flux go brrr on H100s\ntorch.compile and Diffusers: A Hands-On Guide to Peak Performance\nLoRA guide in Diffusers\nFor readers interested in trying this approach, a deployed demo by\nParag Ekbote\nis available on\nReplicate\n. This demo has been designed and tested on NVIDIA L40 and A100 GPUs, demonstrating comparable performance.\nModels mentioned in this article\n2\nDatasets mentioned in this article\n1\nSpaces mentioned in this article\n1\nMore Articles from our Blog\nguide\ncollaboration\ndiffusers\nLoRA training scripts of the world, unite!\n80\nJanuary 2, 2024\npeft\nlora\nguide\nBeyond LoRA: Can you beat the most popular fine-tuning technique?\n105\nJune 18, 2026\nCommunity\nyeonjoon-jung\nJul 24, 2025\nI enjoyed your post! May I ask what version of PyTorch you used for the test results?\nSee translation\nReply\nsayakpaul\nArticle author\nJul 24, 2025\nPyTorch nightly.\nReply\nnoone7273\nJul 25, 2025\nA boy with baloon\nReply\nEdit\nPreview\nUpload images, audio, and videos by dragging in the text input, pasting, or\nclicking here\n.\nTap or paste here to upload images\nComment\n·\nSign up\nor\nlog in\nto comment\nUpvote\n56\n+44\nModels mentioned in this article\n2\nDatasets mentioned in this article\n1\nSpaces mentioned in this article\n1",
  "metadata": {
    "title": "Fast LoRA inference for Flux with Diffusers and PEFT",
    "description": "We’re on a journey to advance and democratize artificial intelligence through open source and open science.",
    "keywords": null,
    "author": null,
    "og:title": "Fast LoRA inference for Flux with Diffusers and PEFT",
    "og:description": "We’re on a journey to advance and democratize artificial intelligence through open source and open science.",
    "og:type": "website",
    "og:url": "https://huggingface.co/blog/lora-fast",
    "og:image": "https://huggingface.co/blog/assets/lora-fast/thumbnail.png",
    "twitter:card": "summary_large_image",
    "twitter:site": "@huggingface",
    "twitter:image": "https://huggingface.co/blog/assets/lora-fast/thumbnail.png"
  },
  "paywall": {
    "listed_paid": false,
    "detected": false,
    "marker": "",
    "public_only": false,
    "policy": "付费/会员内容只保留页面公开可见部分，不绕过付费墙"
  },
  "crawl": {
    "success": true,
    "status_code": 200,
    "error": ""
  },
  "code_blocks": [
    {
      "file": "attachments/cde2fe77d1be/code/body-000.txt",
      "chars": 985,
      "language": "text"
    },
    {
      "file": "attachments/cde2fe77d1be/code/body-001.txt",
      "chars": 387,
      "language": "text"
    },
    {
      "file": "attachments/cde2fe77d1be/code/body-002.txt",
      "chars": 490,
      "language": "text"
    }
  ],
  "images": [
    {
      "status": "ok",
      "url": "https://huggingface.co/avatars/682067f613f9dee8ef0e41e1391c6223.svg",
      "bytes": 397,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-ef7c978fc1c0a367acca.svg",
      "src": "https://huggingface.co/avatars/682067f613f9dee8ef0e41e1391c6223.svg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/no-auth/upIyVlEpqWqoeFTvNzTf5.png",
      "bytes": 8474,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-e54a9c5861715a5e9c64.png",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/no-auth/upIyVlEpqWqoeFTvNzTf5.png",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/1666772404424-noauth.jpeg",
      "bytes": 7280,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-c5033095ae0e4dfd6327.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/1666772404424-noauth.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/5e3aec01f55e2b62848a5217/PMKS0NNB4MJQlTSFzh918.jpeg",
      "bytes": 11598,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-741cc42f07a702f49510.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/5e3aec01f55e2b62848a5217/PMKS0NNB4MJQlTSFzh918.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/1670082547918-noauth.jpeg",
      "bytes": 5134,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-683b320967c7a9a3991e.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/1670082547918-noauth.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/noauth/HXKKlyDzNjei5x-6w7gL2.jpeg",
      "bytes": 4976,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-793be18f70e1a3fbb28f.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/noauth/HXKKlyDzNjei5x-6w7gL2.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/datasets/sayakpaul/sample-datasets/resolve/main/lora-fast/image_1_lora_fast.png",
      "bytes": 1524493,
      "reused": true,
      "local_path": "attachments/cde2fe77d1be/images/002.png",
      "src": "https://huggingface.co/datasets/sayakpaul/sample-datasets/resolve/main/lora-fast/image_1_lora_fast.png",
      "alt": "te_quantized_results",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/datasets/sayakpaul/sample-datasets/resolve/main/lora-fast/image_2_lora_fast.png",
      "bytes": 1330574,
      "reused": true,
      "local_path": "attachments/cde2fe77d1be/images/003.png",
      "src": "https://huggingface.co/datasets/sayakpaul/sample-datasets/resolve/main/lora-fast/image_2_lora_fast.png",
      "alt": "quantized_compiled_results",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/blog/assets/dreambooth_lora_sdxl/thumbnail.png",
      "bytes": 859959,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-c87b9c7da396f4bb81b5.png",
      "src": "https://huggingface.co/blog/assets/dreambooth_lora_sdxl/thumbnail.png",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/638f308fc4444c6ca870b60a/Q11NK-8-JbiilJ-vk2LAR.png",
      "bytes": 15294,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-00e82bd76dcce2c234ce.png",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/638f308fc4444c6ca870b60a/Q11NK-8-JbiilJ-vk2LAR.png",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/1649143001781-624bebf604abc7ebb01789af.jpeg",
      "bytes": 12490,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-f687240cde337070274f.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/1649143001781-624bebf604abc7ebb01789af.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/blog/assets/peft-beyond-lora/thumbnail.png",
      "bytes": 859335,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-bf49a588bce3e3695f34.png",
      "src": "https://huggingface.co/blog/assets/peft-beyond-lora/thumbnail.png",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/1656685953025-62bf03d1e80cec527083cd66.jpeg",
      "bytes": 7446,
      "reused": true,
      "local_path": "attachments/cde2fe77d1be/images/001.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/1656685953025-62bf03d1e80cec527083cd66.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/1649681653581-5f7fbd813e94f16a85448745.jpeg",
      "bytes": 4784,
      "reused": true,
      "local_path": "attachments/cde2fe77d1be/images/000.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/1649681653581-5f7fbd813e94f16a85448745.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/1669189789447-629f3b18ee05727ce328ccbe.jpeg",
      "bytes": 5898,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-492163ca94a89a926baf.jpeg",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/1669189789447-629f3b18ee05727ce328ccbe.jpeg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/avatars/64d855b18df75b35eaed35b4b9282b78.svg",
      "bytes": 1283,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-7d8a956c9d9fccc70cd9.svg",
      "src": "https://huggingface.co/avatars/64d855b18df75b35eaed35b4b9282b78.svg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/avatars/635ba0c6d757c6a5248db82c33962df8.svg",
      "bytes": 397,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-e468958de0cabac30202.svg",
      "src": "https://huggingface.co/avatars/635ba0c6d757c6a5248db82c33962df8.svg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/avatars/5189036488034b94ad39f9cb3006e49a.svg",
      "bytes": 397,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-4a4e0b8db0910f974ba9.svg",
      "src": "https://huggingface.co/avatars/5189036488034b94ad39f9cb3006e49a.svg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/avatars/1952ae3cf5ce6d396fe9b974565df3df.svg",
      "bytes": 397,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-99d11cbaa3fb3b41b4b6.svg",
      "src": "https://huggingface.co/avatars/1952ae3cf5ce6d396fe9b974565df3df.svg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://huggingface.co/avatars/41a1397e1b40fb9a6b88d292b521c3e7.svg",
      "bytes": 397,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-3f6af871bee9429bd62f.svg",
      "src": "https://huggingface.co/avatars/41a1397e1b40fb9a6b88d292b521c3e7.svg",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/68baeb7dbdf2bfb823aacffc/p0J0hLKVCkzJu0auOAz1r.png",
      "bytes": 9738,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-03a343047bcdc3f5071d.png",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/68baeb7dbdf2bfb823aacffc/p0J0hLKVCkzJu0auOAz1r.png",
      "alt": "",
      "downloaded": true
    },
    {
      "status": "ok",
      "url": "https://cdn-avatars.huggingface.co/v1/production/uploads/62b085e6a14cbd643867d561/9gR-XStGUTE-T6vVhKUlA.png",
      "bytes": 16518,
      "reused": false,
      "local_path": "attachments/cde2fe77d1be/images/body-6a84c513065ae3cb2564.png",
      "src": "https://cdn-avatars.huggingface.co/v1/production/uploads/62b085e6a14cbd643867d561/9gR-XStGUTE-T6vVhKUlA.png",
      "alt": "",
      "downloaded": true
    }
  ],
  "audio": [],
  "videos": [],
  "links": [
    {
      "href": "https://huggingface.co/blog",
      "label": "Back to Articles",
      "type": "a"
    },
    {
      "href": "https://github.com/huggingface/blog/blob/main/lora-fast.md",
      "label": "Update on GitHub",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/login?next=%2Fblog%2Flora-fast",
      "label": "Upvote 56",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/Liorra",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/hubnemo",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/Neilblaze",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/lysandre",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/pagarsky",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/iamsingularity",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/sayakpaul",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/BenjaminB",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/spaces/multimodalart/flux-lora-the-explorer",
      "label": "different styles, different characters, and much more",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/ByteDance/Hyper-SD/",
      "label": "to reduce inference latency",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/black-forest-labs/FLUX.1-dev",
      "label": "Flux.1-Dev model",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/models?other=base_model:adapter:black-forest-labs/FLUX.1-dev",
      "label": "as reported",
      "type": "a"
    },
    {
      "href": "https://github.com/huggingface/lora-fast",
      "label": "accompanying code repository",
      "type": "a"
    },
    {
      "href": "https://pytorch.org/blog/presenting-flux-fast-making-flux-go-brrr-on-h100s/",
      "label": "post 1",
      "type": "a"
    },
    {
      "href": "https://pytorch.org/blog/torch-compile-and-diffusers-a-hands-on-guide-to-peak-performance/",
      "label": "post 2",
      "type": "a"
    },
    {
      "href": "https://github.com/huggingface/lora-fast/blob/main/utils/fa3_processor.py",
      "label": "here",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/docs/diffusers/main/en/tutorials/using_peft_for_inference",
      "label": "hotswapping section of the documentation",
      "type": "a"
    },
    {
      "href": "https://github.com/pytorch/pytorch/issues/141548",
      "label": "issue thread",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/docs/diffusers/main/en/quantization/bitsandbytes",
      "label": "bitsandbytes",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/datasets/sayakpaul/sample-datasets/resolve/main/lora-fast/image_1_lora_fast.png",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/datasets/sayakpaul/sample-datasets/resolve/main/lora-fast/image_2_lora_fast.png",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://github.com/huggingface/peft/blob/92d65cafa51c829484ad3d95cf71d09de57ff066/src/peft/utils/hotswap.py",
      "label": "hotswap.py file in PEFT",
      "type": "a"
    },
    {
      "href": "https://github.com/ParagEkbote",
      "label": "Parag Ekbote",
      "type": "a"
    },
    {
      "href": "https://replicate.com/paragekbote/flux-fast-lora-hotswap",
      "label": "Replicate",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/blog/sdxl_lora_advanced_script",
      "label": "guide collaboration diffusers LoRA training scripts of the world, unite! 80 January 2, 2024",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/blog/peft-beyond-lora",
      "label": "peft lora guide Beyond LoRA: Can you beat the most popular fine-tuning technique? 105 June 18, 2026",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/yeonjoon-jung",
      "label": "yeonjoon-jung",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/noone7273",
      "label": "noone7273",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/join?next=%2Fblog%2Flora-fast",
      "label": "Sign up",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/nizda",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/grafit23",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/asmae-khald",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/tarekmasryo",
      "label": "",
      "type": "a"
    },
    {
      "href": "https://huggingface.co/thliang01",
      "label": "",
      "type": "a"
    }
  ],
  "repair_version": 2,
  "repaired_at": "2026-10-14T10:53:32Z",
  "source_url": "https://huggingface.co/blog/lora-fast",
  "papers": [],
  "actual_video_files": [],
  "body_chars": 14082,
  "expected_body_images": 22,
  "discovery_status": "ok",
  "delivery_status": "ok",
  "missing_reason": "",
  "raw_html": "attachments/cde2fe77d1be/pages/source.html",
  "local_html": "attachments/cde2fe77d1be/pages/article.html",
  "body_base_path": "attachments/cde2fe77d1be/pages/",
  "body_markdown_path": "attachments/cde2fe77d1be/pages/article.md"
}