Skip to content

Local UI to run and train LLMs and diffusion models. Supports GGUF, MLX, Qwen3.8, DeepSeek-V4.1, MiniMax-H3, Gemma 4, FLUX and more.

Update flex_attention.py

Daniel Han92c99ce97c06
diff --git a/unsloth/kernels/flex_attention.py b/unsloth/kernels/flex_attention.py
index 678574928c5..99e46a904c1 100644
--- a/unsloth/kernels/flex_attention.py
+++ b/unsloth/kernels/flex_attention.py
@@ -44,7 +44,7 @@ if not HAS_FLEX_ATTENTION:
try:
disable_compiled_autograd = torch._dynamo.compiled_autograd.disable
except:
- disable_compiled_autograd = lambda *args, **kwargs: *args, **kwargs
+ disable_compiled_autograd = lambda f: f
pass
# Logit softcapping