From 38212cf4224ea561956db9ece829e859d55ce56f Mon Sep 17 00:00:00 2001 From: Daniel Han Date: Tue, 1 Jul 2025 02:47:17 -0700 Subject: [PATCH] Update vision.py --- unsloth/models/vision.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/unsloth/models/vision.py b/unsloth/models/vision.py index 525e562abb..39ff1fd2bb 100644 --- a/unsloth/models/vision.py +++ b/unsloth/models/vision.py @@ -366,7 +366,9 @@ class FastBaseModel: # Execute code as well if len(execute_code.strip()) != 0: exec(execute_code) - pass + else: + custom_datatype = None + correct_dtype = None pass # Stop SDPA for some archs like Pixtral / Mistral3