import gradio as gr import os import sys from pathlib import Path import random import string import time from queue import Queue from threading import Thread import emoji text_gen=gr.Interface.load("spaces/phenomenon1981/MagicPrompt-Stable-Diffusion") def get_prompts(prompt_text): if prompt_text: return text_gen(prompt_text + " Dream") else: return text_gen("") models = [ "Yntec/OpenLexica", "Yntec/MapleSyrup", ] current_model = models[0] models2=[ gr.Interface.load(f"models/{models[0]}",live=True,preprocess=False), gr.Interface.load(f"models/{models[1]}",live=True,preprocess=False), ] def text_it1(inputs,text_gen1=text_gen1): go_t1=text_gen1(inputs) return(go_t1) def set_model(current_model): current_model = models[current_model] return gr.update(label=(f"{current_model}")) def send_it1(inputs, model_choice): proc1=models2[model_choice] output1=proc1(inputs) return(output1) css="""""" with gr.Blocks(css='style.css') as demo: gr.HTML( """
PlaceHolder original space created by Phenomenon1981.
❤️ Press the Like Button if you enjoy my space! ❤️