The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface. The fastest local inference engine in the world.
cascade: remove dead weight init code (#13026)
rattuscad24ce26278
diff --git a/comfy/ldm/cascade/stage_a.py b/comfy/ldm/cascade/stage_a.pyindex 145e6e69a..e4e30cacd 100644--- a/comfy/ldm/cascade/stage_a.py+++ b/comfy/ldm/cascade/stage_a.py@@ -136,16 +136,7 @@ class ResBlock(nn.Module):ops.Linear(c_hidden, c),)- self.gammas = nn.Parameter(torch.zeros(6), requires_grad=True)-- # Init weights- def _basic_init(module):- if isinstance(module, nn.Linear) or isinstance(module, nn.Conv2d):- torch.nn.init.xavier_uniform_(module.weight)- if module.bias is not None:- nn.init.constant_(module.bias, 0)-- self.apply(_basic_init)+ self.gammas = nn.Parameter(torch.zeros(6), requires_grad=False)def _norm(self, x, norm):return norm(x.permute(0, 2, 3, 1)).permute(0, 3, 1, 2)