animeartstudio Sam Watson commited on
Commit
81ca520
β€’
0 Parent(s):

Duplicate from pulpapps/Diffusion30-ArtModels

Browse files

Co-authored-by: Sam Watson <pulpapps@users.noreply.huggingface.co>

Files changed (3) hide show
  1. .gitattributes +34 -0
  2. README.md +13 -0
  3. app.py +130 -0
.gitattributes ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
5
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
12
+ *.model filter=lfs diff=lfs merge=lfs -text
13
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
14
+ *.npy filter=lfs diff=lfs merge=lfs -text
15
+ *.npz filter=lfs diff=lfs merge=lfs -text
16
+ *.onnx filter=lfs diff=lfs merge=lfs -text
17
+ *.ot filter=lfs diff=lfs merge=lfs -text
18
+ *.parquet filter=lfs diff=lfs merge=lfs -text
19
+ *.pb filter=lfs diff=lfs merge=lfs -text
20
+ *.pickle filter=lfs diff=lfs merge=lfs -text
21
+ *.pkl filter=lfs diff=lfs merge=lfs -text
22
+ *.pt filter=lfs diff=lfs merge=lfs -text
23
+ *.pth filter=lfs diff=lfs merge=lfs -text
24
+ *.rar filter=lfs diff=lfs merge=lfs -text
25
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
26
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
27
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
28
+ *.tflite filter=lfs diff=lfs merge=lfs -text
29
+ *.tgz filter=lfs diff=lfs merge=lfs -text
30
+ *.wasm filter=lfs diff=lfs merge=lfs -text
31
+ *.xz filter=lfs diff=lfs merge=lfs -text
32
+ *.zip filter=lfs diff=lfs merge=lfs -text
33
+ *.zst filter=lfs diff=lfs merge=lfs -text
34
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ title: Maximum Multiplier
3
+ emoji: πŸ›•πŸ›•
4
+ colorFrom: green
5
+ colorTo: blue
6
+ sdk: gradio
7
+ sdk_version: 3.15.0
8
+ app_file: app.py
9
+ pinned: true
10
+ duplicated_from: pulpapps/Diffusion30-ArtModels
11
+ ---
12
+
13
+ Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
app.py ADDED
@@ -0,0 +1,130 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+ import os
3
+ import sys
4
+ from pathlib import Path
5
+
6
+ models = [
7
+ {"name": "Anything Midjourney 4.1", "url": "Joeythemonster/anything-midjourney-v-4-1"},
8
+ {"name": "Chaos and Order", "url": "Guizmus/SDArt_ChaosAndOrder768"},
9
+ {"name": "Chilloutclara", "url": "Fred99774/chilloutvlara"},
10
+ {"name": "Comic Diffusion", "url": "ogkalu/Comic-Diffusion"},
11
+ {"name": "Cosmic Horros 768", "url": "Guizmus/SDArt_cosmichorrors768"},
12
+ {"name": "Cosmic Horros", "url": "Guizmus/SDArt_cosmichorrors"},
13
+ {"name": "DGSpitzer", "url": "DGSpitzer/DGSpitzer-Art-Diffusion"},
14
+ {"name": "Dungeons and Diffusion", "url": "0xJustin/Dungeons-and-Diffusion"},
15
+ {"name": "Elden Ring", "url": "nitrosocke/elden-ring-diffusion"},
16
+ {"name": "Epic Diffusion 1.1", "url": "johnslegers/epic-diffusion-v1.1"},
17
+ {"name": "Epic Diffusion", "url": "johnslegers/epic-diffusion"},
18
+ {"name": "EpicMix Realism", "url": "Duskfallcrew/EpicMix_Realism"},
19
+ {"name": "Fantasy Mix", "url": "theintuitiveye/FantasyMix"},
20
+ {"name": "Girl New 1", "url": "Fred99774/girlnew1"},
21
+ {"name": "Lit 6B", "url": "hakurei/lit-6B"},
22
+ {"name": "Luna Diffusion", "url": "proximasanfinetuning/luna-diffusion"},
23
+ {"name": "Midjourney 4.0", "url": "flax/midjourney-v4-diffusion"},
24
+ {"name": "Midjourney 4.1", "url": "Joeythemonster/anything-midjourney-v-4-1"},
25
+ {"name": "Mo-Di Diffusion", "url": "nitrosocke/mo-di-diffusion"},
26
+ {"name": "Nitro Diffusion", "url": "nitrosocke/Nitro-Diffusion"},
27
+ {"name": "Openjourney V2", "url": "prompthero/openjourney-v2"},
28
+ {"name": "Openjourney", "url": "prompthero/openjourney"},
29
+ {"name": "Seek Art Mega", "url": "coreco/seek.art_MEGA"},
30
+ {"name": "Something", "url": "Guizmus/SDArt_something"},
31
+ {"name": "Spider Verse diffusion", "url": "nitrosocke/spider-verse-diffusion"},
32
+ {"name": "Vintedois 1.0", "url": "22h/vintedois-diffusion-v0-1"},
33
+ {"name": "Vintedois 2.0", "url": "22h/vintedois-diffusion-v0-2"},
34
+ {"name": "❀ ART STYLES ==========", "url": "joachimsallstrom/Double-Exposure-Diffusion"},
35
+ {"name": "Balloon Art", "url": "Fictiverse/Stable_Diffusion_BalloonArt_Model"},
36
+ {"name": "Double Exposure Diffusion", "url": "joachimsallstrom/Double-Exposure-Diffusion"},
37
+ {"name": "Fluid Art", "url": "Fictiverse/Stable_Diffusion_FluidArt_Model"},
38
+ {"name": "GTA5 Artwork Diffusion", "url": "ItsJayQz/GTA5_Artwork_Diffusion"},
39
+ {"name": "Marvel WhatIf Diffusion", "url": "ItsJayQz/Marvel_WhatIf_Diffusion"},
40
+ {"name": "Naruto Diffuser", "url": "lambdalabs/sd-naruto-diffusers"},
41
+ {"name": "Papercut", "url": "Fictiverse/Stable_Diffusion_PaperCut_Model"},
42
+ {"name": "Pokemon Diffuser", "url": "lambdalabs/sd-pokemon-diffusers"},
43
+ {"name": "Synthwave Punk 2", "url": "ItsJayQz/SynthwavePunk-v2"},
44
+ {"name": "Valorant Diffusion", "url": "ItsJayQz/Valorant_Diffusion"},
45
+ {"name": "Van Gogh Diffusion", "url": "dallinmackay/Van-Gogh-diffusion"},
46
+ {"name": "Vectorartz Diffusion", "url": "coder119/Vectorartz_Diffusion"},
47
+ {"name": "VoxelArt", "url": "Fictiverse/Stable_Diffusion_VoxelArt_Model"},
48
+ ]
49
+
50
+ current_model = models[0]
51
+
52
+ text_gen = gr.Interface.load("spaces/daspartho/prompt-extend")
53
+
54
+ models2 = []
55
+ for model in models:
56
+ model_url = f"models/{model['url']}"
57
+ loaded_model = gr.Interface.load(model_url, live=True, preprocess=True)
58
+ models2.append(loaded_model)
59
+
60
+
61
+ def text_it(inputs, text_gen=text_gen):
62
+ return text_gen(inputs)
63
+
64
+
65
+ def set_model(current_model_index):
66
+ global current_model
67
+ current_model = models[current_model_index]
68
+ return gr.update(value=f"{current_model['name']}")
69
+
70
+
71
+ def send_it(inputs, model_choice):
72
+ proc = models2[model_choice]
73
+ return proc(inputs)
74
+
75
+
76
+ with gr.Blocks() as myface:
77
+ gr.HTML(
78
+
79
+ )
80
+
81
+ with gr.Row():
82
+ with gr.Row():
83
+ input_text = gr.Textbox(label="Prompt idea", placeholder="Eg. Fantasy sunrise, serene", lines=1)
84
+ # Model selection dropdown
85
+ model_name1 = gr.Dropdown(
86
+ label="Choose Model",
87
+ choices=[m["name"] for m in models],
88
+ type="index",
89
+ value=current_model["name"],
90
+ interactive=True,
91
+ )
92
+ with gr.Row():
93
+ see_prompts = gr.Button("Generate Prompts")
94
+ run = gr.Button("Generate Images", variant="primary")
95
+
96
+ with gr.Row():
97
+ output1 = gr.Image(label="")
98
+ output2 = gr.Image(label="")
99
+ output3 = gr.Image(label="")
100
+ with gr.Row():
101
+ magic1 = gr.Textbox(label="Generated Prompt", lines=2)
102
+ magic2 = gr.Textbox(label="Generated Prompt", lines=2)
103
+ magic3 = gr.Textbox(label="Generated Prompt", lines=2)
104
+ with gr.Row():
105
+ output4 = gr.Image(label="")
106
+ output5 = gr.Image(label="")
107
+ output6 = gr.Image(label="")
108
+ with gr.Row():
109
+ magic4 = gr.Textbox(label="Generated Prompt", lines=2)
110
+ magic5 = gr.Textbox(label="Generated Prompt", lines=2)
111
+ magic6 = gr.Textbox(label="Generated Prompt", lines=2)
112
+
113
+ model_name1.change(set_model, inputs=model_name1, outputs=[output1, output2, output3, output4, output5, output6])
114
+
115
+ run.click(send_it, inputs=[magic1, model_name1], outputs=[output1])
116
+ run.click(send_it, inputs=[magic2, model_name1], outputs=[output2])
117
+ run.click(send_it, inputs=[magic3, model_name1], outputs=[output3])
118
+ run.click(send_it, inputs=[magic4, model_name1], outputs=[output4])
119
+ run.click(send_it, inputs=[magic5, model_name1], outputs=[output5])
120
+ run.click(send_it, inputs=[magic6, model_name1], outputs=[output6])
121
+
122
+ see_prompts.click(text_it, inputs=[input_text], outputs=[magic1])
123
+ see_prompts.click(text_it, inputs=[input_text], outputs=[magic2])
124
+ see_prompts.click(text_it, inputs=[input_text], outputs=[magic3])
125
+ see_prompts.click(text_it, inputs=[input_text], outputs=[magic4])
126
+ see_prompts.click(text_it, inputs=[input_text], outputs=[magic5])
127
+ see_prompts.click(text_it, inputs=[input_text], outputs=[magic6])
128
+
129
+ myface.queue(concurrency_count=200)
130
+ myface.launch(inline=True, show_api=False, max_threads=400)