You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
NameError: merge_quantization_configs in patch_merge_quantization_configs on Kaggle P100 #3130
Description
When importing Unsloth on Kaggle (Tesla P100), the dynamic patch in unsloth_zoo/temporary_patches/misc.py fails with a SyntaxError or NameError because it generates an invalid from transformers.quantizers.auto import () statement.
In a Kaggle notebook (Runtime GPU: Tesla P100), run:
python
import torch
from unsloth import FastLanguageModel
Observe the error:
text
File ".../unsloth_zoo/temporary_patches/misc.py", line 66, in patch_merge_quantization_configs
exec("from transformers.quantizers.auto import (" + ",".join(x for x in items if x in source) + ")", globals())
File "", line 1
from transformers.quantizers.auto import ()
^
SyntaxError: invalid syntax
Environment
Platform: Kaggle (GPU: Tesla P100)
Unsloth version: unsloth-2025.8.4
unsloth_zoo version: 2025.8.3
TRL version: 0.8.6
Transformers version: 4.55.0
PyTorch version: 2.6.0+cu124
python
Remove or redact any Hugging Face tokens before sharing
import torch
from unsloth import FastLanguageModel # Fails here
Expected Behavior
Unsloth should import normally; patch_merge_quantization_configs should be a no-op or guarded so an empty import isn’t executed.
Suggested Fix
Guard the dynamic import in misc.py:
I am testing it using !pip install --upgrade unsloth[colab-new] unsloth_zoo and seems like after importing Unsloth, there is no error appear.
Also I do not think Unsloth support P100 because Triton did not support Pascal generation (see this issue in Triton). You can use our notebook kaggle example here instead which uses the 2xT4 machines
Modified two system files to resolve CUDA 12.2 + MSVC 14.44 incompatibility:
Changed version check from 1940 to 1950
for me it was on line 162 in C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v12.2\include\crt\host_config.h
Changed CUDA version check from 12.4 to 12.2
Commented out the error --> (//_EMIT_STL_ERROR(STL1002, "Unexpected compiler version, expected CUDA 12.4 or newer.");)
for me it was on line 902 in C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.44.35207\include\yvals_core.h
Activity
Erland366 commentedon Aug 13, 2025
I am testing it using
!pip install --upgrade unsloth[colab-new] unsloth_zooand seems like after importing Unsloth, there is no error appear.Also I do not think Unsloth support P100 because Triton did not support Pascal generation (see this issue in Triton). You can use our notebook kaggle example here instead which uses the 2xT4 machines
Armysniper46 commentedon Mar 21, 2026
Modified two system files to resolve CUDA 12.2 + MSVC 14.44 incompatibility:
Changed version check from 1940 to 1950
for me it was on line 162 in C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v12.2\include\crt\host_config.h
Changed CUDA version check from 12.4 to 12.2
Commented out the error --> (//_EMIT_STL_ERROR(STL1002, "Unexpected compiler version, expected CUDA 12.4 or newer.");)
for me it was on line 902 in C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.44.35207\include\yvals_core.h
these fixed the issues when i ran "irm https://unsloth.ai/install.ps1 | iex"
currently im running it on tesla p100 16gb that only supported up to cuda 6.0 with nvidia grid driver(538.15) DCH and the chat works without any issues but i never tried the training
Diagnose torch and triton version skew at import time (#11023)
Diagnose torch and triton version skew at import time (unslothai#11023)