JadenFK commited on
Commit
d5684d7
2 Parent(s): 7c89716 ec60320

Merge branch 'main' of https://huggingface.co/spaces/baulab/Erasing-Concepts-In-Diffusion into main

Browse files
app.py CHANGED
@@ -5,11 +5,19 @@ from StableDiffuser import StableDiffuser
5
  from tqdm import tqdm
6
  from train import train
7
 
8
- model_map = {'Car' : 'models/car.pt',
9
- 'Van Gogh' : 'models/vangogh.pt',
 
 
 
 
 
 
10
  'Kilian Eng' : 'models/kilianeng.pt',
11
  'Thomas Kinkade' : 'models/thomaskinkade.pt',
12
- 'Tyler Edlin' : 'models/tyleredlin.pt'}
 
 
13
 
14
 
15
  class Demo:
@@ -185,7 +193,7 @@ class Demo:
185
 
186
  model_map['Custom'] = save_path
187
 
188
- return [gr.update(interactive=True, value='Train'), gr.update(value='Done Training'), save_path, gr.Dropdown.update(choices=list(model_map.keys()), value='Custom')]
189
 
190
 
191
  def inference(self, prompt, seed, model_name, pbar = gr.Progress(track_tqdm=True)):
 
5
  from tqdm import tqdm
6
  from train import train
7
 
8
+ #import os
9
+ #os.system("nvidia-smi topo -m")
10
+
11
+ model_map = {'Van Gogh' : 'models/vangogh.pt',
12
+ 'Pablo Picasso': 'models/pablopicasso.pt',
13
+ 'Car' : 'models/car.pt',
14
+ 'Garbage Truck': 'models/garbagetruck.pt',
15
+ 'French Horn': 'models/frenchhorn.pt',
16
  'Kilian Eng' : 'models/kilianeng.pt',
17
  'Thomas Kinkade' : 'models/thomaskinkade.pt',
18
+ 'Tyler Edlin' : 'models/tyleredlin.pt',
19
+ 'Kelly McKernan': 'models/kellymckernan.pt',
20
+ 'Rembrandt': 'models/rembrandt.pt' }
21
 
22
 
23
  class Demo:
 
193
 
194
  model_map['Custom'] = save_path
195
 
196
+ return [gr.update(interactive=True, value='Train'), gr.update(value='Done Training! \n Try your custom model in the "Test" tab'), save_path, gr.Dropdown.update(choices=list(model_map.keys()), value='Custom')]
197
 
198
 
199
  def inference(self, prompt, seed, model_name, pbar = gr.Progress(track_tqdm=True)):
models/frenchhorn.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:48dc787885e54bbad818b57205ccb39796051b07b98a00b43776fb7d7e375fc0
3
+ size 3438372469
models/garbagetruck.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9e8bc8d2d973e941a16a03cae81113b5f5da07245888dd29934ea77af9242aba
3
+ size 3438373845
models/kellymckernan.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:dee79125ec560c09fcd8820f2df9e3bee94b8a8e8ef3c8e9b330a80ec87cf45e
3
+ size 175879857
models/pablopicasso.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2988ba3a00af8e7796fdd459d31c63e45470d5b00b88fa0a18f1722c8c55fd9a
3
+ size 175879775
models/rembrandt.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b95b9bd8d13f2cd8fc389ec2ec6246a3da334cc0c09cba323a3743ae2453cf58
3
+ size 175879529