Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -5,8 +5,6 @@ from diffusers.pipelines.stable_diffusion import StableDiffusionSafetyChecker
|
|
5 |
from diffusers import DiffusionPipeline
|
6 |
|
7 |
|
8 |
-
|
9 |
-
|
10 |
# model_id = "echarlaix/sdxl-turbo-openvino-int8"
|
11 |
# model_id = "echarlaix/LCM_Dreamshaper_v7-openvino"
|
12 |
|
@@ -15,13 +13,12 @@ from diffusers import DiffusionPipeline
|
|
15 |
model_id = "OpenVINO/LCM_Dreamshaper_v7-int8-ov"
|
16 |
#pipeline = OVLatentConsistencyModelPipeline.from_pretrained(model_id, compile=False, safety_checker=safety_checker)
|
17 |
pipeline = OVLatentConsistencyModelPipeline.from_pretrained(model_id, compile=False)
|
18 |
-
pipeline.load_tf_weights("EvilEngine/easynegative")
|
19 |
|
20 |
batch_size, num_images, height, width = 1, 1, 512, 512
|
21 |
pipeline.reshape(batch_size=batch_size, height=height, width=width, num_images_per_prompt=num_images)
|
22 |
pipeline.compile()
|
23 |
|
24 |
-
negative_prompt="easynegative"
|
25 |
|
26 |
def infer(prompt, num_inference_steps):
|
27 |
|
|
|
5 |
from diffusers import DiffusionPipeline
|
6 |
|
7 |
|
|
|
|
|
8 |
# model_id = "echarlaix/sdxl-turbo-openvino-int8"
|
9 |
# model_id = "echarlaix/LCM_Dreamshaper_v7-openvino"
|
10 |
|
|
|
13 |
model_id = "OpenVINO/LCM_Dreamshaper_v7-int8-ov"
|
14 |
#pipeline = OVLatentConsistencyModelPipeline.from_pretrained(model_id, compile=False, safety_checker=safety_checker)
|
15 |
pipeline = OVLatentConsistencyModelPipeline.from_pretrained(model_id, compile=False)
|
|
|
16 |
|
17 |
batch_size, num_images, height, width = 1, 1, 512, 512
|
18 |
pipeline.reshape(batch_size=batch_size, height=height, width=width, num_images_per_prompt=num_images)
|
19 |
pipeline.compile()
|
20 |
|
21 |
+
negative_prompt="easynegative,bad anatomy, bad hands, missing fingers, extra fingers, three hands, three legs, bad arms, missing legs, missing arms, poorly drawn face, bad face, fused face, cloned face, three crus, fused feet, fused thigh, extra crus, ugly fingers, horn, cartoon, cg, 3d, unreal, animate, amputation, disconnected limbs, nsfw, nude, censored, "
|
22 |
|
23 |
def infer(prompt, num_inference_steps):
|
24 |
|