From 67caa2123108824bf12ec9aefec9c67d59b0b42f Mon Sep 17 00:00:00 2001 From: Datta Nimmaturi Date: Tue, 6 Jan 2026 09:53:20 +0000 Subject: [PATCH] Disable stats when modelscope is being used --- unsloth/models/_utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/unsloth/models/_utils.py b/unsloth/models/_utils.py index b38c5860b3..a2e1d78012 100644 --- a/unsloth/models/_utils.py +++ b/unsloth/models/_utils.py @@ -1197,7 +1197,8 @@ def get_statistics(local_files_only = False): # You can disable this by setting UNSLOTH_DISABLE_STATISTICS import os - if "UNSLOTH_DISABLE_STATISTICS" in os.environ: + global USE_MODELSCOPE + if "UNSLOTH_DISABLE_STATISTICS" in os.environ or USE_MODELSCOPE: return if local_files_only: return