Spaces:
Runtime error
Runtime error
Commit
Β·
9bf51b3
1
Parent(s):
9c5f777
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,5 +1,7 @@
|
|
| 1 |
#@title Prepare the Concepts Library to be used
|
| 2 |
|
|
|
|
|
|
|
| 3 |
|
| 4 |
import requests
|
| 5 |
import os
|
|
@@ -29,10 +31,7 @@ my_token = os.environ['api_key']
|
|
| 29 |
pipe = StableDiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-2", revision="fp16", torch_dtype=torch.float16, use_auth_token=my_token).to("cuda")
|
| 30 |
|
| 31 |
def check_prompt(prompt):
|
| 32 |
-
SPAM_WORDS = [
|
| 33 |
-
"seductive",
|
| 34 |
-
"breast"
|
| 35 |
-
]
|
| 36 |
for spam_word in SPAM_WORDS:
|
| 37 |
if spam_word in prompt:
|
| 38 |
return False
|
|
|
|
| 1 |
#@title Prepare the Concepts Library to be used
|
| 2 |
|
| 3 |
+
# Deployment Log ---------------------------
|
| 4 |
+
# added beta 4305ed7
|
| 5 |
|
| 6 |
import requests
|
| 7 |
import os
|
|
|
|
| 31 |
pipe = StableDiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-2", revision="fp16", torch_dtype=torch.float16, use_auth_token=my_token).to("cuda")
|
| 32 |
|
| 33 |
def check_prompt(prompt):
|
| 34 |
+
SPAM_WORDS = [] # phasing this out
|
|
|
|
|
|
|
|
|
|
| 35 |
for spam_word in SPAM_WORDS:
|
| 36 |
if spam_word in prompt:
|
| 37 |
return False
|