Skip to content

The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface. The fastest local inference engine in the world.

Some minor cleanups.

comfyanonymous7d2467e830ca
diff --git a/comfy/clip_vision.py b/comfy/clip_vision.py
index 20dc3345d..64392e270 100644
--- a/comfy/clip_vision.py
+++ b/comfy/clip_vision.py
@@ -109,8 +109,7 @@ def load_clipvision_from_sd(sd, prefix="", convert_keys=False):
keys = list(sd.keys())
for k in keys:
if k not in u:
- t = sd.pop(k)
- del t
+ sd.pop(k)
return clip
def load(ckpt_path):
diff --git a/comfy/float.py b/comfy/float.py
index 4a6ae6776..0c8f1d6cf 100644
--- a/comfy/float.py
+++ b/comfy/float.py
@@ -1,5 +1,4 @@
import torch
-import math
def calc_mantissa(abs_x, exponent, normal_mask, MANTISSA_BITS, EXPONENT_BIAS, generator=None):
mantissa_scaled = torch.where(
diff --git a/comfy/sd.py b/comfy/sd.py
index 3b4cff747..a494e531c 100644
--- a/comfy/sd.py
+++ b/comfy/sd.py
@@ -29,7 +29,6 @@ import comfy.text_encoders.long_clipl
import comfy.model_patcher
import comfy.lora
import comfy.t2i_adapter.adapter
-import comfy.supported_models_base
import comfy.taesd.taesd
def load_lora_for_models(model, clip, lora, strength_model, strength_clip):