Jonny001 commited on
Commit
4fb21b0
1 Parent(s): baf2123

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -16
app.py CHANGED
@@ -5,28 +5,14 @@ import os
5
  # model = gr.load("models/prithivMLmods/SD3.5-Turbo-Realism-2.0-LoRA") # <-- This model is also working
6
  model = gr.load("models/Purz/face-projection")
7
 
8
-
9
- default_negative_prompt = (
10
- "Extra limbs, Extra fingers or toes, Disfigured face, Distorted hands, Mutated body parts, "
11
- "Missing limbs, Asymmetrical features, Blurry face, Poor anatomy, Incorrect proportions, Crooked eyes, "
12
- "Deformed hands or fingers, Double face, Unrealistic skin texture, Overly smooth skin, Poor lighting, "
13
- "Cartoonish appearance, Plastic look, Grainy, Unnatural expressions, Crossed eyes, Mutated clothing, "
14
- "Artifacts, Uncanny valley, Doll-like features, Bad symmetry, Uneven skin tones, Extra teeth, "
15
- "Unrealistic hair texture, Dark shadows on face, Overexposed face, Cluttered background, Text, watermark, "
16
- "or signature, Over-processed, Low quality, Blurry, Low resolution, Pixelated, Oversaturated, Too dark, Overexposed, Poor lighting, "
17
- "Unclear, Text or watermark, Distorted faces, Extra limbs or fingers, Disfigured, Grainy, Overly stylized, Cartoonish, "
18
- "Unrealistic anatomy, Bad proportions, Unrealistic colors, Artificial look, Background noise, Unwanted objects, Repetitive patterns, Artifacting, Abstract shapes, Out of focus"
19
- )
20
-
21
- def generate_image(text, seed, width, height, guidance_scale, num_inference_steps, negative_prompt=default_negative_prompt):
22
  if seed is not None:
23
  random.seed(seed)
24
 
25
  if text in [example[0] for example in examples]:
26
  print(f"Using example: {text}")
27
 
28
-
29
- result_image = model(text, negative_prompt=negative_prompt)
30
 
31
  print(f"Width: {width}, Height: {height}, Guidance Scale: {guidance_scale}, Inference Steps: {num_inference_steps}")
32
 
 
5
  # model = gr.load("models/prithivMLmods/SD3.5-Turbo-Realism-2.0-LoRA") # <-- This model is also working
6
  model = gr.load("models/Purz/face-projection")
7
 
8
+ def generate_image(text, seed, width, height, guidance_scale, num_inference_steps):
 
 
 
 
 
 
 
 
 
 
 
 
 
9
  if seed is not None:
10
  random.seed(seed)
11
 
12
  if text in [example[0] for example in examples]:
13
  print(f"Using example: {text}")
14
 
15
+ result_image = model(text)
 
16
 
17
  print(f"Width: {width}, Height: {height}, Guidance Scale: {guidance_scale}, Inference Steps: {num_inference_steps}")
18