Merge pull request #165 from AIrjen/model_mode

Model mode
This commit is contained in:
AIrjen
2024-02-20 20:22:55 +01:00
committed by GitHub
16 changed files with 266 additions and 56 deletions
+12 -7
View File
@@ -23,6 +23,7 @@ subjects =["all", "object", "animal", "humanoid", "landscape", "concept"]
genders = ["all", "male", "female"]
emojis = [False, True]
models = ["SD1.5", "SDXL", "Stable Cascade"]
subjects =["all"]
subjectsubtypesobject = ["all"]
subjectsubtypeshumanoid = ["all"]
@@ -229,6 +230,7 @@ class OneButtonPrompt:
"humanoids_gender": (genders, {"default": "all"}),
"subject_subtypes_concepts": (subjectsubtypesconcept, {"default": "all"}),
"emojis":(emojis, {"default": False}),
"base_model":(models, {"default": "SDXL"}),
"seed": ("INT", {"default": 0, "min": 0, "max": 0xFFFFFFFFFFFFFFFF}),
},
@@ -243,8 +245,8 @@ class OneButtonPrompt:
CATEGORY = "OneButtonPrompt"
def Comfy_OBP(self, insanitylevel, custom_subject, seed, artist, imagetype, subject, imagemodechance, humanoids_gender, subject_subtype_objects, subject_subtypes_humanoids, subject_subtypes_concepts, emojis, custom_outfit):
generatedpromptlist = build_dynamic_prompt(insanitylevel,subject,artist,imagetype,False,"","","",1,"",custom_subject,True,"",imagemodechance, humanoids_gender, subject_subtype_objects, subject_subtypes_humanoids, subject_subtypes_concepts, False, emojis, seed, custom_outfit, True)
def Comfy_OBP(self, insanitylevel, custom_subject, seed, artist, imagetype, subject, imagemodechance, humanoids_gender, subject_subtype_objects, subject_subtypes_humanoids, subject_subtypes_concepts, emojis, custom_outfit, base_model):
generatedpromptlist = build_dynamic_prompt(insanitylevel,subject,artist,imagetype,False,"","","",1,"",custom_subject,True,"",imagemodechance, humanoids_gender, subject_subtype_objects, subject_subtypes_humanoids, subject_subtypes_concepts, False, emojis, seed, custom_outfit, True, base_model)
#print(generatedprompt)
generatedprompt = generatedpromptlist[0]
prompt_g = generatedpromptlist[1]
@@ -451,7 +453,8 @@ class OneButtonPreset:
"required": {
"OneButtonPreset": (allpresets, {"default": "Standard"}),
},
"optional": {
"optional": {
"base_model":(models, {"default": "SDXL"}),
"seed": ("INT", {"default": 0, "min": 0, "max": 0xFFFFFFFFFFFFFFFF}),
},
}
@@ -466,7 +469,7 @@ class OneButtonPreset:
CATEGORY = "OneButtonPrompt"
def Comfy_OBP_OneButtonPreset(self, OneButtonPreset, seed):
def Comfy_OBP_OneButtonPreset(self, OneButtonPreset, seed, base_model):
# load the stuff
selected_opb_preset = OBPresets.get_obp_preset(OneButtonPreset)
@@ -505,7 +508,8 @@ class OneButtonPreset:
antivalues=antistring,
advancedprompting=False,
hardturnoffemojis=True,
seed=seed
seed=seed,
base_model=base_model,
)
@@ -541,6 +545,7 @@ class AutoNegativePrompt:
"max": 10, #Maximum value
"step": 1 #Slider's step
}),
"base_model":(models, {"default": "SDXL"}),
"seed": ("INT", {"default": 0, "min": 0, "max": 0xFFFFFFFFFFFFFFFF}),
},
@@ -555,8 +560,8 @@ class AutoNegativePrompt:
CATEGORY = "OneButtonPrompt"
def Comfy_OBP_AutoNegativePrompt(self, postive_prompt, insanitylevel, enhancenegative,base_negative, seed):
generatedprompt = build_dynamic_negative(postive_prompt, insanitylevel, enhancenegative, base_negative)
def Comfy_OBP_AutoNegativePrompt(self, postive_prompt, insanitylevel, enhancenegative,base_negative, seed, base_model):
generatedprompt = build_dynamic_negative(postive_prompt, insanitylevel, enhancenegative, base_negative, base_model=base_model)
print("Generated negative prompt: " + generatedprompt)
+102 -26
View File
@@ -10,7 +10,11 @@ from random_functions import *
# insanity level controls randomness of propmt 0-10
# forcesubject van be used to force a certain type of subject
# Set artistmode to none, to exclude artists
def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all", imagetype = "all", onlyartists = False, antivalues = "", prefixprompt = "", suffixprompt ="",promptcompounderlevel ="1", seperator = "comma", givensubject="",smartsubject = True,giventypeofimage="", imagemodechance = 20, gender = "all", subtypeobject="all", subtypehumanoid="all", subtypeconcept="all", advancedprompting=True, hardturnoffemojis=False, seed=-1, overrideoutfit="", prompt_g_and_l = False):
def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all", imagetype = "all", onlyartists = False, antivalues = "", prefixprompt = "", suffixprompt ="",promptcompounderlevel ="1", seperator = "comma", givensubject="",smartsubject = True,giventypeofimage="", imagemodechance = 20, gender = "all", subtypeobject="all", subtypehumanoid="all", subtypeconcept="all", advancedprompting=True, hardturnoffemojis=False, seed=-1, overrideoutfit="", prompt_g_and_l = False, base_model = "SD1.5"):
remove_weights = False
less_verbose = False
# set seed
# For use in ComfyUI (might bring to Automatic1111 as well)
@@ -45,6 +49,18 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
# clean up antivalue list:
antilist = [s.strip().lower() for s in antilist]
# Base model options, used to change things in prompt generation. Might be able to extend to different forms like animatediff as well?
base_model_options = ["SD1.5", "SDXL", "Stable Cascade"]
if base_model not in base_model_options:
base_model = "SD1.5" # Just in case there is no option here.
# "SD1.5" -- Standard, future: More original style prompting
# "SDXL" -- Standard (for now), future: More natural language
# "Stable Cascade" -- Remove weights
if(base_model == "Stable Cascade"):
remove_weights = True
if(base_model == "SD1.5"):
less_verbose = True
# Some tricks for gender to make sure we can choose Him/Her/It etc on the right time.
if(gender=="all"):
genderchoicelist = ["male", "female"]
@@ -90,7 +106,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
haircolorlist = csv_to_list("haircolors",antilist)
hairstylelist = csv_to_list("hairstyles",antilist)
hairvomitlist = csv_to_list("hairvomit",antilist,"./csvfiles/",0,"?",False,False)
humanactivitylist = csv_to_list("human_activities",antilist,"./csvfiles/",0,"?",False,False)
humanoidlist = csv_to_list("humanoids",antilist)
imagetypelist = csv_to_list(csvfilename="imagetypes",antilist=antilist, insanitylevel=insanitylevel)
joblist = csv_to_list(csvfilename="jobs",antilist=antilist,skipheader=True,gender=gender)
@@ -174,15 +190,23 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
humanlist = fictionallist + nonfictionallist + humanoidlist
objecttotallist = objectlist + buildinglist + vehiclelist + foodlist + spacelist + floralist + containerlist
outfitprinttotallist = objecttotallist + locationlist + colorlist + musicgenrelist + seasonlist + animallist + patternlist
humanactivitycheatinglist = ["OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
if(less_verbose):
humanactivitycheatinglist = ["-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)"]
else:
humanactivitycheatinglist = ["OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)",
"OR(;, -heshe- is;uncommon) -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)"]
humanactivitylist = humanactivitylist + humanactivitycheatinglist
# build artists list
if artists == "wild":
artists = "all (wild)"
@@ -270,19 +294,34 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
backgroundtypelist = csv_to_list("backgroundtypes", antilist,"./csvfiles/special_lists/",0,"?")
insideshotlist = csv_to_list("insideshots", antilist,"./csvfiles/special_lists/",0,"?")
photoadditionlist = csv_to_list("photoadditions", antilist,"./csvfiles/special_lists/",0,"?")
buildhairlist = csv_to_list("buildhair", antilist,"./csvfiles/special_lists/",0,"?")
buildoutfitlist = csv_to_list("buildoutfit", antilist,"./csvfiles/special_lists/",0,"?")
objectadditionslist = csv_to_list("objectadditions", antilist,"./csvfiles/special_lists/",0,"?")
humanadditionlist = csv_to_list("humanadditions", antilist,"./csvfiles/special_lists/",0,"?")
if(less_verbose):
buildhairlist = csv_to_list("buildhair_less_verbose", antilist,"./csvfiles/special_lists/",0,"?")
buildoutfitlist = csv_to_list("buildoutfit_less_verbose", antilist,"./csvfiles/special_lists/",0,"?")
humanadditionlist = csv_to_list("humanadditions_less_verbose", antilist,"./csvfiles/special_lists/",0,"?")
objectadditionslist = csv_to_list("objectadditions_less_verbose", antilist,"./csvfiles/special_lists/",0,"?")
buildfacelist = csv_to_list("buildface_less_verbose", antilist,"./csvfiles/special_lists/",0,"?")
buildaccessorielist = csv_to_list("buildaccessorie_less_verbose", antilist,"./csvfiles/special_lists/",0,"?")
humanactivitylist = csv_to_list("human_activities_less_verbose",antilist,"./csvfiles/",0,"?",False,False)
else:
buildhairlist = csv_to_list("buildhair", antilist,"./csvfiles/special_lists/",0,"?")
buildoutfitlist = csv_to_list("buildoutfit", antilist,"./csvfiles/special_lists/",0,"?")
humanadditionlist = csv_to_list("humanadditions", antilist,"./csvfiles/special_lists/",0,"?")
objectadditionslist = csv_to_list("objectadditions", antilist,"./csvfiles/special_lists/",0,"?")
buildfacelist = csv_to_list("buildface", antilist,"./csvfiles/special_lists/",0,"?")
buildaccessorielist = csv_to_list("buildaccessorie", antilist,"./csvfiles/special_lists/",0,"?")
humanactivitylist = csv_to_list("human_activities",antilist,"./csvfiles/",0,"?",False,False)
humanactivitylist = humanactivitylist + humanactivitycheatinglist
animaladditionlist = csv_to_list("animaladditions", antilist,"./csvfiles/special_lists/",0,"?")
buildaccessorielist = csv_to_list("buildaccessorie", antilist,"./csvfiles/special_lists/",0,"?")
minilocationadditionslist = csv_to_list("minilocationadditions", antilist,"./csvfiles/special_lists/",0,"?")
overalladditionlist = csv_to_list("overalladditions", antilist,"./csvfiles/special_lists/",0,"?")
imagetypemodelist = csv_to_list("imagetypemodes", antilist,"./csvfiles/special_lists/",0,"?")
miniactivitylist = csv_to_list("miniactivity", antilist,"./csvfiles/special_lists/",0,"?")
animalsuffixadditionlist = csv_to_list("animalsuffixadditions", antilist,"./csvfiles/special_lists/",0,"?")
buildfacepartlist = csv_to_list("buildfaceparts", antilist,"./csvfiles/special_lists/",0,"?")
buildfacelist = csv_to_list("buildface", antilist,"./csvfiles/special_lists/",0,"?")
tokinatorlist = csv_to_list("tokinator", antilist,"./csvfiles/templates/",0,"?")
styleslist = csv_to_list("styles", antilist,"./csvfiles/templates/",0,"?")
@@ -1456,7 +1495,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
completeprompt += " ["
while step < end:
if(normal_dist(insanitylevel)):
if(normal_dist(insanitylevel) and remove_weights == False):
isweighted = 1
if isweighted == 1:
@@ -1546,7 +1585,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
if(thetokinatormode == True):
tokinatorsubtype = ["personification", "human form", "object", "landscape", "OR(creature;beast;animal;myth;concept;world;planet)", "building", "location", "shape", "being", "-token-"]
if(chance_roll(insanitylevel,"normal")):
if(chance_roll(insanitylevel,"normal")):
if(chance_roll(insanitylevel,"normal") and remove_weights == False):
completeprompt += "(OR(;-imagetypequality-;uncommon) OR(-imagetype-;-othertype-;rare):1.3) "
else:
completeprompt += "OR(;-imagetypequality-;uncommon) OR(-imagetype-;-othertype-;rare) "
@@ -2063,28 +2102,51 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
# Common to have 1 description, uncommon to have 2
if(chance_roll(insanitylevel, subjectdescriptor1chance) and generatedescriptors == True):
if(subjectchooser in ["animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation","manwomanmultiple", "firstname"]):
if(random.randint(0,3) > 0):
if(less_verbose):
completeprompt += ", -humandescriptor- "
elif(random.randint(0,3) > 0):
completeprompt += ", OR(;-heshe- is;normal) OR(;very;rare) -humandescriptor- "
elif(subjectchooser == "manwomanmultiple"):
completeprompt += ", the -samehumansubject- are OR(;very;rare) -humandescriptor-"
else:
completeprompt += ", OR(the -manwoman-;-samehumansubject-) is OR(;very;rare) -humandescriptor-"
elif(mainchooser == "landscape"):
completeprompt += ", OR(;-heshe- is;normal) OR(;very;rare) -locationdescriptor- "
if(less_verbose):
completeprompt += ", -locationdescriptor- "
else:
completeprompt += ", OR(;-heshe- is;normal) OR(;very;rare) -locationdescriptor- "
elif(mainchooser == "animal"):
completeprompt += ", OR(;-heshe- is;normal) OR(;very;rare) -animaldescriptor- "
if(less_verbose):
completeprompt += ", -animaldescriptor- "
else:
completeprompt += ", OR(;-heshe- is;normal) OR(;very;rare) -animaldescriptor- "
else:
completeprompt += ", OR(;-heshe- is;normal) OR(;very;rare) -descriptor- "
if(less_verbose):
completeprompt += ", -descriptor- "
else:
completeprompt += ", OR(;-heshe- is;normal) OR(;very;rare) -descriptor- "
if(chance_roll(insanitylevel, subjectdescriptor2chance) and generatedescriptors == True):
if(subjectchooser in ["animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation","manwomanmultiple","firstname"]):
completeprompt += " and -humandescriptor- "
if(less_verbose):
completeprompt += ", -humandescriptor- "
else:
completeprompt += " and -humandescriptor- "
elif(mainchooser == "landscape"):
completeprompt += " and -locationdescriptor- "
if(less_verbose):
completeprompt += ", -locationdescriptor- "
else:
completeprompt += " and -locationdescriptor- "
elif(mainchooser == "animal"):
completeprompt += " and -animaldescriptor- "
if(less_verbose):
completeprompt += ", -animaldescriptor- "
else:
completeprompt += " and -animaldescriptor- "
else:
completeprompt += " and -descriptor- "
if(less_verbose):
completeprompt += ", -descriptor- "
else:
completeprompt += " and -descriptor- "
completeprompt += ", "
if(thetokinatormode == False):
@@ -2274,7 +2336,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
completeprompt += " ["
while step < end:
if(normal_dist(insanitylevel)):
if(normal_dist(insanitylevel) and remove_weights == False):
isweighted = 1
if isweighted == 1:
@@ -2600,7 +2662,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
completeprompt += " ["
while step < end:
if(normal_dist(insanitylevel)):
if(normal_dist(insanitylevel) and remove_weights == False):
isweighted = 1
if isweighted == 1:
@@ -2984,7 +3046,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all
matches = re.findall(pattern, givensubject)
if(len(completeprompt) > 325 and matches == []):
if(len(completeprompt) > 325 and matches == [] and remove_weights == False):
if(len(completeprompt) < 375):
strenght = "1.1"
elif(len(completeprompt) < 450):
@@ -3863,12 +3925,23 @@ def replacewildcard(completeprompt, insanitylevel, wildcard,listname, activatehy
return completeprompt
def build_dynamic_negative(positive_prompt = "", insanitylevel = 0, enhance = False, existing_negative_prompt = ""):
def build_dynamic_negative(positive_prompt = "", insanitylevel = 0, enhance = False, existing_negative_prompt = "", base_model="SD1.5"):
negative_primer = []
negative_result = []
all_negative_words_list = []
remove_weights = False
# Base model options, used to change things in prompt generation. Might be able to extend to different forms like animatediff as well?
base_model_options = ["SD1.5", "SDXL", "Stable Cascade"]
if base_model not in base_model_options:
base_model = "SD1.5" # Just in case there is no option here.
# "SD1.5" -- Standard, future: More original style prompting
# "SDXL" -- Standard (for now), future: More natural language
# "Stable Cascade" -- Remove weights
if base_model == "Stable Cascade":
remove_weights = True
# negavite_primer, all words that should trigger a negative result
# the negative words to put in the negative prompt
@@ -3937,7 +4010,7 @@ def build_dynamic_negative(positive_prompt = "", insanitylevel = 0, enhance = Fa
# Convert the list to unique values or (word:count) format
unique_words = []
for word, count in word_count.items():
if(count > 2):
if(count > 2 and remove_weights == False):
#counttotal = int(count/2)
counttotal = count
if(counttotal > 3):
@@ -4070,6 +4143,8 @@ def cleanup(completeprompt, advancedprompting, insanitylevel = 5):
completeprompt = re.sub(', ,', ',', completeprompt)
completeprompt = re.sub(' , ', ', ', completeprompt)
completeprompt = re.sub(' ,', ',', completeprompt)
completeprompt = re.sub(' ,', ',', completeprompt)
completeprompt = re.sub(' ,', ',', completeprompt)
completeprompt = re.sub(',\(', ', (', completeprompt)
while " " in completeprompt:
@@ -4170,6 +4245,7 @@ def custom_or(values, insanitylevel = 5):
return selected_value
def parse_custom_functions(completeprompt, insanitylevel = 5):
#print(completeprompt)
# Regular expression pattern to match 'or()' function calls and their arguments
ORpattern = r'OR\((.*?)\)'
@@ -0,0 +1,61 @@
Walking
Running
Jumping
Laying down
Swimming
Dancing
Frolicking
OR(Painting a painting;Drawing a drawing)
Singing
Writing
Cooking
Reading
Hiking
Camping
Fishing
Hunting
Making photographs
OR(Sculpting;Knitting;Sewing;Quilting;Woodworking;Blacksmithing;Metalworking;Pottery;Glassblowing)
Playing video games
Watching OR(movies;TV shows;cinema)
Playing OR(board games;card games;chess;poker;trivia games;word games)
Doing puzzles
Collecting OR(stamps;coins;art;antiques)
OR(Playing a musical instrument;Composing music;Producing music;DJing)
Singing in a choir
Playing in a OR(band;orchestra)
OR(Blogging;Vlogging;Podcasting)
Speaking in public
OR(Stand-up;Improvisational) comedy
OR(Acting in;Directing;Producing) a OR(play;movie;TV show)
OR(Teaching;Coaching;Mentoring;Tutoring)
OR(Fundraising;Campaigning for a cause;Activism;Participating in a protest)
OR(Gardening;Landscaping)
Home improvement
Cleaning
OR(Organizing;Planning events;Hosting parties)
Attending OR(concerts;festivals;theater performances;movies;sports events)
OR(Exercising;Going to the gym;Fitnessing)
OR(Yoga;Pilates;Tai chi)
Meditating
OR(Scuba diving;Snorkeling;Kayaking;Canoeing;Rafting;Climbing;Bungee jumping;Skydiving;Paragliding;Hang gliding;Zip lining)
OR(Traveling;Exploring new places)
Playing OR(Tennis;Basketball;Soccer;Football;Golf;Baseball;Hockey;Icehockey;Volleyball;Beach Volleyball;Sports)
OR(Boxing;Wrestling;Doing Martial Arts;Gymnastics;Cycling;Surfing;Skateboarding;Snowboarding;Skiing;Figure Skating;Rowing;Sailing;Cycling;Mountain biking)
Diving
Playing
Horse-back riding
-animal--back riding
having a tea party
Lounging
Bathing in a -waterlocation-
drinking coffee in a cafe
studying in a room
doing a fashion show
fighting a War
sieging a Castle
sitting and talking
Walking up a stairs
Walking down a stairs
Walking down a OR(street;-minilocation-)
casting a -element- magic spell
1 Walking
2 Running
3 Jumping
4 Laying down
5 Swimming
6 Dancing
7 Frolicking
8 OR(Painting a painting;Drawing a drawing)
9 Singing
10 Writing
11 Cooking
12 Reading
13 Hiking
14 Camping
15 Fishing
16 Hunting
17 Making photographs
18 OR(Sculpting;Knitting;Sewing;Quilting;Woodworking;Blacksmithing;Metalworking;Pottery;Glassblowing)
19 Playing video games
20 Watching OR(movies;TV shows;cinema)
21 Playing OR(board games;card games;chess;poker;trivia games;word games)
22 Doing puzzles
23 Collecting OR(stamps;coins;art;antiques)
24 OR(Playing a musical instrument;Composing music;Producing music;DJing)
25 Singing in a choir
26 Playing in a OR(band;orchestra)
27 OR(Blogging;Vlogging;Podcasting)
28 Speaking in public
29 OR(Stand-up;Improvisational) comedy
30 OR(Acting in;Directing;Producing) a OR(play;movie;TV show)
31 OR(Teaching;Coaching;Mentoring;Tutoring)
32 OR(Fundraising;Campaigning for a cause;Activism;Participating in a protest)
33 OR(Gardening;Landscaping)
34 Home improvement
35 Cleaning
36 OR(Organizing;Planning events;Hosting parties)
37 Attending OR(concerts;festivals;theater performances;movies;sports events)
38 OR(Exercising;Going to the gym;Fitnessing)
39 OR(Yoga;Pilates;Tai chi)
40 Meditating
41 OR(Scuba diving;Snorkeling;Kayaking;Canoeing;Rafting;Climbing;Bungee jumping;Skydiving;Paragliding;Hang gliding;Zip lining)
42 OR(Traveling;Exploring new places)
43 Playing OR(Tennis;Basketball;Soccer;Football;Golf;Baseball;Hockey;Icehockey;Volleyball;Beach Volleyball;Sports)
44 OR(Boxing;Wrestling;Doing Martial Arts;Gymnastics;Cycling;Surfing;Skateboarding;Snowboarding;Skiing;Figure Skating;Rowing;Sailing;Cycling;Mountain biking)
45 Diving
46 Playing
47 Horse-back riding
48 -animal--back riding
49 having a tea party
50 Lounging
51 Bathing in a -waterlocation-
52 drinking coffee in a cafe
53 studying in a room
54 doing a fashion show
55 fighting a War
56 sieging a Castle
57 sitting and talking
58 Walking up a stairs
59 Walking down a stairs
60 Walking down a OR(street;-minilocation-)
61 casting a -element- magic spell
+1 -1
View File
@@ -13,6 +13,6 @@ also has a OR(;large;flowing;rare) OR(hooded cloak;cloak;cape;coat;-season- coat
rolled up sleeves
is in the style of -artmovement-
-outfitdescriptor- and -outfitdescriptor-
-materialcombination-;-colorcombination-
OR(-materialcombination-;-colorcombination-)
OR(fishnets;trinkets;bling)
with a OR(asymetrical;bateau;grecian;collar;cowl;halter;illusion;jewel;keyhole;off-the-shoulder;one-shoulder;plunging;queen anne;round neck;scalloped;scoop;spaghetti strap;split crew;square;strapless;surplice;sweethearth;tie bow;turtleneck;U-shape;V-neck) neckline
1 has a OR(;large;small;giant;tiny;normal) OR(;-color-;normal) bowOR(;s;normal)
13 rolled up sleeves
14 is in the style of -artmovement-
15 -outfitdescriptor- and -outfitdescriptor-
16 -materialcombination-;-colorcombination- OR(-materialcombination-;-colorcombination-)
17 OR(fishnets;trinkets;bling)
18 with a OR(asymetrical;bateau;grecian;collar;cowl;halter;illusion;jewel;keyhole;off-the-shoulder;one-shoulder;plunging;queen anne;round neck;scalloped;scoop;spaghetti strap;split crew;square;strapless;surplice;sweethearth;tie bow;turtleneck;U-shape;V-neck) neckline
@@ -0,0 +1 @@
OR(;-descriptor-;normal) OR(;-culture-;uncommon) OR(;-color-;uncommon) -accessory- OR(; , -accessory-; , -descriptor- -accessory-;rare) OR(; and -accessory-;unique)
1 OR( -descriptor- normal) OR( -culture- uncommon) OR( -color- uncommon) -accessory- OR( , -accessory- , -descriptor- -accessory- rare) OR( and -accessory- unique)
@@ -0,0 +1,5 @@
combination of OR(-nonfictional-;-fictional-;legendary) OR(;, OR(-nonfictional-;-fictional-;legendary);rare) and OR(-nonfictional-;-fictional-;legendary)
-facepart- of OR(-nonfictional-;-fictional-;legendary), -facepart- of OR(-nonfictional-;-fictional-;legendary)
OR(;very;legendary) -buildfacepart- OR(; OR(,;and) -buildfacepart-;normal) OR(; and -buildfacepart-;legendary)
OR(;very;legendary) -humandescriptor- -facepart- OR(; and -humandescriptor- -facepart-;uncommon)
-facepart- of OR(-conceptsuffix-;-basicbitchdescriptor-;uncommon) OR(; and -facepart- of OR(-conceptsuffix-;-basicbitchdescriptor-;uncommon);uncommon)
1 combination of OR(-nonfictional-;-fictional-;legendary) OR(;, OR(-nonfictional-;-fictional-;legendary);rare) and OR(-nonfictional-;-fictional-;legendary)
2 -facepart- of OR(-nonfictional-;-fictional-;legendary), -facepart- of OR(-nonfictional-;-fictional-;legendary)
3 OR(;very;legendary) -buildfacepart- OR(; OR(,;and) -buildfacepart-;normal) OR(; and -buildfacepart-;legendary)
4 OR(;very;legendary) -humandescriptor- -facepart- OR(; and -humandescriptor- -facepart-;uncommon)
5 -facepart- of OR(-conceptsuffix-;-basicbitchdescriptor-;uncommon) OR(; and -facepart- of OR(-conceptsuffix-;-basicbitchdescriptor-;uncommon);uncommon)
@@ -0,0 +1,2 @@
OR(-haircolor-;-hairdescriptor-;-culture-;uncommon) hair OR(styled as -hairstyle-;, ;rare)
OR(-haircolor-; -hairstyle-) OR(hairstyle;hair)
1 OR(-haircolor-;-hairdescriptor-;-culture-;uncommon) hair OR(styled as -hairstyle-;, ;rare)
2 OR(-haircolor-; -hairstyle-) OR(hairstyle;hair)
+2 -2
View File
@@ -2,13 +2,13 @@
, OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(;from the OR(-age-;the -agecalculator-);rare)
, OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(; and OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit-;rare)
, OR(wearing;dressed in;in;normal) OR(-job-;-rpgclass-;-season-;-animal--style) OR(-minioutfit-;-outfit-;rare)
, OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;uncommon) OR(-minioutfit-;-outfit-;rare) OR(;OR(designed;made;inspired;forged) by OR(-brand-;-fashiondesigner-);uncommon)
, OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;uncommon) OR(-minioutfit-;-outfit-;rare) OR(;OR(designed;made;inspired;forged) by OR(-brand-;-fashiondesigner-);rare)
, wearing OR(-material-;-color-;-element-;uncommon) -overrideoutfit-
, OR(wearing;dressed in;in;normal) OR(;-outfitdescriptor-;-material-;-color-;uncommon) OR(-outfit-;-minioutfit-;rare) with OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print-,
, -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -outfit-, OR(-hisher-;The;normal) -sameoutfit- is OR(-outfitdescriptor-;-color-) OR( OR(and has;, It has) OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print- on it,; and is OR(made of;detailed with bits of) -material-;rare) OR(;, It looks OR(;very;rare) -outfitdescriptor- on -himher-,;unique)
, -heshe- is OR(wearing;dressed in) OR(;-hisher-;rare) -culture- -outfit-, OR(; OR(-hisher-;The;normal) -sameoutfit- is OR(-outfitdescriptor-;-color-),;normal) OR(;, It looks OR(;very;rare) -outfitdescriptor- on -himher-,;unique)
, -heshe- is OR(wearing a;dressed in a) OR(;-outfitdescriptor-;normal) OR(;-color-;uncommon) OR(;-culture-;uncommon) OR(;-material-;rare) -outfit- that was OR(designed;made;inspired;forged) by -brand-, It is OR(;very;rare) OR(-outfitdescriptor-;-color-;normal) OR(;and OR(-outfitdescriptor-;-color-;normal);normal) OR(;, The -sameoutfit- looks OR(;very;rare) -outfitdescriptor- on -himher-,;unique)
, OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) OR(-minioutfit-;-outfit-;uncommon), OR(-hisher-;The;normal) -sameoutfit- -outfitvomit-
, -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -outfit-, OR(-hisher-;The;normal) -sameoutfit- OR(is tailored by -fashiondesigner- OR(; and -fashiondesigner-;uncommon);is inspired by the -charactertype- OR(;and -charactertype-;uncommon))
, -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -outfit-, OR(-hisher-;The;normal) -sameoutfit- OR(is tailored by -fashiondesigner- OR(; and -fashiondesigner-;uncommon);is inspired by the -charactertype- OR(;and -charactertype-;rare))
, -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -artmovement- fashion style -outfit-
, OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) -outfit-
1 , OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) OR(;-color-;uncommon) OR(;-culture-;uncommon) OR(;-material-;rare) -outfit- OR(;from the OR(-age-;the -agecalculator-);rare)
2 , OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(;from the OR(-age-;the -agecalculator-);rare)
3 , OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(; and OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit-;rare)
4 , OR(wearing;dressed in;in;normal) OR(-job-;-rpgclass-;-season-;-animal--style) OR(-minioutfit-;-outfit-;rare)
5 , OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;uncommon) OR(-minioutfit-;-outfit-;rare) OR(;OR(designed;made;inspired;forged) by OR(-brand-;-fashiondesigner-);uncommon) , OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;uncommon) OR(-minioutfit-;-outfit-;rare) OR(;OR(designed;made;inspired;forged) by OR(-brand-;-fashiondesigner-);rare)
6 , wearing OR(-material-;-color-;-element-;uncommon) -overrideoutfit-
7 , OR(wearing;dressed in;in;normal) OR(;-outfitdescriptor-;-material-;-color-;uncommon) OR(-outfit-;-minioutfit-;rare) with OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print-,
8 , -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -outfit-, OR(-hisher-;The;normal) -sameoutfit- is OR(-outfitdescriptor-;-color-) OR( OR(and has;, It has) OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print- on it,; and is OR(made of;detailed with bits of) -material-;rare) OR(;, It looks OR(;very;rare) -outfitdescriptor- on -himher-,;unique)
9 , -heshe- is OR(wearing;dressed in) OR(;-hisher-;rare) -culture- -outfit-, OR(; OR(-hisher-;The;normal) -sameoutfit- is OR(-outfitdescriptor-;-color-),;normal) OR(;, It looks OR(;very;rare) -outfitdescriptor- on -himher-,;unique)
10 , -heshe- is OR(wearing a;dressed in a) OR(;-outfitdescriptor-;normal) OR(;-color-;uncommon) OR(;-culture-;uncommon) OR(;-material-;rare) -outfit- that was OR(designed;made;inspired;forged) by -brand-, It is OR(;very;rare) OR(-outfitdescriptor-;-color-;normal) OR(;and OR(-outfitdescriptor-;-color-;normal);normal) OR(;, The -sameoutfit- looks OR(;very;rare) -outfitdescriptor- on -himher-,;unique)
11 , OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) OR(-minioutfit-;-outfit-;uncommon), OR(-hisher-;The;normal) -sameoutfit- -outfitvomit-
12 , -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -outfit-, OR(-hisher-;The;normal) -sameoutfit- OR(is tailored by -fashiondesigner- OR(; and -fashiondesigner-;uncommon);is inspired by the -charactertype- OR(;and -charactertype-;uncommon)) , -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -outfit-, OR(-hisher-;The;normal) -sameoutfit- OR(is tailored by -fashiondesigner- OR(; and -fashiondesigner-;uncommon);is inspired by the -charactertype- OR(;and -charactertype-;rare))
13 , -heshe- is OR(wearing a;dressed in) OR(;-hisher-;-hisher- -outfitdescriptor-;rare) -artmovement- fashion style -outfit-
14 , OR(wearing;dressed in;in;normal) OR(;OR(;a very;rare) -outfitdescriptor-;normal) -outfit-
@@ -0,0 +1,14 @@
, OR(;-outfitdescriptor-;normal) OR(;-color-;uncommon) OR(;-culture-;uncommon) OR(;-material-;rare) -outfit- OR(;from the OR(-age-;the -agecalculator-);rare)
, OR(;-outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(;from the OR(-age-;the -agecalculator-);rare)
, OR(;-outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(; and OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit-;rare)
, OR(-job-;-rpgclass-;-season-;-animal--style) OR(-minioutfit-;-outfit-;rare)
, OR(;-outfitdescriptor-;uncommon) OR(-minioutfit-;-outfit-;rare) OR(;OR(designed;made;inspired;forged) by OR(-brand-;-fashiondesigner-);rare)
, OR(-material-;-color-;-element-;uncommon) -overrideoutfit-
, OR(;-outfitdescriptor-;-material-;-color-;uncommon) OR(-outfit-;-minioutfit-;rare), OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print-,
, OR(;-outfitdescriptor-;normal) -outfit-, OR(-outfitdescriptor-;-color-), OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print- OR(;-material-;rare)
, -culture- -outfit-, OR(;OR(-outfitdescriptor-;-color-),;normal)
, OR(;-outfitdescriptor-;normal) OR(;-color-;uncommon) OR(;-culture-;uncommon) OR(;-material-;rare) -outfit- that was OR(designed;made;inspired;forged) by -brand-
, OR(;-outfitdescriptor-;normal) OR(-minioutfit-;-outfit-;uncommon), -outfitvomit-
, OR(;-outfitdescriptor-;normal) -outfit-, OR(is tailored by -fashiondesigner- OR(; and -fashiondesigner-;uncommon);-charactertype- OR(;and -charactertype-;rare))
, OR(;-outfitdescriptor-;normal) -artmovement- fashion style -outfit-
, OR(;-outfitdescriptor-;normal) -outfit-
1 , OR(;-outfitdescriptor-;normal) OR(;-color-;uncommon) OR(;-culture-;uncommon) OR(;-material-;rare) -outfit- OR(;from the OR(-age-;the -agecalculator-);rare)
2 , OR(;-outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(;from the OR(-age-;the -agecalculator-);rare)
3 , OR(;-outfitdescriptor-;normal) OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit- OR(; and OR(;-outfitdescriptor-;uncommon) OR(;-color-;uncommon) -outfit-;rare)
4 , OR(-job-;-rpgclass-;-season-;-animal--style) OR(-minioutfit-;-outfit-;rare)
5 , OR(;-outfitdescriptor-;uncommon) OR(-minioutfit-;-outfit-;rare) OR(;OR(designed;made;inspired;forged) by OR(-brand-;-fashiondesigner-);rare)
6 , OR(-material-;-color-;-element-;uncommon) -overrideoutfit-
7 , OR(;-outfitdescriptor-;-material-;-color-;uncommon) OR(-outfit-;-minioutfit-;rare), OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print-,
8 , OR(;-outfitdescriptor-;normal) -outfit-, OR(-outfitdescriptor-;-color-), OR(-pattern-;-outfitprinttotal-;-material-;uncommon) -print- OR(;-material-;rare)
9 , -culture- -outfit-, OR(;OR(-outfitdescriptor-;-color-),;normal)
10 , OR(;-outfitdescriptor-;normal) OR(;-color-;uncommon) OR(;-culture-;uncommon) OR(;-material-;rare) -outfit- that was OR(designed;made;inspired;forged) by -brand-
11 , OR(;-outfitdescriptor-;normal) OR(-minioutfit-;-outfit-;uncommon), -outfitvomit-
12 , OR(;-outfitdescriptor-;normal) -outfit-, OR(is tailored by -fashiondesigner- OR(; and -fashiondesigner-;uncommon);-charactertype- OR(;and -charactertype-;rare))
13 , OR(;-outfitdescriptor-;normal) -artmovement- fashion style -outfit-
14 , OR(;-outfitdescriptor-;normal) -outfit-
+2 -1
View File
@@ -15,4 +15,5 @@ OR(;, -heshe- is;rare) inside a -container-
OR(;, -heshe- is;rare) OR(surrounded by;being looked at by) a OR(couple;group) of OR(;-descriptor-;uncommon) OR(people;-malefemale-s;animals) OR(;wearing OR(;-descriptor-;uncommon) -outfit-;rare)
OR(;, -heshe- is;rare) from the OR(-age-;the -agecalculator-)
OR(;, -heshe- is;uncommon) in a -setting- setting
OR(as a;OR(;, -heshe- is;uncommon) reimagined as a) -charactertype- character
OR(as a;OR(;, -heshe- is;uncommon) reimagined as a) -charactertype- character
OR(;, -heshe- is;rare) dressed up as -fictional- character
1 OR(; -heshe- is;rare) OR(riding;with) a -animal-
15 OR(; -heshe- is;rare) OR(surrounded by;being looked at by) a OR(couple;group) of OR(;-descriptor-;uncommon) OR(people;-malefemale-s;animals) OR(;wearing OR(;-descriptor-;uncommon) -outfit-;rare)
16 OR(; -heshe- is;rare) from the OR(-age-;the -agecalculator-)
17 OR(; -heshe- is;uncommon) in a -setting- setting
18 OR(as a;OR(; -heshe- is;uncommon) reimagined as a) -charactertype- character
19 OR(; -heshe- is;rare) dressed up as -fictional- character
@@ -0,0 +1,19 @@
OR(riding;with) a -animal-
holding a OR(-objectstohold-;-object-;rare)
driving a -vehicle-
surrounded by OR(-object-s;-flora-s;-space-)
eating -food-
OR(and;holding hands with) -human-
cosplaying as -fictional-
OR(-color-;-material-) skin
-miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)
wearing -elaborateoutfit-
- OR(-animal-;-humanoid-) OR(;hybrid;normal)
-culture- -rpgclass-
sitting in a OR(;-descriptor-;uncommon) -chair-
inside a -container-
OR(surrounded by;being looked at by) a OR(couple;group) of OR(;-descriptor-;uncommon) OR(people;-malefemale-s;animals) OR(;wearing OR(;-descriptor-;uncommon) -outfit-;rare)
from the OR(-age-;the -agecalculator-)
-setting-
-charactertype- character
as -fictional- character
1 OR(riding;with) a -animal-
2 holding a OR(-objectstohold-;-object-;rare)
3 driving a -vehicle-
4 surrounded by OR(-object-s;-flora-s;-space-)
5 eating -food-
6 OR(and;holding hands with) -human-
7 cosplaying as -fictional-
8 OR(-color-;-material-) skin
9 -miniactivity- OR(in;at) a OR(-location-;-building-;-waterlocation-)
10 wearing -elaborateoutfit-
11 - OR(-animal-;-humanoid-) OR(;hybrid;normal)
12 -culture- -rpgclass-
13 sitting in a OR(;-descriptor-;uncommon) -chair-
14 inside a -container-
15 OR(surrounded by;being looked at by) a OR(couple;group) of OR(;-descriptor-;uncommon) OR(people;-malefemale-s;animals) OR(;wearing OR(;-descriptor-;uncommon) -outfit-;rare)
16 from the OR(-age-;the -agecalculator-)
17 -setting-
18 -charactertype- character
19 as -fictional- character
@@ -0,0 +1,9 @@
made from OR(-material-;-space-;-flora-)
OR(detailed;engraved;rare) with OR(-material-;-color-;-outfitdescriptor-;-pattern-) OR(; and -color-; and -outfitdescriptor-;rare) OR(patterns;details)
OR(smooth;sleek)
OR(intricate;ornate;-basicbitchdescriptor-) details
OR(designed;made;inspired;forged) by -brand-
anthropomorphic OR(;with a face;as a -charactertype- character;common)
with OR(-pattern-;-color-;-descriptor-;rare) -print-
covered in -covering-
-setting- setting
1 made from OR(-material-;-space-;-flora-)
2 OR(detailed;engraved;rare) with OR(-material-;-color-;-outfitdescriptor-;-pattern-) OR(; and -color-; and -outfitdescriptor-;rare) OR(patterns;details)
3 OR(smooth;sleek)
4 OR(intricate;ornate;-basicbitchdescriptor-) details
5 OR(designed;made;inspired;forged) by -brand-
6 anthropomorphic OR(;with a face;as a -charactertype- character;common)
7 with OR(-pattern-;-color-;-descriptor-;rare) -print-
8 covered in -covering-
9 -setting- setting
+3 -3
View File
@@ -13,7 +13,7 @@ from call_extras import *
from model_lists import *
def generateimages(amount = 1, size = "all",model = "currently selected model",samplingsteps = "40",cfg= "7",hiresfix = True,hiressteps ="0",denoisestrength="0.6",samplingmethod="DPM++ SDE Karras", upscaler="R-ESRGAN 4x+", hiresscale="2",apiurl="http://127.0.0.1:7860",qualitygate=False,quality="7.6",runs="5",insanitylevel="5",subject="all", artist="all", imagetype="all",silentmode=False, workprompt="", antistring="",prefixprompt="", suffixprompt="", negativeprompt="",promptcompounderlevel = "1", seperator="comma", img2imgbatch = "1", img2imgsamplingsteps = "20", img2imgcfg = "7", img2imgsamplingmethod = "DPM++ SDE Karras", img2imgupscaler = "R-ESRGAN 4x+", img2imgmodel = "currently selected model", img2imgactivate = False, img2imgscale = "2", img2imgpadding = "64",img2imgdenoisestrength="0.3",ultimatesdupscale=False,usdutilewidth = "512", usdutileheight = "0", usdumaskblur = "8", usduredraw ="Linear", usduSeamsfix = "None", usdusdenoise = "0.35", usduswidth = "64", usduspadding ="32", usdusmaskblur = "8",controlnetenabled=False, controlnetmodel="",img2imgdenoisestrengthmod="-0.05",enableextraupscale = False,controlnetblockymode = False,extrasupscaler1 = "all",extrasupscaler2 ="all",extrasupscaler2visiblity="0.5",extrasupscaler2gfpgan="0",extrasupscaler2codeformer="0.15",extrasupscaler2codeformerweight="0.1",extrasresize="2",onlyupscale="false",givensubject="",smartsubject=True,giventypeofimage="",imagemodechance=20, gender="all", chosensubjectsubtypeobject="all", chosensubjectsubtypehumanoid="all", chosensubjectsubtypeconcept="all", increasestability = False, qualityhiresfix = False, qualitymode = "highest", qualitykeep="keep used", basesize = "512", promptvariantinsanitylevel = 0, givenoutfit = "", autonegativeprompt = True, autonegativepromptstrength = 0, autonegativepromptenhance = False):
def generateimages(amount = 1, size = "all",model = "currently selected model",samplingsteps = "40",cfg= "7",hiresfix = True,hiressteps ="0",denoisestrength="0.6",samplingmethod="DPM++ SDE Karras", upscaler="R-ESRGAN 4x+", hiresscale="2",apiurl="http://127.0.0.1:7860",qualitygate=False,quality="7.6",runs="5",insanitylevel="5",subject="all", artist="all", imagetype="all",silentmode=False, workprompt="", antistring="",prefixprompt="", suffixprompt="", negativeprompt="",promptcompounderlevel = "1", seperator="comma", img2imgbatch = "1", img2imgsamplingsteps = "20", img2imgcfg = "7", img2imgsamplingmethod = "DPM++ SDE Karras", img2imgupscaler = "R-ESRGAN 4x+", img2imgmodel = "currently selected model", img2imgactivate = False, img2imgscale = "2", img2imgpadding = "64",img2imgdenoisestrength="0.3",ultimatesdupscale=False,usdutilewidth = "512", usdutileheight = "0", usdumaskblur = "8", usduredraw ="Linear", usduSeamsfix = "None", usdusdenoise = "0.35", usduswidth = "64", usduspadding ="32", usdusmaskblur = "8",controlnetenabled=False, controlnetmodel="",img2imgdenoisestrengthmod="-0.05",enableextraupscale = False,controlnetblockymode = False,extrasupscaler1 = "all",extrasupscaler2 ="all",extrasupscaler2visiblity="0.5",extrasupscaler2gfpgan="0",extrasupscaler2codeformer="0.15",extrasupscaler2codeformerweight="0.1",extrasresize="2",onlyupscale="false",givensubject="",smartsubject=True,giventypeofimage="",imagemodechance=20, gender="all", chosensubjectsubtypeobject="all", chosensubjectsubtypehumanoid="all", chosensubjectsubtypeconcept="all", increasestability = False, qualityhiresfix = False, qualitymode = "highest", qualitykeep="keep used", basesize = "512", promptvariantinsanitylevel = 0, givenoutfit = "", autonegativeprompt = True, autonegativepromptstrength = 0, autonegativepromptenhance = False, base_model = "SD1.5"):
loops = int(amount) # amount of images to generate
steps = 0
upscalefilelist=[]
@@ -136,12 +136,12 @@ def generateimages(amount = 1, size = "all",model = "currently selected model",s
else:
randompromptlist = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, False,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,True,False,-1,givenoutfit, prompt_g_and_l=True)
randompromptlist = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, False,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,True,False,-1,givenoutfit, prompt_g_and_l=True, base_model=base_model)
randomprompt = randompromptlist[0]
randomsubject = randompromptlist[1]
if(autonegativeprompt):
negativeprompt = build_dynamic_negative(positive_prompt=randomprompt, insanitylevel=autonegativepromptstrength,enhance=autonegativepromptenhance, existing_negative_prompt=originalnegativeprompt)
negativeprompt = build_dynamic_negative(positive_prompt=randomprompt, insanitylevel=autonegativepromptstrength,enhance=autonegativepromptenhance, existing_negative_prompt=originalnegativeprompt, base_model=base_model)
if(randomsubject == ""):
# make the filename, from from a to the first comma
+3 -3
View File
@@ -10,7 +10,7 @@ from build_dynamic_prompt import *
def generateprompts(amount = 1,positive_prompt = "",insanitylevel="0",enhance=False,existing_negative_prompt=""):
def generateprompts(amount = 1,positive_prompt = "",insanitylevel="0",enhance=False,existing_negative_prompt="", base_model= "SD1.5"):
loops = int(amount) # amount of images to generate
steps = 0
@@ -19,7 +19,7 @@ def generateprompts(amount = 1,positive_prompt = "",insanitylevel="0",enhance=Fa
# build prompt
if positive_prompt == "":
positive_prompt = build_dynamic_prompt()
result = build_dynamic_negative(positive_prompt=positive_prompt, insanitylevel=insanitylevel,enhance=enhance, existing_negative_prompt=existing_negative_prompt)
result = build_dynamic_negative(positive_prompt=positive_prompt, insanitylevel=insanitylevel,enhance=enhance, existing_negative_prompt=existing_negative_prompt, base_model=base_model)
print("negative prompt: " + result)
print("")
print("loop " + str(steps))
@@ -32,4 +32,4 @@ def generateprompts(amount = 1,positive_prompt = "",insanitylevel="0",enhance=Fa
print("")
print("All done!")
generateprompts(1,"art by van gogh, a celestial being",0,False,"")
generateprompts(1,"photo, photograph, realism",0,False,"", base_model="Stable Cascade")
+4 -4
View File
@@ -10,7 +10,7 @@ from build_dynamic_prompt import *
def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", imagetype="all",onlyartists=False, workprompt="", antistring="",prefixprompt="", suffixprompt="", negativeprompt="",promptcompounderlevel = "1", seperator="comma",givensubject="",smartsubject=True,giventypeofimage="",imagemodechance=20, gender = "all", subtypeobject = "all", subtypehumanoid = "all", subtypeconcept = "all", advancedprompting = True, hardturnoffemojis=False, seed=0, overrideoutfit="", prompt_g_and_l = False):
def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", imagetype="all",onlyartists=False, workprompt="", antistring="",prefixprompt="", suffixprompt="", negativeprompt="",promptcompounderlevel = "1", seperator="comma",givensubject="",smartsubject=True,giventypeofimage="",imagemodechance=20, gender = "all", subtypeobject = "all", subtypehumanoid = "all", subtypeconcept = "all", advancedprompting = True, hardturnoffemojis=False, seed=0, overrideoutfit="", prompt_g_and_l = False, base_model = "SD1.5"):
loops = int(amount) # amount of images to generate
steps = 0
@@ -18,7 +18,7 @@ def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", im
while steps < loops:
# build prompt
if(prompt_g_and_l == True):
resultlist = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, subtypeobject, subtypehumanoid, subtypeconcept, advancedprompting, hardturnoffemojis, seed, overrideoutfit, prompt_g_and_l)
resultlist = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, subtypeobject, subtypehumanoid, subtypeconcept, advancedprompting, hardturnoffemojis, seed, overrideoutfit, prompt_g_and_l, base_model)
result = resultlist[0]
print("prompt_g")
print(resultlist[1])
@@ -26,7 +26,7 @@ def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", im
print(resultlist[2])
else:
result = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, subtypeobject, subtypehumanoid, subtypeconcept, advancedprompting, hardturnoffemojis, seed, overrideoutfit, prompt_g_and_l)
result = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, subtypeobject, subtypehumanoid, subtypeconcept, advancedprompting, hardturnoffemojis, seed, overrideoutfit, prompt_g_and_l, base_model)
print("")
print("loop " + str(steps))
print("")
@@ -88,7 +88,6 @@ def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", im
# print(result)
# break
steps += 1
@@ -115,4 +114,5 @@ generateprompts(10,5
, 0 # seed
, "" #outfit override
, False #prompt_g_and_l
, "SDXL" #base model
)
+26 -9
View File
@@ -18,6 +18,7 @@ from csv_reader import *
from one_button_presets import OneButtonPresets
OBPresets = OneButtonPresets()
basemodelslist = ["SD1.5", "SDXL", "Stable Cascade"]
#subjects = ["all","object","animal","humanoid", "landscape", "concept"]
subjects =["all"]
subjectsubtypesobject = ["all"]
@@ -233,12 +234,12 @@ class Script(scripts.Script):
def ui(self, is_img2img):
def gen_prompt(insanitylevel, subject, artist, imagetype, antistring, prefixprompt, suffixprompt, promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage, imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,givenoutfit):
def gen_prompt(insanitylevel, subject, artist, imagetype, antistring, prefixprompt, suffixprompt, promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage, imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,givenoutfit, base_model):
promptlist = []
for i in range(5):
promptlist.append(build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring,prefixprompt,suffixprompt,promptcompounderlevel,seperator,givensubject,smartsubject, giventypeofimage, imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,True,False,-1,givenoutfit))
promptlist.append(build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring,prefixprompt,suffixprompt,promptcompounderlevel,seperator,givensubject,smartsubject, giventypeofimage, imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,True,False,-1,givenoutfit,False,base_model))
return promptlist
@@ -627,6 +628,22 @@ class Script(scripts.Script):
with gr.Column(variant="compact"):
prompt5toworkflow = gr.Button("⬆️🛠️💬")
with gr.Tab("Advanced"):
with gr.Row(variant="compact"):
gr.Markdown("""
<font size="2">
✨Base model will try and generate prompts fitting the selected model.
SD1.5 --> Less natural language
SDXL --> More natural language (default)
Stable Cascade --> More natural language and no prompt weights
</font>
"""
)
with gr.Row(variant="compact"):
base_model = gr.Dropdown(
basemodelslist, label="✨ Base model", value="SDXL")
with gr.Row(variant="compact"):
with gr.Column(variant="compact"):
promptcompounderlevel = gr.Dropdown(
@@ -888,7 +905,7 @@ class Script(scripts.Script):
extrasupscaler2codeformerweight = gr.Slider(0, 1, value="0.1", step=0.05, label="CodeFormer weight", visible = False)
genprom.click(gen_prompt, inputs=[insanitylevel,subject, artist, imagetype, antistring,prefixprompt, suffixprompt,promptcompounderlevel, seperator, givensubject,smartsubject,giventypeofimage,imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, givenoutfit], outputs=[prompt1, prompt2, prompt3,prompt4,prompt5])
genprom.click(gen_prompt, inputs=[insanitylevel,subject, artist, imagetype, antistring,prefixprompt, suffixprompt,promptcompounderlevel, seperator, givensubject,smartsubject,giventypeofimage,imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, givenoutfit, base_model], outputs=[prompt1, prompt2, prompt3,prompt4,prompt5])
prompt1toworkflow.click(prompttoworkflowprompt, inputs=prompt1, outputs=workprompt)
prompt2toworkflow.click(prompttoworkflowprompt, inputs=prompt2, outputs=workprompt)
@@ -896,7 +913,7 @@ class Script(scripts.Script):
prompt4toworkflow.click(prompttoworkflowprompt, inputs=prompt4, outputs=workprompt)
prompt5toworkflow.click(prompttoworkflowprompt, inputs=prompt5, outputs=workprompt)
startmain.click(generateimages, inputs=[amountofimages,size,model,samplingsteps,cfg,hiresfix,hiressteps,denoisestrength,samplingmethod, upscaler,hiresscale, apiurl, qualitygate, quality, runs,insanitylevel,subject, artist, imagetype, silentmode, workprompt, antistring, prefixprompt, suffixprompt,negativeprompt,promptcompounderlevel, seperator, img2imgbatch, img2imgsamplingsteps, img2imgcfg, img2imgsamplingmethod, img2imgupscaler, img2imgmodel,img2imgactivate, img2imgscale, img2imgpadding,img2imgdenoisestrength,ultimatesdupscale,usdutilewidth, usdutileheight, usdumaskblur, usduredraw, usduSeamsfix, usdusdenoise, usduswidth, usduspadding, usdusmaskblur, controlnetenabled, controlnetmodel,img2imgdenoisestrengthmod,enableextraupscale,controlnetblockymode,extrasupscaler1,extrasupscaler2,extrasupscaler2visiblity,extrasupscaler2gfpgan,extrasupscaler2codeformer,extrasupscaler2codeformerweight,extrasresize,onlyupscale,givensubject,smartsubject,giventypeofimage,imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, increasestability, qualityhiresfix, qualitymode, qualitykeep, basesize, promptvariantinsanitylevel, givenoutfit, autonegativeprompt, autonegativepromptstrength, autonegativepromptenhance])
startmain.click(generateimages, inputs=[amountofimages,size,model,samplingsteps,cfg,hiresfix,hiressteps,denoisestrength,samplingmethod, upscaler,hiresscale, apiurl, qualitygate, quality, runs,insanitylevel,subject, artist, imagetype, silentmode, workprompt, antistring, prefixprompt, suffixprompt,negativeprompt,promptcompounderlevel, seperator, img2imgbatch, img2imgsamplingsteps, img2imgcfg, img2imgsamplingmethod, img2imgupscaler, img2imgmodel,img2imgactivate, img2imgscale, img2imgpadding,img2imgdenoisestrength,ultimatesdupscale,usdutilewidth, usdutileheight, usdumaskblur, usduredraw, usduSeamsfix, usdusdenoise, usduswidth, usduspadding, usdusmaskblur, controlnetenabled, controlnetmodel,img2imgdenoisestrengthmod,enableextraupscale,controlnetblockymode,extrasupscaler1,extrasupscaler2,extrasupscaler2visiblity,extrasupscaler2gfpgan,extrasupscaler2codeformer,extrasupscaler2codeformerweight,extrasresize,onlyupscale,givensubject,smartsubject,giventypeofimage,imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, increasestability, qualityhiresfix, qualitymode, qualitykeep, basesize, promptvariantinsanitylevel, givenoutfit, autonegativeprompt, autonegativepromptstrength, autonegativepromptenhance, base_model])
interrupt.click(tryinterrupt, inputs=[apiurl])
automatedoutputsfolderbutton.click(openfolder)
@@ -1201,12 +1218,12 @@ class Script(scripts.Script):
return [insanitylevel,subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring, seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, promptvariantinsanitylevel, givenoutfit, autonegativeprompt, autonegativepromptstrength, autonegativepromptenhance]
return [insanitylevel,subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring, seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, promptvariantinsanitylevel, givenoutfit, autonegativeprompt, autonegativepromptstrength, autonegativepromptenhance, base_model]
def run(self, p, insanitylevel, subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring,seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, promptvariantinsanitylevel, givenoutfit, autonegativeprompt, autonegativepromptstrength, autonegativepromptenhance):
def run(self, p, insanitylevel, subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring,seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept, promptvariantinsanitylevel, givenoutfit, autonegativeprompt, autonegativepromptstrength, autonegativepromptenhance, base_model):
images = []
infotexts = []
@@ -1253,7 +1270,7 @@ class Script(scripts.Script):
if(ANDtoggle == "automatic"):
if(artist != "none"):
preppedprompt += build_dynamic_prompt(insanitylevel,subject,artist, imagetype, True, antistring)
preppedprompt += build_dynamic_prompt(insanitylevel,subject,artist, imagetype, True, antistring, base_model=base_model)
if(subject == "humanoid"):
preppedprompt += ", " + promptcompounderlevel + " people"
if(subject == "landscape"):
@@ -1280,7 +1297,7 @@ class Script(scripts.Script):
#Here is where we build a "normal" prompt
preppedprompt += build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring, prefixprompt, suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,True,False,-1,givenoutfit)
preppedprompt += build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring, prefixprompt, suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept,True,False,-1,givenoutfit, False, base_model)
# set the artist mode back when done (for automatic mode)
artist = artistcopy
@@ -1301,7 +1318,7 @@ class Script(scripts.Script):
print(p.prompt)
if(autonegativeprompt):
p.negative_prompt = build_dynamic_negative(positive_prompt=p.prompt, insanitylevel=autonegativepromptstrength,enhance=autonegativepromptenhance, existing_negative_prompt=p.negative_prompt)
p.negative_prompt = build_dynamic_negative(positive_prompt=p.prompt, insanitylevel=autonegativepromptstrength,enhance=autonegativepromptenhance, existing_negative_prompt=p.negative_prompt, base_model=base_model)
promptlist = []