Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
S
stable-diffusion-webui
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
stable-diffusion-webui
Commits
3daf9cac
Commit
3daf9cac
authored
Sep 14, 2022
by
Elias Oenal
Committed by
AUTOMATIC1111
Sep 14, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed stray references to shared.device_codeformer.
parent
26f733a0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
+2
-4
codeformer_model.py
modules/codeformer_model.py
+2
-4
No files found.
modules/codeformer_model.py
View file @
3daf9cac
...
...
@@ -47,13 +47,11 @@ def setup_codeformer():
def
__init__
(
self
):
self
.
net
=
None
self
.
face_helper
=
None
if
shared
.
device
.
type
==
'mps'
:
# CodeFormer currently does not support mps backend
shared
.
device_codeformer
=
torch
.
device
(
'cpu'
)
def
create_models
(
self
):
if
self
.
net
is
not
None
and
self
.
face_helper
is
not
None
:
self
.
net
.
to
(
shared
.
device_codeformer
)
self
.
net
.
to
(
devices
.
device_codeformer
)
return
self
.
net
,
self
.
face_helper
net
=
net_class
(
dim_embd
=
512
,
codebook_size
=
1024
,
n_head
=
8
,
n_layers
=
9
,
connect_list
=
[
'32'
,
'64'
,
'128'
,
'256'
])
.
to
(
devices
.
device_codeformer
)
...
...
@@ -66,7 +64,7 @@ def setup_codeformer():
self
.
net
=
net
self
.
face_helper
=
face_helper
self
.
net
.
to
(
shared
.
device_codeformer
)
self
.
net
.
to
(
devices
.
device_codeformer
)
return
net
,
face_helper
...
...
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