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.
Python agentaichatgptdeepseekfine-tuninggemmaimage-generationllamallmllmsopenaipythonqwenreinforcement-learningself-hostedstable-diffusiontext-to-speechttsuiunsloth
Update _utils.py
Daniel Hanc92ef07ab7ff
diff --git a/unsloth/models/_utils.py b/unsloth/models/_utils.pyindex af423d560fc..b062bc2d49c 100644--- a/unsloth/models/_utils.py+++ b/unsloth/models/_utils.py@@ -184,7 +184,7 @@ except:# Patch get_model_param_count to record correct 4bit / 8bitfrom transformers.trainer_pt_utils import is_deepspeed_zero3_enabled-def get_model_param_count(model, trainable_only=False):+def get_model_param_count(model, trainable_only = False):"""Calculate model's total param count. If trainable_only is True then count only those requiring grads"""@@ -208,6 +208,8 @@ def get_model_param_count(model, trainable_only=False):passimport transformers.trainer_pt_utilstransformers.trainer_pt_utils.get_model_param_count = get_model_param_count+import transformers.trainer+transformers.trainer.get_model_param_count = get_model_param_count# =============================================# =============================================