From 7e911ee59fb7339cab11278e7775039beca78f96 Mon Sep 17 00:00:00 2001 From: rickard Date: Sat, 8 Jun 2024 18:42:02 +0200 Subject: [PATCH] clears any selected_adapters before calling internal_model.save_pretrained --- unsloth/save.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/unsloth/save.py b/unsloth/save.py index 5d6f925d45..e7ac4e5797 100644 --- a/unsloth/save.py +++ b/unsloth/save.py @@ -642,7 +642,8 @@ def unsloth_save_model( model.config = new_config # Save! - + + save_pretrained_settings["selected_adapters"] = None # Check if pushing to an organization if save_pretrained_settings["push_to_hub"] and (username != actual_username): print(f"Unsloth: Saving to organization with address {new_save_directory}")