Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
ComfyUI
Commits
11e3221f
"...composable_kernel_onnx.git" did not exist on "968bd93285318f0e43319d4c2a27c352a458ddd3"
Commit
11e3221f
authored
Feb 17, 2024
by
comfyanonymous
Browse files
fp8 weight support for Stable Cascade.
parent
f8706546
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
comfy/ldm/cascade/common.py
comfy/ldm/cascade/common.py
+1
-1
No files found.
comfy/ldm/cascade/common.py
View file @
11e3221f
...
@@ -84,7 +84,7 @@ class GlobalResponseNorm(nn.Module):
...
@@ -84,7 +84,7 @@ class GlobalResponseNorm(nn.Module):
def
forward
(
self
,
x
):
def
forward
(
self
,
x
):
Gx
=
torch
.
norm
(
x
,
p
=
2
,
dim
=
(
1
,
2
),
keepdim
=
True
)
Gx
=
torch
.
norm
(
x
,
p
=
2
,
dim
=
(
1
,
2
),
keepdim
=
True
)
Nx
=
Gx
/
(
Gx
.
mean
(
dim
=-
1
,
keepdim
=
True
)
+
1e-6
)
Nx
=
Gx
/
(
Gx
.
mean
(
dim
=-
1
,
keepdim
=
True
)
+
1e-6
)
return
self
.
gamma
.
to
(
x
.
device
)
*
(
x
*
Nx
)
+
self
.
beta
.
to
(
x
.
devic
e
)
+
x
return
self
.
gamma
.
to
(
device
=
x
.
device
,
dtype
=
x
.
dtype
)
*
(
x
*
Nx
)
+
self
.
beta
.
to
(
device
=
x
.
device
,
dtype
=
x
.
dtyp
e
)
+
x
class
ResBlock
(
nn
.
Module
):
class
ResBlock
(
nn
.
Module
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment