Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -23,8 +23,6 @@ import gradio as gr
|
|
23 |
import numpy as np
|
24 |
from PIL import Image
|
25 |
|
26 |
-
import cyper
|
27 |
-
|
28 |
DESCRIPTIONXX = """
|
29 |
## ⚡⚡⚡⚡ REALVISXL V5.0 BF16 (Tester C) ⚡⚡⚡⚡
|
30 |
"""
|
@@ -70,7 +68,6 @@ STYLE_NAMES = list(styles.keys())
|
|
70 |
|
71 |
MAX_SEED = np.iinfo(np.int32).max
|
72 |
|
73 |
-
code = r'''
|
74 |
import os
|
75 |
|
76 |
import torch
|
@@ -495,8 +492,7 @@ def generate_90(
|
|
495 |
os.symlink(sd_image_path, unique_name)
|
496 |
return [unique_name]
|
497 |
|
498 |
-
|
499 |
-
pyx = cyper.inline(code, openmp='-fopenmp-simd', fast_indexing=True, directives=dict(boundscheck=False, wraparound=False, infer_types=True, cdivision=True, language_level=3))
|
500 |
|
501 |
def load_predefined_images1():
|
502 |
predefined_images1 = [
|
@@ -620,7 +616,7 @@ with gr.Blocks(theme=gr.themes.Origin(),css=css) as demo:
|
|
620 |
run_button_30.click,
|
621 |
],
|
622 |
# api_name="generate", # Add this line
|
623 |
-
fn=
|
624 |
inputs=[
|
625 |
prompt,
|
626 |
negative_prompt,
|
@@ -640,7 +636,7 @@ with gr.Blocks(theme=gr.themes.Origin(),css=css) as demo:
|
|
640 |
run_button_60.click,
|
641 |
],
|
642 |
# api_name="generate", # Add this line
|
643 |
-
fn=
|
644 |
inputs=[
|
645 |
prompt,
|
646 |
negative_prompt,
|
@@ -660,7 +656,7 @@ with gr.Blocks(theme=gr.themes.Origin(),css=css) as demo:
|
|
660 |
run_button_90.click,
|
661 |
],
|
662 |
# api_name="generate", # Add this line
|
663 |
-
fn=
|
664 |
inputs=[
|
665 |
prompt,
|
666 |
negative_prompt,
|
|
|
23 |
import numpy as np
|
24 |
from PIL import Image
|
25 |
|
|
|
|
|
26 |
DESCRIPTIONXX = """
|
27 |
## ⚡⚡⚡⚡ REALVISXL V5.0 BF16 (Tester C) ⚡⚡⚡⚡
|
28 |
"""
|
|
|
68 |
|
69 |
MAX_SEED = np.iinfo(np.int32).max
|
70 |
|
|
|
71 |
import os
|
72 |
|
73 |
import torch
|
|
|
492 |
os.symlink(sd_image_path, unique_name)
|
493 |
return [unique_name]
|
494 |
|
495 |
+
infer_types=True, cdivision=True, language_level=3))
|
|
|
496 |
|
497 |
def load_predefined_images1():
|
498 |
predefined_images1 = [
|
|
|
616 |
run_button_30.click,
|
617 |
],
|
618 |
# api_name="generate", # Add this line
|
619 |
+
fn=generate_30,
|
620 |
inputs=[
|
621 |
prompt,
|
622 |
negative_prompt,
|
|
|
636 |
run_button_60.click,
|
637 |
],
|
638 |
# api_name="generate", # Add this line
|
639 |
+
fn=generate_60,
|
640 |
inputs=[
|
641 |
prompt,
|
642 |
negative_prompt,
|
|
|
656 |
run_button_90.click,
|
657 |
],
|
658 |
# api_name="generate", # Add this line
|
659 |
+
fn=generate_90,
|
660 |
inputs=[
|
661 |
prompt,
|
662 |
negative_prompt,
|