From 1ddf512fdc69bf8dfb51eb858d3e5ba069570791 Mon Sep 17 00:00:00 2001 From: comfyanonymous Date: Wed, 12 Jun 2024 01:07:58 -0400 Subject: [PATCH] Don't auto convert clip and vae weights to fp16 when saving checkpoint. --- comfy/model_base.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/comfy/model_base.py b/comfy/model_base.py index 7ef03440..21f884ba 100644 --- a/comfy/model_base.py +++ b/comfy/model_base.py @@ -207,9 +207,6 @@ class BaseModel(torch.nn.Module): unet_state_dict = self.diffusion_model.state_dict() unet_state_dict = self.model_config.process_unet_state_dict_for_saving(unet_state_dict) - if self.get_dtype() == torch.float16: - extra_sds = map(lambda sd: utils.convert_sd_to(sd, torch.float16), extra_sds) - if self.model_type == ModelType.V_PREDICTION: unet_state_dict["v_pred"] = torch.tensor([])