From dfbc30f15c7966523b979dfe0f869f9af35eaf48 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Tue, 4 Jul 2023 20:11:59 +0200 Subject: [PATCH 01/18] First part of config is working --- .gitignore | 1 + build_dynamic_prompt.py | 106 +++++++++++++++++++++++------ csv_reader.py | 19 ++++++ csvfiles/accessories.csv | 1 + csvfiles/config/default_config.csv | 28 ++++++++ csvfiles/containers.csv | 4 +- csvfiles/elaborateoutfits.csv | 3 +- 7 files changed, 141 insertions(+), 21 deletions(-) create mode 100644 csvfiles/config/default_config.csv diff --git a/.gitignore b/.gitignore index e1172cd..654640b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ *.pyc userfiles/antilist.csv +userfiles/config.csv \ No newline at end of file diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index a56d458..28bdd68 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -13,6 +13,11 @@ from random_functions import * 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): + # load the config file + config = load_config_csv() + + + # first build up a complete anti list. Those values are removing during list building # this uses the antivalues string AND the antilist.csv emptylist = [] @@ -145,12 +150,75 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all addontolocationinsidelist = [] addontolocationlist = [] - generatevehicle = bool(vehiclelist) - generateobject = bool(objectlist) - generatefood = bool(foodlist) - generatebuilding = bool(buildinglist) - generatespace = bool(spacelist) - generateobject = generatevehicle + generateobject + generatefood + generatebuilding + generatespace + # load subjects stuff from config + generatevehicle = False + generateobject = False + generatefood = False + generatebuilding = False + generatespace = False + generateanimal = False + generatemanwoman = False + generatemanwomanrelation = False + generatefictionalcharacter = False + generatenonfictionalcharacter = False + generatehumanoids = False + generatejob = False + generatelandscape = False + generateevent = False + generateconcepts = False + generatepoemline = False + generatesongline = False + + + for item in config: + # objects + if item[0] == 'subject_vehicle' and item[1] == 'on': + generatevehicle = True + if item[0] == 'subject_object' and item[1] == 'on': + generateobject = True + if item[0] == 'subject_food' and item[1] == 'on': + generatefood = True + if item[0] == 'subject_building' and item[1] == 'on': + generatebuilding = True + if item[0] == 'subject_space' and item[1] == 'on': + generatespace = True + # animals + if item[0] == 'subject_animal' and item[1] == 'on': + generateanimal = True + # humanoids + if item[0] == 'subject_manwoman' and item[1] == 'on': + generatemanwoman = True + if item[0] == 'subject_manwomanrelation' and item[1] == 'on': + generatemanwomanrelation = True + if item[0] == 'subject_fictional' and item[1] == 'on': + generatefictionalcharacter = True + if item[0] == 'subject_nonfictional' and item[1] == 'on': + generatenonfictionalcharacter = True + if item[0] == 'subject_humanoid' and item[1] == 'on': + generatehumanoids = True + if item[0] == 'subject_job' and item[1] == 'on': + generatejob = True + # landscape + if item[0] == 'subject_landscape' and item[1] == 'on': + generatelandscape = True + # concept + if item[0] == 'subject_event' and item[1] == 'on': + generateevent = True + if item[0] == 'subject_concept' and item[1] == 'on': + generateconcepts = True + if item[0] == 'poemline' and item[1] == 'on': + generatepoemline = True + if item[0] == 'songline' and item[1] == 'on': + generatesongline = True + + + + generatevehicle = bool(vehiclelist) and generatevehicle + generateobject = bool(objectlist) and generateobject + generatefood = bool(foodlist) and generatefood + generatebuilding = bool(buildinglist) and generatebuilding + generatespace = bool(spacelist) and generatespace + generateobject = generatevehicle or generateobject or generatefood or generatebuilding or generatespace if(generatevehicle): @@ -180,13 +248,13 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all if(generateobject): mainchooserlist.append("object") - generatefictionalcharacter = bool(fictionallist) - generatenonfictionalcharacter = bool(nonfictionallist) - generatehumanoids = bool(humanoidlist) - generatemanwoman = bool(manwomanlist) - generatemanwomanrelation = bool(manwomanrelationlist) - generatejob = bool(joblist) - generatehumanoid = generatefictionalcharacter + generatenonfictionalcharacter + generatehumanoids + generatemanwoman + generatejob + generatemanwomanrelation + generatefictionalcharacter = bool(fictionallist) and generatefictionalcharacter + generatenonfictionalcharacter = bool(nonfictionallist) and generatenonfictionalcharacter + generatehumanoids = bool(humanoidlist) and generatehumanoids + generatemanwoman = bool(manwomanlist) and generatemanwoman + generatemanwomanrelation = bool(manwomanrelationlist) and generatemanwomanrelation + generatejob = bool(joblist) and generatejob + generatehumanoid = generatefictionalcharacter or generatenonfictionalcharacter or generatehumanoids or generatemanwoman or generatejob or generatemanwomanrelation if(generatefictionalcharacter): @@ -217,23 +285,23 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all mainchooserlist.append("humanoid") - generateanimal = bool(animallist) + generateanimal = bool(animallist) and generateanimal if(generateanimal): mainchooserlist.append("animal") hybridlist.append("-animal-") - generatelandscape = bool(locationlist) + generatelandscape = bool(locationlist) and generatelandscape if(generatelandscape): mainchooserlist.append("landscape") addontolocationlist.append("-location-") addontolocationinsidelist.append("-location-") - generateevent = bool(eventlist) - generateconcepts = bool(conceptprefixlist) + bool(conceptsuffixlist) - generatepoemline = bool(poemlinelist) - generatesongline = bool(songlinelist) + generateevent = bool(eventlist) and generateevent + generateconcepts = bool(conceptprefixlist) and bool(conceptsuffixlist) and generateconcepts + generatepoemline = bool(poemlinelist) and generatepoemline + generatesongline = bool(songlinelist) and generatesongline diff --git a/csv_reader.py b/csv_reader.py index cccf27f..ffc146b 100644 --- a/csv_reader.py +++ b/csv_reader.py @@ -1,6 +1,7 @@ import csv import random import os +import shutil def random_read_from_csv(filename): script_dir = os.path.dirname(os.path.abspath(__file__)) # Script directory @@ -92,3 +93,21 @@ def artist_category_csv_to_list(csvfilename,category): +def load_config_csv(): + csvlist = [] + script_dir = os.path.dirname(os.path.abspath(__file__)) + full_path_config_file = os.path.join(script_dir, "./userfiles/" ) + full_path_default_config_file = os.path.join(script_dir, "./csvfiles/config/" ) + config_file = full_path_config_file + 'config.csv' + default_config_file = full_path_default_config_file + 'default_config.csv' + + if not os.path.exists(config_file): + shutil.copy2(default_config_file, config_file) + print("Config file created.") + + + with open(config_file, "r", newline="",encoding="utf8") as file: + reader = csv.DictReader(file, delimiter=";") + csvlist = [list(row.values()) for row in reader if not any(value.startswith('#') for value in row.values())] + return csvlist + \ No newline at end of file diff --git a/csvfiles/accessories.csv b/csvfiles/accessories.csv index e633cb8..bdbf360 100644 --- a/csvfiles/accessories.csv +++ b/csvfiles/accessories.csv @@ -26,6 +26,7 @@ Anime Eyes Hair Tie Hair Clip Hair Ribbons +Flower in hair Barrette Hat Trucker hat diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv new file mode 100644 index 0000000..8f23610 --- /dev/null +++ b/csvfiles/config/default_config.csv @@ -0,0 +1,28 @@ +#this file controls the generation process; +#records starting with # are ignored; +#----; +# main subject generation options; +# these can either be on or off; +#----; +# objects; +subject_object;on +subject_vehicle;on +subject_food;on +subject_space;on +subject_building;on +# animals; +subject_animal;on +# humanoids; +subject_manwoman;on +subject_manwomanrelation;on +subject_fictional;on +subject_nonfictional;on +subject_humanoid;on +subject_job;on +# landscape; +subject_landscape;on +# concept; +subject_event;on +subject_concept;on +subject_poemline;on +subject_songline;on \ No newline at end of file diff --git a/csvfiles/containers.csv b/csvfiles/containers.csv index d203f90..b6b9608 100644 --- a/csvfiles/containers.csv +++ b/csvfiles/containers.csv @@ -23,4 +23,6 @@ Terrarium Fishbowl Paperweight Glass canister -Machine \ No newline at end of file +Machine +Glass case +Display case \ No newline at end of file diff --git a/csvfiles/elaborateoutfits.csv b/csvfiles/elaborateoutfits.csv index 37d5b53..7b34344 100644 --- a/csvfiles/elaborateoutfits.csv +++ b/csvfiles/elaborateoutfits.csv @@ -33,4 +33,5 @@ prehistoric -minioutfit-, in a cave, cave paintings, unga bunga cute cat ears, furry, kawaii, cutecore, happy, cattail, colorful cute -animal- ears, furry hybrid, grin, animal- tail, colorful F1 racer suit, at the pit stop, F1 car -Cargo Shorts, Tight Shirt and Vest, Adventuring Backpack Gear, Hiking Boots \ No newline at end of file +Cargo Shorts, Tight Shirt and Vest, Adventuring Backpack Gear, Hiking Boots +-rgpclass-, -minioutfit-, shield, sword, medieval \ No newline at end of file From 0a4e68cfa51872161fd0d5706dd661bd9d4fddaa Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 09:11:34 +0200 Subject: [PATCH 02/18] more work on the config --- build_dynamic_prompt.py | 189 +++++++++++++++++++---------- csvfiles/config/default_config.csv | 24 +++- prompttester.py | 2 +- random_functions.py | 32 ++++- 4 files changed, 177 insertions(+), 70 deletions(-) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index 28bdd68..7b4766c 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -151,66 +151,121 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all addontolocationlist = [] # load subjects stuff from config - generatevehicle = False - generateobject = False - generatefood = False - generatebuilding = False - generatespace = False - generateanimal = False - generatemanwoman = False - generatemanwomanrelation = False - generatefictionalcharacter = False - generatenonfictionalcharacter = False - generatehumanoids = False - generatejob = False - generatelandscape = False - generateevent = False - generateconcepts = False - generatepoemline = False - generatesongline = False + generatevehicle = True + generateobject = True + generatefood = True + generatebuilding = True + generatespace = True + generateanimal = True + generatemanwoman = True + generatemanwomanrelation = True + generatefictionalcharacter = True + generatenonfictionalcharacter = True + generatehumanoids = True + generatejob = True + generatelandscape = True + generateevent = True + generateconcepts = True + generatepoemline = True + generatesongline = True + + custominputprefixrepeats = 2 + custominputprefixchance = 'uncommon' + + imagetypechance = 'normal' + generateimagetype = True + imagetypequalitychance = 'rare' + generateimagetypequality = True + generateminilocationaddition = True + minilocationadditionchance = 'unique' + artmovementprefixchance = 'unique' + minivomitprefix1chance = 'rare' + minivomitprefix2chance = 'unique' + shotsizechance = 'uncommon' + + subjectdescriptor1chance = 'common' + subjectdescriptor2chance = 'uncommon' + subjectbodytypechance = 'normal' + subjectculturechance = 'normal' + for item in config: # objects - if item[0] == 'subject_vehicle' and item[1] == 'on': - generatevehicle = True - if item[0] == 'subject_object' and item[1] == 'on': - generateobject = True - if item[0] == 'subject_food' and item[1] == 'on': - generatefood = True - if item[0] == 'subject_building' and item[1] == 'on': - generatebuilding = True - if item[0] == 'subject_space' and item[1] == 'on': - generatespace = True + if item[0] == 'subject_vehicle' and item[1] != 'on': + generatevehicle = False + if item[0] == 'subject_object' and item[1] != 'on': + generateobject = False + if item[0] == 'subject_food' and item[1] != 'on': + generatefood = False + if item[0] == 'subject_building' and item[1] != 'on': + generatebuilding = False + if item[0] == 'subject_space' and item[1] != 'on': + generatespace = False # animals - if item[0] == 'subject_animal' and item[1] == 'on': - generateanimal = True + if item[0] == 'subject_animal' and item[1] != 'on': + generateanimal = False # humanoids - if item[0] == 'subject_manwoman' and item[1] == 'on': - generatemanwoman = True - if item[0] == 'subject_manwomanrelation' and item[1] == 'on': - generatemanwomanrelation = True - if item[0] == 'subject_fictional' and item[1] == 'on': - generatefictionalcharacter = True - if item[0] == 'subject_nonfictional' and item[1] == 'on': - generatenonfictionalcharacter = True - if item[0] == 'subject_humanoid' and item[1] == 'on': - generatehumanoids = True - if item[0] == 'subject_job' and item[1] == 'on': - generatejob = True + if item[0] == 'subject_manwoman' and item[1] != 'on': + generatemanwoman = False + if item[0] == 'subject_manwomanrelation' and item[1] != 'on': + generatemanwomanrelation = False + if item[0] == 'subject_fictional' and item[1] != 'on': + generatefictionalcharacter = False + if item[0] == 'subject_nonfictional' and item[1] != 'on': + generatenonfictionalcharacter = False + if item[0] == 'subject_humanoid' and item[1] != 'on': + generatehumanoids = False + if item[0] == 'subject_job' and item[1] != 'on': + generatejob = False # landscape - if item[0] == 'subject_landscape' and item[1] == 'on': - generatelandscape = True + if item[0] == 'subject_landscape' and item[1] != 'on': + generatelandscape = False # concept - if item[0] == 'subject_event' and item[1] == 'on': - generateevent = True - if item[0] == 'subject_concept' and item[1] == 'on': - generateconcepts = True - if item[0] == 'poemline' and item[1] == 'on': - generatepoemline = True - if item[0] == 'songline' and item[1] == 'on': - generatesongline = True + if item[0] == 'subject_event' and item[1] != 'on': + generateevent = False + if item[0] == 'subject_concept' and item[1] != 'on': + generateconcepts = False + if item[0] == 'poemline' and item[1] != 'on': + generatepoemline = False + if item[0] == 'songline' and item[1] != 'on': + generatesongline = False + # main list stuff + if item[0] == 'custominputprefixrepeats': + custominputprefixrepeats = int(item[1]) + if item[0] == 'custominputprefixchance': + custominputprefixchance = item[1] + if(custominputprefixchance == 'never'): + generatecustominputprefix = False + if item[0] == 'imagetypechance': + imagetypechance = item[1] + if(imagetypechance == 'never'): + generateimagetype = False + if item[0] == 'imagetypequalitychance': + imagetypequalitychance = item[1] + if(imagetypequalitychance == 'never'): + generateimagetypequality = False + if item[0] == 'minilocationadditionchance': + minilocationadditionchance = item[1] + if item[0] == 'artmovementprefixchance': + artmovementprefixchance = item[1] + if item[0] == 'minivomitprefix1chance': + minivomitprefix1chance = item[1] + if item[0] == 'minivomitprefix2chance': + minivomitprefix2chance = item[1] + + if item[0] == 'shotsizechance': + shotsizechance = item[1] + + if item[0] == 'subjectdescriptor1chance': + subjectdescriptor1chance = item[1] + if item[0] == 'subjectdescriptor2chance': + subjectdescriptor2chance = item[1] + if item[0] == 'subjectbodytypechance': + subjectbodytypechance = item[1] + if item[0] == 'subjectculturechance': + subjectculturechance = item[1] generatevehicle = bool(vehiclelist) and generatevehicle @@ -421,9 +476,9 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all generateminilocationaddition = bool(minilocationadditionslist) and not specialmode generateminivomit = bool(minivomitlist) and not specialmode - generateimagetypequality = bool(imagetypequalitylist) and not specialmode + generateimagetypequality = bool(imagetypequalitylist) and not specialmode and generateimagetypequality generateoveralladdition = bool(overalladditionlist) and not specialmode - generateimagetype = bool(imagetypelist) and not specialmode + generateimagetype = bool(imagetypelist) and not specialmode and generateimagetype # Smart subject logic @@ -637,8 +692,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # custom prefix list - for i in range(2): - if(uncommon_dist(insanitylevel) and generatecustominputprefix == True): + for i in range(custominputprefixrepeats): + if(chance_roll(insanitylevel, custominputprefixchance) and generatecustominputprefix == True): completeprompt += random.choice(custominputprefixlist) + ", " @@ -647,7 +702,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all insanitylevel = random.randint(1, 10) # 10 = add everything, 1 is add almost nothing insanitylevel3 = int((insanitylevel/3) + 1.20) - print("Setting insanity level to " + str(insanitylevel)) + # print("Setting insanity level to " + str(insanitylevel)) # main chooser: 0 object, 1 animal, 2 humanoid, 3 landscape, 4 event/concept #mainchooserlist = ["object","animal","humanoid", "landscape", "concept"] @@ -915,14 +970,14 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all othertype = 1 completeprompt += random.choice(othertypelist) - if(imagetype == "all" and normal_dist(insanitylevel) and amountofimagetypes <= 1): + if(imagetype == "all" and chance_roll(insanitylevel, imagetypechance) and amountofimagetypes <= 1): amountofimagetypes = 1 for i in range(amountofimagetypes): # one in 6 images is a complex/other type - if(rare_dist(insanitylevel) and generateimagetypequality): + if(chance_roll(insanitylevel, imagetypequalitychance) and generateimagetypequality): completeprompt += "-imagetypequality- " if(random.randint(0,5) < 5): completeprompt += " -imagetype-, " @@ -941,22 +996,22 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all ### here we can do some other stuff to spice things up - if(unique_dist(insanitylevel) and generateminilocationaddition == True): + if(chance_roll(insanitylevel, minilocationadditionchance) and generateminilocationaddition == True): completeprompt += " -minilocationaddition-, " - if(unique_dist(insanitylevel) and generateartmovement == True): + if(chance_roll(insanitylevel, artmovementprefixchance) and generateartmovement == True): generateartmovement = False completeprompt += " -artmovement-, " - if(rare_dist(insanitylevel) and generateminivomit == True): + if(chance_roll(insanitylevel, minivomitprefix1chance) and generateminivomit == True): completeprompt += " -minivomit-, " - if(unique_dist(insanitylevel) and generateminivomit == True): + if(chance_roll(insanitylevel, minivomitprefix2chance) and generateminivomit == True): completeprompt += " -minivomit-, " # start shot size - if(mainchooser in ["object", "animal", "humanoid", "concept"] and othertype == 0 and "portrait" not in completeprompt and generateshot == True and uncommon_dist(insanitylevel)): + if(mainchooser in ["object", "animal", "humanoid", "concept"] and othertype == 0 and "portrait" not in completeprompt and generateshot == True and chance_roll(insanitylevel,shotsizechance)): completeprompt += "-shotsize- of a " elif("portrait" in completeprompt and generateshot == True): completeprompt += " ,close up of a " @@ -971,16 +1026,16 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # start with descriptive qualities # Common to have 1 description, uncommon to have 2 - if(common_dist(insanitylevel) and generatedescriptors == True): + if(chance_roll(insanitylevel, subjectdescriptor1chance) and generatedescriptors == True): completeprompt += "-descriptor- " - if(uncommon_dist(insanitylevel) and generatedescriptors == True): + if(chance_roll(insanitylevel, subjectdescriptor2chance) and generatedescriptors == True): completeprompt += "-descriptor- " - if(subjectchooser in ["animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] and normal_dist(insanitylevel) and generatebodytype == True): + if(subjectchooser in ["animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, subjectbodytypechance) and generatebodytype == True): completeprompt += "-bodytype- " - if(subjectchooser in ["object","animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] and normal_dist(insanitylevel) and generatedescriptors == True): + if(subjectchooser in ["object","animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, subjectculturechance) and generatedescriptors == True): completeprompt += "-culture- " if(mainchooser == "object"): diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index 8f23610..ed27d1e 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -25,4 +25,26 @@ subject_landscape;on subject_event;on subject_concept;on subject_poemline;on -subject_songline;on \ No newline at end of file +subject_songline;on +#----; +# other main lists, in order of appearance; +# setting the random chance, for normal generation; +# these can be, in order of most appearing to least appearing; +# always, common, normal, uncommon, rare, legendary, unique, extraordinary, novel, never; +custominputprefixrepeats;2 +custominputprefixchance;uncommon +imagetypechance;normal +imagetypequalitychance;rare +# some prefixes that happen rarely; +minilocationadditionchance;unique +artmovementprefixchance;unique +minivomitprefix1chance;rare +minivomitprefix2chance;unique +# shot size generation; +shotsizechance;uncommon +# subject specific stuff; +subjectdescriptor1chance;common +subjectdescriptor2chance;uncommon +subjectbodytypechance;normal +subjectculturechance;normal + diff --git a/prompttester.py b/prompttester.py index 9b55c30..834f026 100644 --- a/prompttester.py +++ b/prompttester.py @@ -46,4 +46,4 @@ def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", im print("") print("All done!") -generateprompts(10,10,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100) \ No newline at end of file +generateprompts(10,5,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100) \ No newline at end of file diff --git a/random_functions.py b/random_functions.py index ee6a63d..50e394c 100644 --- a/random_functions.py +++ b/random_functions.py @@ -36,4 +36,34 @@ def novel_dist(insanitylevel): roll = (random.randint(1, 500)= 10): + return True + roll = random.randint(1, set_number) < insanitylevel + return roll + else: + raise ValueError(f"Invalid chance value: {chance}") From 9119914537a2528f86efa66c702381b9c6406c2f Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 09:35:51 +0200 Subject: [PATCH 03/18] some more config stuff --- build_dynamic_prompt.py | 49 ++++++++++++++++++++++++------ csvfiles/config/default_config.csv | 11 +++++++ csvfiles/jobs.csv | 4 ++- 3 files changed, 54 insertions(+), 10 deletions(-) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index 7b4766c..24e27a0 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -187,6 +187,17 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all subjectdescriptor2chance = 'uncommon' subjectbodytypechance = 'normal' subjectculturechance = 'normal' + subjectconceptsuffixchance = 'unique' + + subjectlandscapeinsideshotchance = 'unique' + subjectlandscapeaddonlocationchance = 'normal' + subjectlandscapeaddonlocationdescriptorchance = 'rare' + subjectlandscapeaddonlocationculturechance = 'rare' + + objectadditionsrepeats = 2 + objectadditionschance = 'uncommon' + humanadditionchance = 'rare' + overalladditionchance = 'extraordinary' @@ -266,6 +277,26 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all subjectbodytypechance = item[1] if item[0] == 'subjectculturechance': subjectculturechance = item[1] + if item[0] == 'subjectconceptsuffixchance': + subjectconceptsuffixchance = item[1] + + if item[0] == 'subjectlandscapeinsideshotchance': + subjectlandscapeinsideshotchance = item[1] + if item[0] == 'subjectlandscapeaddonlocationchance': + subjectlandscapeaddonlocationchance = item[1] + if item[0] == 'subjectlandscapeaddonlocationdescriptorchance': + subjectlandscapeaddonlocationdescriptorchance = item[1] + if item[0] == 'subjectlandscapeaddonlocationculturechance': + subjectlandscapeaddonlocationculturechance = item[1] + + if item[0] == 'objectadditionsrepeats': + objectadditionsrepeats = int(item[1]) + if item[0] == 'objectadditionschance': + objectadditionschance = item[1] + if item[0] == 'humanadditionchance': + humanadditionchance = item[1] + if item[0] == 'overalladditionchance': + overalladditionchance = item[1] generatevehicle = bool(vehiclelist) and generatevehicle @@ -1163,7 +1194,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all completeprompt += " " + givensubject + " " # sometimes add a suffix for more fun! - if( (mainchooser == "humanoid" or mainchooser == "animal" or mainchooser == "object") and unique_dist(insanitylevel)): + if( (mainchooser == "humanoid" or mainchooser == "animal" or mainchooser == "object") and chance_roll(insanitylevel, subjectconceptsuffixchance)): completeprompt += " of -conceptsuffix- " if(subjectchooser == "landscape"): @@ -1187,15 +1218,15 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all hybridorswap = "" # shots from inside can create cool effects in landscapes - if(unique_dist(insanitylevel)): + if(chanceroll(insanitylevel, subjectlandscapeaddonlocationchance)): insideshot = 1 completeprompt += " from inside of a -addontolocationinside- " - if(normal_dist(insanitylevel) and insideshot == 0): + if(chance_roll(insanitylevel, subjectlandscapeaddonlocationchance) and insideshot == 0): completeprompt += " and " - if(rare_dist(insanitylevel)): + if(chance_roll(insanitylevel, subjectlandscapeaddonlocationdescriptorchance)): completeprompt += "-descriptor- " - if(rare_dist(insanitylevel)): + if(chance_roll(insanitylevel, subjectlandscapeaddonlocationculturechance)): completeprompt += "-culture- " #addontolocation = [locationlist,buildinglist, vehiclelist] @@ -1221,20 +1252,20 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # object additions - for i in range(2): - if(mainchooser == "object" and uncommon_dist(insanitylevel) and generateobjectaddition == True): + for i in range(objectadditionsrepeats): + if(mainchooser == "object" and chance_roll(insanitylevel, objectadditionschance) and generateobjectaddition == True): completeprompt += ", -objectaddition- , " # riding an animal, holding an object or driving a vehicle, rare - if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and rare_dist(insanitylevel) and generatehumanaddition == True): + if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, humanadditionchance) and generatehumanaddition == True): humanspecial = 1 completeprompt += "-humanaddition- " completeprompt += ", " # unique additions for all types: - if(extraordinary_dist(insanitylevel) and generateoveralladdition == True): + if(chance_roll(insanitylevel, overalladditionchance) and generateoveralladdition == True): completeprompt += "-overalladdition- " diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index ed27d1e..cc815a3 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -47,4 +47,15 @@ subjectdescriptor1chance;common subjectdescriptor2chance;uncommon subjectbodytypechance;normal subjectculturechance;normal +subjectconceptsuffixchance;unique +# subjectlandscape specific stuff; +subjectlandscapeinsideshotchance;unique +subjectlandscapeaddonlocationchance;normal +subjectlandscapeaddonlocationdescriptorchance;rare +subjectlandscapeaddonlocationculturechance;rare +# all additions; +objectadditionsrepeats;2 +objectadditionschance;uncommon +humanadditionchance;rare +overalladditionchance;extraordinary diff --git a/csvfiles/jobs.csv b/csvfiles/jobs.csv index 56dce67..25e904d 100644 --- a/csvfiles/jobs.csv +++ b/csvfiles/jobs.csv @@ -365,4 +365,6 @@ Cowgirl Pop Singer President Construction worker -Idol \ No newline at end of file +Idol +Nerd +Geek \ No newline at end of file From 37c4e3e269fd7d53ba6533bad73683b0e5a01517 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 10:11:39 +0200 Subject: [PATCH 04/18] more config stuff, almost done --- build_dynamic_prompt.py | 150 +++++++++++++++++++++++------ csvfiles/config/default_config.csv | 36 ++++++- random_functions.py | 6 +- 3 files changed, 159 insertions(+), 33 deletions(-) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index 24e27a0..687c0ad 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -199,6 +199,37 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all humanadditionchance = 'rare' overalladditionchance = 'extraordinary' + custominputmidrepeats = 2 + custominputmidchance = 'uncommon' + minivomitmidchance = 'unique' + + outfitchance = 'normal' + posechance = 'uncommon' + hairchance = 'normal' + accessorychance = 'normal' + humanoidinsideshotchance = 'legendary' + humanoidbackgroundchance = 'uncommon' + + landscapeminilocationchance = 'uncommon' + generalminilocationchance = 'rare' + + timperiodchance = 'normal' + focuschance = 'normal' + directionchance = 'normal' + moodchance = 'normal' + minivomitsuffixchance = 'unique' + artmovementchance = 'normal' + lightingchance = 'normal' + photoadditionchance = 'common' + lenschance = 'normal' + colorschemechance = 'normal' + vomit1chance = 'uncommon' + vomit2chance= 'uncommon' + greatworkchance = 'novel' + poemlinechance = 'novel' + songlinechance = 'novel' + quality1chance = 'uncommon' + quality2chance = 'uncommon' for item in config: @@ -298,6 +329,66 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all if item[0] == 'overalladditionchance': overalladditionchance = item[1] + if item[0] == 'custominputmidrepeats': + custominputmidrepeats = int(item[1]) + if item[0] == 'custominputmidchance': + custominputmidchance = item[1] + if item[0] == 'minivomitmidchance': + minivomitmidchance = item[1] + + if item[0] == 'outfitchance': + outfitchance = item[1] + if item[0] == 'posechance': + posechance = item[1] + if item[0] == 'hairchance': + hairchance = item[1] + if item[0] == 'accessorychance': + accessorychance = item[1] + if item[0] == 'humanoidinsideshotchance': + humanoidinsideshotchance = item[1] + if item[0] == 'humanoidbackgroundchance': + humanoidbackgroundchance = item[1] + + if item[0] == 'landscapeminilocationchance': + landscapeminilocationchance = item[1] + if item[0] == 'generalminilocationchance': + generalminilocationchance = item[1] + + if item[0] == 'timperiodchance': + timperiodchance = item[1] + if item[0] == 'focuschance': + focuschance = item[1] + if item[0] == 'directionchance': + directionchance = item[1] + if item[0] == 'moodchance': + moodchance = item[1] + if item[0] == 'minivomitsuffixchance': + minivomitsuffixchance = item[1] + if item[0] == 'artmovementchance': + artmovementchance = item[1] + if item[0] == 'lightingchance': + lightingchance = item[1] + if item[0] == 'photoadditionchance': + photoadditionchance = item[1] + if item[0] == 'lenschance': + lenschance = item[1] + if item[0] == 'colorschemechance': + colorschemechance = item[1] + if item[0] == 'vomit1chance': + vomit1chance = item[1] + if item[0] == 'vomit2chance': + vomit2chance = item[1] + if item[0] == 'greatworkchance': + greatworkchance = item[1] + if item[0] == 'poemlinechance': + poemlinechance = item[1] + if item[0] == 'songlinechance': + songlinechance = item[1] + if item[0] == 'quality1chance': + quality1chance = item[1] + if item[0] == 'quality2chance': + quality2chance = item[1] + generatevehicle = bool(vehiclelist) and generatevehicle generateobject = bool(objectlist) and generateobject @@ -1295,110 +1386,109 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # completeprompt += ", with " + random.choice(skintypelist) + " skin, " # custom mid list - if(uncommon_dist(insanitylevel) and generatecustominputmid == True): - completeprompt += random.choice(custominputmidlist) + ", " - if(uncommon_dist(insanitylevel)): + for i in range(custominputmidrepeats): + if(chance_roll(insanitylevel, custominputmidchance) and generatecustominputmid == True): completeprompt += random.choice(custominputmidlist) + ", " # add in some more mini vomits - if(unique_dist(insanitylevel) and generateminivomit == True): + if(chance_roll(insanitylevel, minivomitmidchance) and generateminivomit == True): completeprompt += " -minivomit-, " # outfit builder - if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and normal_dist(insanitylevel) and generateoutfit == True and humanspecial != 1): + if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, outfitchance) and generateoutfit == True and humanspecial != 1): completeprompt += ", wearing " + random.choice(buildoutfitlist) + ", " - if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and uncommon_dist(insanitylevel) and humanspecial != 1 and generatepose == True): + if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, posechance) and humanspecial != 1 and generatepose == True): completeprompt += random.choice(poselist) + ", " - if(subjectchooser in ["human","job","fictional", "non fictional", "humanoid", "manwomanrelation"] and normal_dist(insanitylevel) and generatehairstyle == True): + if(subjectchooser in ["human","job","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, hairchance) and generatehairstyle == True): completeprompt += random.choice(buildhairlist) + ", " - if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and normal_dist(insanitylevel) and generateaccessorie == True and generateaccessories == True): + if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, accessorychance) and generateaccessorie == True and generateaccessories == True): completeprompt += random.choice(buildaccessorielist) + ", " - if(legendary_dist(insanitylevel) and subjectchooser not in ["landscape", "concept"] and generateinsideshot == True): + if(chance_roll(insanitylevel, humanoidinsideshotchance) and subjectchooser not in ["landscape", "concept"] and generateinsideshot == True): insideshot = 1 completeprompt += random.choice(insideshotlist) + ", " - if(subjectchooser not in ["landscape", "concept"] and humanspecial != 1 and insideshot == 0 and uncommon_dist(insanitylevel) and generatebackground == True): + if(subjectchooser not in ["landscape", "concept"] and humanspecial != 1 and insideshot == 0 and chance_roll(insanitylevel, humanoidbackgroundchance) and generatebackground == True): completeprompt += random.choice(backgroundtypelist) + ", " # minilocation bit - if(subjectchooser in ["landscape"] and uncommon_dist(insanitylevel) and generateminilocationaddition == True): + if(subjectchooser in ["landscape"] and chance_roll(insanitylevel, landscapeminilocationchance) and generateminilocationaddition == True): completeprompt += " -minilocationaddition-, " - if(rare_dist(insanitylevel) and generateminilocationaddition == True): + if(chance_roll(insanitylevel, generalminilocationchance) and generateminilocationaddition == True): completeprompt += " -minilocationaddition-, " # landscapes it is nice to always have a time period - if(normal_dist(insanitylevel) or subjectchooser=="landscape"): + if(chance_roll(insanitylevel, timperiodchance) or subjectchooser=="landscape"): if(generatetimeperiod == True): completeprompt += "-timeperiod-, " - if(mainchooser not in ["landscape"] and rare_dist(insanitylevel) and generatefocus == True): + if(mainchooser not in ["landscape"] and chance_roll(insanitylevel, focuschance) and generatefocus == True): completeprompt += "-focus-, " # others - if(normal_dist(insanitylevel) and generatedirection == True): + if(chance_roll(insanitylevel, directionchance) and generatedirection == True): completeprompt += "-direction-, " - if(normal_dist(insanitylevel) and generatemood == True): + if(chance_roll(insanitylevel, moodchance) and generatemood == True): completeprompt += "-mood-, " # add in some more mini vomits - if(unique_dist(insanitylevel) and generateminivomit == True): + if(chance_roll(insanitylevel, minivomitsuffixchance) and generateminivomit == True): completeprompt += " -minivomit-, " - if(normal_dist(insanitylevel) and generateartmovement == True): + if(chance_roll(insanitylevel, artmovementchance) and generateartmovement == True): completeprompt += "-artmovement-, " - if(normal_dist(insanitylevel) and generatelighting == True): + if(chance_roll(insanitylevel, lightingchance) and generatelighting == True): completeprompt += "-lighting-, " # determine wether we have a photo or not if("photo" in completeprompt.lower()): isphoto = 1 - if(common_dist(insanitylevel) and isphoto == 1 and generatephotoaddition == True): + if(chance_roll(insanitylevel, photoadditionchance) and isphoto == 1 and generatephotoaddition == True): completeprompt += random.choice(photoadditionlist) + ", " if(isphoto == 1 and generatecamera == True): completeprompt += "-camera-, " - if(normal_dist(insanitylevel) or isphoto == 1): + if(chance_roll(insanitylevel, lenschance) or isphoto == 1): if(generatelens == True): completeprompt += "-lens-, " - if(normal_dist(insanitylevel) and generatecolorscheme == True): - completeprompt += random.choice(colorschemelist) + ", " + if(chance_roll(insanitylevel, colorschemechance) and generatecolorscheme == True): + completeprompt += "-colorscheme-, " # vomit some cool/wierd things into the prompt - if(uncommon_dist(insanitylevel) and generatevomit == True): + if(chance_roll(insanitylevel, vomit1chance) and generatevomit == True): completeprompt += "-vomit-, " - if(uncommon_dist(insanitylevel)): + if(chance_roll(insanitylevel, vomit2chance)): completeprompt += "-vomit-, " #adding a great work of art, like starry night has cool effects. But this should happen only very rarely. - if(novel_dist(insanitylevel) and generategreatwork == True): + if(chance_roll(insanitylevel, greatworkchance) and generategreatwork == True): completeprompt += " in the style of -greatwork-, " #adding a poemline. But this should happen only very rarely. - if(novel_dist(insanitylevel) and generatepoemline == True): + if(chance_roll(insanitylevel, poemlinechance) and generatepoemline == True): completeprompt += " \"-poemline-\", " #adding a songline. But this should happen only very rarely. - if(novel_dist(insanitylevel) and generatesongline == True): + if(chance_roll(insanitylevel, songlinechance) and generatesongline == True): completeprompt += " \"-songline-\", " # everyone loves the adding quality. The better models don't need this, but lets add it anyway - if(uncommon_dist(insanitylevel) and generatequality == True): + if(chance_roll(insanitylevel, quality1chance) and generatequality == True): completeprompt += "-quality-, " - if(uncommon_dist(insanitylevel)): + if(chance_roll(insanitylevel, quality2chance)): completeprompt += "-quality-, " diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index cc815a3..83b3d58 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -58,4 +58,38 @@ objectadditionsrepeats;2 objectadditionschance;uncommon humanadditionchance;rare overalladditionchance;extraordinary - +# humanoid other stuff; +emojichance;legendary +joboractivitychance;normal +# things in the middle of the prompt; +custominputmidrepeats;2 +custominputmidchance;uncommon +minivomitmidchance;unique +# humanoid main stuff; +outfitchance;normal +posechance;uncommon +hairchance;normal +accessorychance;normal +humanoidinsideshotchance;legendary +humanoidbackgroundchance;uncommon +# minilocation stuff; +landscapeminilocationchance;uncommon +generalminilocationchance;rare +# general stuff add the end of the prompt; +timperiodchance;normal +focuschance;normal +directionchance;normal +moodchance;normal +minivomitsuffixchance;unique +artmovementchance;normal +lightingchance;normal +photoadditionchance;common +lenschance;normal +colorschemechance;normal +vomit1chance;uncommon +vomit2chance;uncommon +greatworkchance;novel +poemlinechance;novel +songlinechance;novel +quality1chance;uncommon +quality2chance;uncommon \ No newline at end of file diff --git a/random_functions.py b/random_functions.py index 50e394c..579b42f 100644 --- a/random_functions.py +++ b/random_functions.py @@ -58,12 +58,14 @@ def chance_roll(insanitylevel, chance): properties = chance_mapping[chance] set_number = properties['set_number'] message = properties['message'] - if(message != ""): - print(message) # if we have insanity level of 10, then every under rare is alwas true if (set_number <= 35 and insanitylevel >= 10): + if(message != ""): + print(message) return True roll = random.randint(1, set_number) < insanitylevel + if(message != "" and roll == True): + print(message) return roll else: raise ValueError(f"Invalid chance value: {chance}") From 7fb6edbada3bae78207e24623889655f45eee5c3 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 10:22:09 +0200 Subject: [PATCH 05/18] config file is done? --- build_dynamic_prompt.py | 43 ++++++++++++++++++++++++------ csvfiles/config/default_config.csv | 8 +++++- 2 files changed, 42 insertions(+), 9 deletions(-) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index 687c0ad..331567a 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -199,6 +199,9 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all humanadditionchance = 'rare' overalladditionchance = 'extraordinary' + emojichance = 'legendary' + joboractivitychance = 'normal' + custominputmidrepeats = 2 custominputmidchance = 'uncommon' minivomitmidchance = 'unique' @@ -231,6 +234,13 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all quality1chance = 'uncommon' quality2chance = 'uncommon' + customstyle1chance = 'uncommon' + customstyle2chance = 'uncommon' + + custominputsuffixrepeats = 2 + custominputsuffixchance = 'uncommon' + + artistsatbackchance = 'uncommon' for item in config: # objects @@ -329,6 +339,11 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all if item[0] == 'overalladditionchance': overalladditionchance = item[1] + if item[0] == 'emojichance': + emojichance = item[1] + if item[0] == 'joboractivitychance': + joboractivitychance = item[1] + if item[0] == 'custominputmidrepeats': custominputmidrepeats = int(item[1]) if item[0] == 'custominputmidchance': @@ -389,6 +404,19 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all if item[0] == 'quality2chance': quality2chance = item[1] + if item[0] == 'customstyle1chance': + customstyle1chance = item[1] + if item[0] == 'customstyle2chance': + customstyle2chance = item[1] + + if item[0] == 'custominputsuffixrepeats': + custominputsuffixrepeats = int(item[1]) + if item[0] == 'custominputsuffixchance': + custominputsuffixchance = item[1] + + if item[0] == 'artistsatbackchance': + artistsatbackchance = item[1] + generatevehicle = bool(vehiclelist) and generatevehicle generateobject = bool(objectlist) and generateobject @@ -989,7 +1017,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # start artist part artistsplacement = "front" - if(uncommon_dist(insanitylevel) and onlyartists == False): + if(chance_roll(insanitylevel, artistsatbackchance) and onlyartists == False): artistsplacement = "back" if(artists != "none" and artistsplacement == "front" and generateartist == True): @@ -1365,7 +1393,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # SD understands emoji's. Can be used to manipulate facial expressions. # emoji, legendary - if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and legendary_dist(insanitylevel) and generateemoji== True): + if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, emojichance) and generateemoji== True): completeprompt += "-emoji-, " @@ -1376,7 +1404,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # Job # either go job or activity, not both - if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and normal_dist(insanitylevel) and humanspecial != 1 and generatesubject == True): + if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, joboractivitychance) and humanspecial != 1 and generatesubject == True): joboractivitylist = [joblist,humanactivitylist] completeprompt += random.choice(random.choice(joboractivitylist)) + ", " @@ -1622,16 +1650,15 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all step = step + 1 # custom style list - if(uncommon_dist(insanitylevel) and generatestyle == True): + if(chance_roll(insanitylevel, customstyle1chance) and generatestyle == True): completeprompt += "-styletilora-, " - if(uncommon_dist(insanitylevel)): + if(chance_roll(insanitylevel, customstyle2chance)): completeprompt += "-styletilora-, " # custom suffix list - if(uncommon_dist(insanitylevel) and generatecustominputsuffix == True): - completeprompt += random.choice(custominputsuffixlist) + ", " - if(uncommon_dist(insanitylevel)): + for i in range(custominputsuffixrepeats): + if(chance_roll(insanitylevel, custominputsuffixchance) and generatecustominputsuffix == True): completeprompt += random.choice(custominputsuffixlist) + ", " diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index 83b3d58..6f2a8e7 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -92,4 +92,10 @@ greatworkchance;novel poemlinechance;novel songlinechance;novel quality1chance;uncommon -quality2chance;uncommon \ No newline at end of file +quality2chance;uncommon +# custom style list (lora and tis); +customstyle1chance;uncommon +customstyle2chance;uncommon +# suffix custom list# +custominputsuffixrepeats;2 +custominputsuffixchance;uncommon \ No newline at end of file From 402577305aa2171ba7ded7cc9bf8f8f8fbbde85b Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 10:31:11 +0200 Subject: [PATCH 06/18] create config file on startup --- scripts/onebuttonprompt.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index c1c9517..3b9aad5 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -13,6 +13,7 @@ from modules.shared import opts, cmd_opts, state from build_dynamic_prompt import * from main import * from model_lists import * +from csv_reader import * subjects = ["all","object","animal","humanoid", "landscape", "concept"] artists = ["all", "none", "popular", "greg mode", "3D", "abstract", "angular", "anime" ,"architecture", "art nouveau", "art deco", "baroque", "bauhaus", "cartoon", "character", "children's illustration", "cityscape", "clean", "cloudscape", "collage", "colorful", "comics", "cubism", "dark", "detailed", "digital", "expressionism", "fantasy", "fashion", "fauvism", "figurativism", "gore", "graffiti", "graphic design", "high contrast", "horror", "impressionism", "installation", "landscape", "light", "line drawing", "low contrast", "luminism", "magical realism", "manga", "melanin", "messy", "monochromatic", "nature", "nudity", "photography", "pop art", "portrait", "primitivism", "psychedelic", "realism", "renaissance", "romanticism", "scene", "sci-fi", "sculpture", "seascape", "space", "stained glass", "still life", "storybook realism", "street art", "streetscape", "surrealism", "symbolism", "textile", "ukiyo-e", "vibrant", "watercolor", "whimsical"] @@ -64,6 +65,8 @@ for filename in os.listdir(userfilesfolder): # directly insert into the artists list artists.insert(2, name) +# on startup, check if we have a config file, or else create it +load_config_csv() class Script(scripts.Script): From 9b681c6cb7c29de9b8b4f6331dc45e9db99ee226 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 10:31:29 +0200 Subject: [PATCH 07/18] Update default_config.csv --- csvfiles/config/default_config.csv | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index 6f2a8e7..cef759a 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -98,4 +98,6 @@ customstyle1chance;uncommon customstyle2chance;uncommon # suffix custom list# custominputsuffixrepeats;2 -custominputsuffixchance;uncommon \ No newline at end of file +custominputsuffixchance;uncommon +# artists stuff +artistsatbackchance;uncommon \ No newline at end of file From d9fc65013a6539f024014edff41438e5bd6df11c Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 12:51:37 +0200 Subject: [PATCH 08/18] Work on seperating male and female --- build_dynamic_prompt.py | 12 +- csv_reader.py | 32 +- csvfiles/config/default_config.csv | 4 +- csvfiles/fictional characters.csv | 1017 ++++++++++++++-------------- csvfiles/genderdescription.csv | 7 +- csvfiles/malefemale.csv | 5 +- csvfiles/manwoman.csv | 5 +- csvfiles/manwomanrelations.csv | 33 +- 8 files changed, 567 insertions(+), 548 deletions(-) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index 331567a..fa19d69 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -10,7 +10,7 @@ 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): +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"): # load the config file @@ -32,7 +32,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all animallist = csv_to_list("animals",antilist) materiallist = csv_to_list("materials",antilist) objectlist = csv_to_list("objects",antilist) - fictionallist = csv_to_list("fictional characters",antilist) + fictionallist = csv_to_list(csvfilename="fictional characters",antilist=antilist,skipheader=True,gender=gender) nonfictionallist = csv_to_list("nonfictional characters",antilist) conceptsuffixlist = csv_to_list("concept_suffix",antilist) buildinglist = csv_to_list("buildings",antilist) @@ -62,8 +62,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all joblist = csv_to_list("jobs",antilist) lenslist = csv_to_list("lenses",antilist) lightinglist = csv_to_list("lighting",antilist) - malefemalelist = csv_to_list("malefemale",antilist) - manwomanlist = csv_to_list("manwoman",antilist) + malefemalelist = csv_to_list(csvfilename="malefemale",antilist=antilist,skipheader=True,gender=gender) + manwomanlist = csv_to_list(csvfilename="manwoman",antilist=antilist,skipheader=True,gender=gender) moodlist = csv_to_list("moods",antilist) othertypelist = csv_to_list("othertypes",antilist) poselist = csv_to_list("poses",antilist) @@ -72,7 +72,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all timeperiodlist = csv_to_list("timeperiods",antilist) vomitlist = csv_to_list("vomit",antilist) foodlist = csv_to_list("foods", antilist) - genderdescriptionlist = csv_to_list("genderdescription", antilist) + genderdescriptionlist = csv_to_list(csvfilename="genderdescription",antilist=antilist,skipheader=True,gender=gender) minilocationlist = csv_to_list("minilocations", antilist) minioutfitlist = csv_to_list("minioutfits", antilist) seasonlist = csv_to_list("seasons", antilist) @@ -85,7 +85,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all poemlinelist = csv_to_list("poemlines", antilist) songlinelist = csv_to_list("songlines", antilist) musicgenrelist = csv_to_list("musicgenres", antilist) - manwomanrelationlist = csv_to_list("manwomanrelations", antilist) + manwomanrelationlist = csv_to_list(csvfilename="manwomanrelations",antilist=antilist,skipheader=True,gender=gender) waterlocationlist = csv_to_list("waterlocations", antilist) containerlist = csv_to_list("containers", antilist) diff --git a/csv_reader.py b/csv_reader.py index ffc146b..4066fbf 100644 --- a/csv_reader.py +++ b/csv_reader.py @@ -19,7 +19,7 @@ def add_from_csv(completeprompt, csvfilename, addcomma, prefix, suffix): return ", ".join([completeprompt,addtoprompt]) return " ".join([completeprompt,addtoprompt]) -def csv_to_list(csvfilename, antilist=[], directory="./csvfiles/", lowerandstrip=0, delimiter=";", listoflistmode = False): +def csv_to_list(csvfilename, antilist=[], directory="./csvfiles/", lowerandstrip=0, delimiter=";", listoflistmode = False, skipheader = False, gender = "all"): userfilesdirectory = "./userfiles/" userfileaddonname = csvfilename + "_addon.csv" userfilereplacename = csvfilename + "_replace.csv" @@ -40,30 +40,44 @@ def csv_to_list(csvfilename, antilist=[], directory="./csvfiles/", lowerandstrip if(os.path.isfile(full_path + csvfilename + ".csv")): with open(full_path + csvfilename + ".csv", "r", newline="",encoding="utf8") as file: reader = csv.reader(file, delimiter=delimiter) + if(skipheader==True): + next(reader) if(listoflistmode==True): csvlist = list(reader) else: for row in reader: value = row[0] - if(value.lower().strip() not in antilist): - if(lowerandstrip == 1): - csvlist.append(row[0].lower().strip()) - csvlist.append(row[0]) + if( + (gender != "all" and row[1] == gender) + or gender == "all" + ): + if(value.lower().strip() not in antilist): + if(lowerandstrip == 1): + csvlist.append(row[0].lower().strip()) + else: + csvlist.append(row[0]) # do the add ons! if(directory=="./csvfiles/" or directory=="./csvfiles/special_lists/"): if(os.path.isfile(userfilesfolder + csvfilename + "_addon" + ".csv")): with open(userfilesfolder + csvfilename + "_addon" + ".csv", "r", newline="",encoding="utf8") as file: reader = csv.reader(file, delimiter=",") + if(skipheader==True): + next(reader) if(listoflistmode==True): csvlist.append(list(reader)) else: for row in reader: value = row[0] - if(value.lower().strip() not in antilist): - if(lowerandstrip == 1): - csvlist.append(row[0].lower().strip()) - csvlist.append(row[0]) + if( + (gender != "all" and row[1] == gender) + or gender == "all" + ): + if(value.lower().strip() not in antilist): + if(lowerandstrip == 1): + csvlist.append(row[0].lower().strip()) + else: + csvlist.append(row[0]) # remove duplicates, but check only for lowercase stuff diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index cef759a..a308b13 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -96,8 +96,8 @@ quality2chance;uncommon # custom style list (lora and tis); customstyle1chance;uncommon customstyle2chance;uncommon -# suffix custom list# +# suffix custom list; custominputsuffixrepeats;2 custominputsuffixchance;uncommon -# artists stuff +# artists stuff; artistsatbackchance;uncommon \ No newline at end of file diff --git a/csvfiles/fictional characters.csv b/csvfiles/fictional characters.csv index 76dd2eb..a68f51c 100644 --- a/csvfiles/fictional characters.csv +++ b/csvfiles/fictional characters.csv @@ -1,508 +1,509 @@ -Harry Potter -Frodo Baggins -Luke Skywalker -Katniss Everdeen -Sherlock Holmes -James Bond -Wonder Woman -Batman -Spider-Man -Superman -Captain America -Iron Man -The Hulk -Thor -Black Widow -Elsa from Frozen -Mickey Mouse -Bugs Bunny -Pikachu -Sonic the Hedgehog -Lara Croft -Gandalf -Aladdin -Cinderella -Ariel from The Little Mermaid -Belle from Beauty and the Beast -Jasmine from Aladdin -Mulan -Tinker Bell -Peter Pan -Captain Hook -Winnie the Pooh -Donkey from Shrek -Fiona from Shrek -Pinocchio -The Grinch -Scrooge from A Christmas Carol -The Cat in the Hat -The Lorax -The Big Bad Wolf -Little Red Riding Hood -Puss in Boots -Rapunzel -Sleeping Beauty -Snow White -Maleficent -Ursula from The Little Mermaid -Jafar from Aladdin -Gaston from Beauty and the Beast -Scar from The Lion King -Simba from The Lion King -Mufasa from The Lion King -Woody from Toy Story -Buzz Lightyear from Toy Story -Mr. Potato Head from Toy Story -Slinky Dog from Toy Story -Jessie from Toy Story -Rex from Toy Story -Hamm from Toy Story -Lightning McQueen from Cars -Mater from Cars -Doc Hudson from Cars -Mike Wazowski -Sulley -Randall Boggs -Remy from Ratatouille -Linguini from Ratatouille -Joy from Inside Out -Sadness from Inside Out -Anger from Inside Out -Fear from Inside Out -Disgust from Inside Out -WALL-E from WALL-E -EVE from WALL-E -Syndrome from The Incredibles -Edna Mode from The Incredibles -Violet from The Incredibles -Dash from The Incredibles -Frozone from The Incredibles -Ratigan from The Great Mouse Detective -Basil from The Great Mouse Detective -Baloo from The Jungle Book -Bagheera from The Jungle Book -King Louie from The Jungle Book -Mowgli from The Jungle Book -Luke Skywalker -Princess Leia Organa -Han Solo -Darth Vader -Chewbacca -R2-D2 -C-3PO -Yoda -Boba Fett -Obi-Wan Kenobi -Captain Kirk -Mr. Spock -Dr. McCoy -Scotty -Uhura -Hikaru Sulu -Chekov -Data -Jean-Luc Picard -William Riker -Deanna Troi -Worf -Geordi La Forge -Wesley Crusher -Seven of Nine -Kathryn Janeway -Chakotay -Tuvok -B'Elanna Torres -Tom Paris -Harry Kim -The Doctor -Anakin Skywalker -Darth Vader -Padmé Amidala -Han Solo -Princess Leia Organa -Chewbacca -Lando Calrissian -Qui-Gon Jinn -Mace Windu -Emperor Palpatine -Count Dooku -General Grievous -Rey -Finn -Poe Dameron -Kylo Ren -BB-8 -R2-D2 -C-3PO -The Mandolorian -Neo -Trinity -Morpheus -Agent Smith -The Architect -John Connor -Sarah Connor -The Terminator -Kyle Reese -T-1000 -Ellen Ripley -Lt. Ellen Ripley -The Alien Queen -The Predators -The Xenomorphs -The Colonial Marines -The Engineers -David 8 -HAL 9000 -Dave Bowman -Frank Poole -Dr. Heywood Floyd -Roy Batty -Rick Deckard -Rachael -Gaff -Dr. Eldon Tyrell -Captain Dallas -Lieutenant Kane -Ash -Jonesy -Captain Nemo -Professor Aronnax -Conseil -Ned Land -The Nautilus -The Time Traveler -The Eloi -The Morlocks -Dr. John Watson -Sherlock Holmes -Professor James Moriarty -Irene Adler -Mycroft Holmes -Dr. Jekyll/Mr. Hyde -Mr. Edward Hyde -Dr. Victor Frankenstein -Frankenstein's Monster -Dracula -Count Dracula -Gandalf -Bilbo Baggins -Aragorn -Legolas -Gimli -Frodo Baggins -Samwise Gamgee -Galadriel -Elrond -Gollum -Sauron -Saruman -Thorin Oakenshield -Bard the Bowman -Beorn -Tom Bombadil -Eowyn -Eomer -Faramir -Treebeard -Pippin -Merry -Boromir -Celeborn -Haldir -Radagast -Kili -Tauriel -Thranduil -Arwen -Glorfindel -Harry Potter -Hermione Granger -Ron Weasley -Albus Dumbledore -Severus Snape -Sirius Black -Remus Lupin -Ginny Weasley -Neville Longbottom -Luna Lovegood -Fred Weasley -George Weasley -Draco Malfoy -Voldemort -Hagrid -Minerva McGonagall -Dobby -Bellatrix Lestrange -Lucius Malfoy -Zeus -Thor -Apollo -Odin -Hades -Anubis -Poseidon -Shiva -Vishnu -Brahma -Kali -Athena -Hera -Demeter -Persephone -Dionysus -Artemis -Hecate -Freyja -Frigg -Loki -Horus -Osiris -Ra -Anansi -Tiamat -Marduk -Enki -Inanna -Ereshkigal -Ishtar -Baal -Moloch -Astarte -Dagon -El -Yahweh -Jesus -Buddha -Ganesh -Kwan Yin -Amaterasu -Susanoo -Izanami -Kami -Quetzalcoatl -Tezcatlipoca -Tlaloc -Coatlicue -Inti -Pachamama -Viracocha -Mithras -Apollo Belenus -Cernunnos -Morrigan -Brigid -Lugh -The Dagda -The Horned God -Diana -Janus -Vesta -Saturn -Mars -Venus -Mercury -Neptune -Ceres -Bacchus -Cupid -Vulcan -Fortuna -Pluto -Juno -Apollo Musagetes -Eros -HymenTriton -Amphitrite -Proteus -Thetis -Oceanus -Helios -Selene -Atlas -Prometheus -Epimetheus -Hyperion -Rhea -Mario -Luigi -Bowser -Bowsette -Donkey Kong -Link -Princess Zelda -Princess Peach -Samus Aran -Kirby -Sonic the Hedgehog -Tails -Knuckles -Crash Bandicoot -Spyro the Dragon -Lara Croft -Nathan Drake -Master Chief -Cortana -Kratos -Cloud Strife -Tifa Lockhart -Leon S. Kennedy -Jill Valentine -Chris Redfield -Dante -Nero -Ryu -Ken Masters -Chun-Li -Sub-Zero -Scorpion from Mortal Kombat -Solid Snake -Big Boss -Ezio Auditore -Altair Ibn-La'Ahad -Aloy -Geralt of Rivia -Trevor Philips -Michael De Santa -Franklin Clinton -Niko Bellic -Tommy Vercetti -Marcus Fenix -Dom Santiago -Arthur Morgan -John Marston -Red Dead Redemption -Arthur Curry -Cole MacGrath -SpongeBob SquarePants -Homer Simpson -Betty Boop -Bart Simpson -Fred Flintstone -Shrek -Pink Panther -Popeye -Charlie Brown -Tweety Bird -Jerry Mouse -Wile E. Coyote -Sylvester -Road Runner -Yosemite Sam -Speedy Gonzales -Tasmanian Devil -Mighty Mouse -Inspector Gadget -Alvin -The Brain -Stimpy -Ren -Daria -Eric Cartman -Butters Stotch -Kenny McCormick -Stan Marsh -Kyle Broflovski -Peter Griffin -Brian Griffin -Stewie Griffin -Bender from Futurama -Fry from Futurama -Leela from Futurama -Roger from American Dad -Steve Smith -Walter White -Tony Soprano -Don Draper -Ross Geller -Jerry Seinfeld -Michael Scott -Carrie Bradshaw -Buffy Summers -Tyrion Lannister -Olivia Pope -Dexter Morgan -Meredith Grey -Rachel Green -Sheldon Cooper -Lorelai Gilmore -Cookie Lyon -Barney Stinson -Daenerys Targaryen -Sherlock Holmes -Leslie Knope -Alicia Florrick -Eleven from Stranger Things -Carrie Mathison -Mindy Lahiri -Agent Dale Cooper from Twin Peaks -Eric Cartman -Will Byers -Dr. House -Claire Underwood -Rick Grimes -Carrie Brownstein -Abed Nadir -Agent Mulder -Carmela Soprano -Leslie Poole -Jesse Pinkman -Lorelei Lee -Tracy Jordan -Omar Little -Dwight Schrute -Tyrone Biggums -Omarosa Manigault Newman -Issa Dee -David Brent -Betty Draper -Kenny Powers -Selina Meyer -Peggy Olson -Ash Ketchum -Misty from pokemon -Brock from pokemon -Gary Oak -Professor Oak -Nurse Joy -Officer Jenny -Jessie from pokemon -James from pokemon -Team rocket -John Wick -Captain -material-beard --animal-man -Poison Ivy from Batman -Ryu from Street fighter -Ken from Street fighter -Chun-Li from Street fighter -Guile from Street fighter -Blanka from Street fighter -Dhalsim from Street fighter -Zangief from Street fighter -B2 from Nier -A2 from Nier -S9 from Nier -Kainé from Nier -Emil from Nier -Anthropomorphic -animal- -Barbie -Barbarella -Goku -Vegeta -Naruto Uzumaki -Sailor Moon -Monkey D. Luffy -Light Yagami -Edward Elric -Spike Spiegel -Levi Ackerman -Saitama -Jotaro Kujo -Guts -Alucard --animal- like human -Kermit the frog -Miss piggy -Santa -Storm trooper \ No newline at end of file +character;gender +Harry Potter;male +Frodo Baggins;male +Luke Skywalker;male +Katniss Everdeen;female +Sherlock Holmes;male +James Bond;male +Wonder Woman;female +Batman;male +Spider-Man;male +Superman;male +Captain America;male +Iron Man;male +The Hulk;male +Thor;male +Black Widow;female +Elsa from Frozen;female +Mickey Mouse;male +Bugs Bunny;male +Pikachu;genderless +Sonic the Hedgehog;male +Lara Croft;female +Gandalf;male +Aladdin;male +Cinderella;female +Ariel from The Little Mermaid;female +Belle from Beauty and the Beast;female +Jasmine from Aladdin;female +Mulan;female +Tinker Bell;female +Peter Pan;male +Captain Hook;male +Winnie the Pooh;male +Donkey from Shrek;male +Fiona from Shrek;female +Pinocchio;male +The Grinch;male +Scrooge from A Christmas Carol;male +The Cat in the Hat;male +The Lorax;genderless +The Big Bad Wolf;male +Little Red Riding Hood;female +Puss in Boots;male +Rapunzel;female +Sleeping Beauty;female +Snow White;female +Maleficent;female +Ursula from The Little Mermaid;female +Jafar from Aladdin;male +Gaston from Beauty and the Beast;male +Scar from The Lion King;male +Simba from The Lion King;male +Mufasa from The Lion King;male +Woody from Toy Story;male +Buzz Lightyear from Toy Story;male +Mr. Potato Head from Toy Story;male +Slinky Dog from Toy Story;male +Jessie from Toy Story;female +Rex from Toy Story;male +Hamm from Toy Story;male +Lightning McQueen from Cars;male +Mater from Cars;male +Doc Hudson from Cars;male +Mike Wazowski;male +Sulley;male +Randall Boggs;male +Remy from Ratatouille;male +Linguini from Ratatouille;male +Joy from Inside Out;female +Sadness from Inside Out;female +Anger from Inside Out;male +Fear from Inside Out;male +Disgust from Inside Out;female +WALL-E from WALL-E;male +EVE from WALL-E;female +Syndrome from The Incredibles;male +Edna Mode from The Incredibles;female +Violet from The Incredibles;female +Dash from The Incredibles;male +Frozone from The Incredibles;male +Ratigan from The Great Mouse Detective;male +Basil from The Great Mouse Detective;male +Baloo from The Jungle Book;male +Bagheera from The Jungle Book;male +King Louie from The Jungle Book;male +Mowgli from The Jungle Book;male +Luke Skywalker;male +Princess Leia Organa;female +Han Solo;male +Darth Vader;male +Chewbacca;male +R2-D2;genderless +C-3PO;genderless +Yoda;male +Boba Fett;male +Obi-Wan Kenobi;male +Captain Kirk;male +Mr. Spock;male +Dr. McCoy;male +Scotty;male +Uhura;female +Hikaru Sulu;male +Chekov;male +Data;male +Jean-Luc Picard;male +William Riker;male +Deanna Troi;female +Worf;male +Geordi La Forge;male +Wesley Crusher;male +Seven of Nine;female +Kathryn Janeway;female +Chakotay;male +Tuvok;male +B'Elanna Torres;female +Tom Paris;male +Harry Kim;male +The Doctor;genderless +Anakin Skywalker;male +Darth Vader;male +Padmé Amidala;female +Han Solo;male +Princess Leia Organa;female +Chewbacca;male +Lando Calrissian;male +Qui-Gon Jinn;male +Mace Windu;male +Emperor Palpatine;male +Count Dooku;male +General Grievous;male +Rey;female +Finn;male +Poe Dameron;male +Kylo Ren;male +BB-8;genderless +R2-D2;genderless +C-3PO;genderless +The Mandalorian;male +Neo;male +Trinity;female +Morpheus;male +Agent Smith;male +The Architect;genderless +John Connor;male +Sarah Connor;female +The Terminator;genderless +Kyle Reese;male +T-1000;genderless +Ellen Ripley;female +Lt. Ellen Ripley;female +The Alien Queen;female +The Predators;genderless +The Xenomorphs;genderless +The Colonial Marines;genderless +The Engineers;genderless +David 8;genderless +HAL 9000;genderless +Dave Bowman;male +Frank Poole;male +Dr. Heywood Floyd;male +Roy Batty;male +Rick Deckard;male +Rachael;female +Gaff;male +Dr. Eldon Tyrell;male +Captain Dallas;male +Lieutenant Kane;male +Ash;genderless +Jonesy;genderless +Captain Nemo;male +Professor Aronnax;male +Conseil;male +Ned Land;male +The Nautilus;genderless +The Time Traveler;male +The Eloi;genderless +The Morlocks;genderless +Dr. John Watson;male +Sherlock Holmes;male +Professor James Moriarty;male +Irene Adler;female +Mycroft Holmes;male +Dr. Jekyll/Mr. Hyde;male +Mr. Edward Hyde;male +Dr. Victor Frankenstein;male +Frankenstein's Monster;genderless +Dracula;male +Count Dracula;male +Gandalf;male +Bilbo Baggins;male +Aragorn;male +Legolas;male +Gimli;male +Frodo Baggins;male +Samwise Gamgee;male +Galadriel;female +Elrond;male +Gollum;male +Sauron;male +Saruman;male +Thorin Oakenshield;male +Bard the Bowman;male +Beorn;male +Tom Bombadil;male +Eowyn;female +Eomer;male +Faramir;male +Treebeard;genderless +Pippin;male +Merry;male +Boromir;male +Celeborn;male +Haldir;male +Radagast;male +Kili;male +Tauriel;female +Thranduil;male +Arwen;female +Glorfindel;male +Harry Potter;male +Hermione Granger;female +Ron Weasley;male +Albus Dumbledore;male +Severus Snape;male +Sirius Black;male +Remus Lupin;male +Ginny Weasley;female +Neville Longbottom;male +Luna Lovegood;female +Fred Weasley;male +George Weasley;male +Draco Malfoy;male +Voldemort;male +Hagrid;male +Minerva McGonagall;female +Dobby;genderless +Bellatrix Lestrange;female +Lucius Malfoy;male +Zeus;male +Thor;male +Apollo;male +Odin;male +Hades;male +Anubis;male +Poseidon;male +Shiva;male +Vishnu;male +Brahma;male +Kali;female +Athena;female +Hera;female +Demeter;female +Persephone;female +Dionysus;male +Artemis;female +Hecate;female +Freyja;female +Frigg;female +Loki;male +Horus;male +Osiris;male +Ra;male +Anansi;male +Tiamat;female +Marduk;male +Enki;male +Inanna;female +Ereshkigal;female +Ishtar;female +Baal;male +Moloch;male +Astarte;female +Dagon;male +El;male +Yahweh;male +Jesus;male +Buddha;male +Ganesh;male +Kwan Yin;female +Amaterasu;female +Susanoo;male +Izanami;female +Kami;genderless +Quetzalcoatl;genderless +Tezcatlipoca;male +Tlaloc;male +Coatlicue;female +Inti;male +Pachamama;female +Viracocha;male +Mithras;male +Apollo Belenus;male +Cernunnos;male +Morrigan;female +Brigid;female +Lugh;male +The Dagda;male +The Horned God;male +Diana;female +Janus;male +Vesta;female +Saturn;genderless +Mars;genderless +Venus;female +Mercury;genderless +Neptune;genderless +Ceres;genderless +Bacchus;male +Cupid;male +Vulcan;male +Fortuna;female +Pluto;genderless +Juno;female +Apollo Musagetes;male +Eros;male +HymenTriton;genderless +Amphitrite;female +Proteus;male +Thetis;female +Oceanus;male +Helios;male +Selene;female +Atlas;male +Prometheus;male +Epimetheus;male +Hyperion;male +Rhea;female +Mario;male +Luigi;male +Bowser;male +Bowsette;female +Donkey Kong;male +Link;male +Princess Zelda;female +Princess Peach;female +Samus Aran;female +Kirby;genderless +Sonic the Hedgehog;genderless +Tails;genderless +Knuckles;genderless +Crash Bandicoot;genderless +Spyro the Dragon;genderless +Lara Croft;female +Nathan Drake;male +Master Chief;male +Cortana;female +Kratos;male +Cloud Strife;male +Tifa Lockhart;female +Leon S. Kennedy;male +Jill Valentine;female +Chris Redfield;male +Dante;male +Nero;male +Ryu;male +Ken Masters;male +Chun-Li;female +Sub-Zero;male +Scorpion from Mortal Kombat;male +Solid Snake;male +Big Boss;male +Ezio Auditore;male +Altair Ibn-La'Ahad;male +Aloy;female +Geralt of Rivia;male +Trevor Philips;male +Michael De Santa;male +Franklin Clinton;male +Niko Bellic;male +Tommy Vercetti;male +Marcus Fenix;male +Dom Santiago;male +Arthur Morgan;male +John Marston;male +Red Dead Redemption;genderless +Arthur Curry;male +Cole MacGrath;male +SpongeBob SquarePants;genderless +Homer Simpson;male +Betty Boop;female +Bart Simpson;male +Fred Flintstone;male +Shrek;male +Pink Panther;genderless +Popeye;male +Charlie Brown;male +Tweety Bird;genderless +Jerry Mouse;genderless +Wile E. Coyote;genderless +Sylvester;genderless +Road Runner;genderless +Yosemite Sam;male +Speedy Gonzales;male +Tasmanian Devil;genderless +Mighty Mouse;genderless +Inspector Gadget;male +Alvin;male +The Brain;genderless +Stimpy;genderless +Ren;genderless +Daria;female +Eric Cartman;male +Butters Stotch;male +Kenny McCormick;male +Stan Marsh;male +Kyle Broflovski;male +Peter Griffin;male +Brian Griffin;male +Stewie Griffin;male +Bender from Futurama;genderless +Fry from Futurama;male +Leela from Futurama;female +Roger from American Dad;genderless +Steve Smith;male +Walter White;male +Tony Soprano;male +Don Draper;male +Ross Geller;male +Jerry Seinfeld;male +Michael Scott;male +Carrie Bradshaw;female +Buffy Summers;female +Tyrion Lannister;male +Olivia Pope;female +Dexter Morgan;male +Meredith Grey;female +Rachel Green;female +Sheldon Cooper;male +Lorelai Gilmore;female +Cookie Lyon;female +Barney Stinson;male +Daenerys Targaryen;female +Sherlock Holmes;male +Leslie Knope;female +Alicia Florrick;female +Eleven from Stranger Things;female +Carrie Mathison;female +Mindy Lahiri;female +Agent Dale Cooper from Twin Peaks;male +Eric Cartman;male +Will Byers;male +Dr. House;male +Claire Underwood;female +Rick Grimes;male +Carrie Brownstein;female +Abed Nadir;male +Agent Mulder;male +Carmela Soprano;female +Leslie Poole;female +Jesse Pinkman;male +Lorelei Lee;female +Tracy Jordan;male +Omar Little;male +Dwight Schrute;male +Tyrone Biggums;male +Omarosa Manigault Newman;female +Issa Dee;female +David Brent;male +Betty Draper;female +Kenny Powers;male +Selina Meyer;female +Peggy Olson;female +Ash Ketchum;male +Misty from Pokemon;female +Brock from Pokemon;male +Gary Oak;male +Professor Oak;male +Nurse Joy;female +Officer Jenny;female +Jessie from Pokemon;female +James from Pokemon;male +Team Rocket;genderless +John Wick;male +Captain -material-beard;male +-animal-man;genderless +Poison Ivy from Batman;female +Ryu from Street Fighter;male +Ken from Street Fighter;male +Chun-Li from Street Fighter;female +Guile from Street Fighter;male +Blanka from Street Fighter;male +Dhalsim from Street Fighter;male +Zangief from Street Fighter;male +B2 from Nier;genderless +A2 from Nier;female +S9 from Nier;female +Kainé from Nier;female +Emil from Nier;male +Anthropomorphic -animal-;genderless +Barbie;female +Barbarella;female +Goku;male +Vegeta;male +Naruto Uzumaki;male +Sailor Moon;female +Monkey D. Luffy;male +Light Yagami;male +Edward Elric;male +Spike Spiegel;male +Levi Ackerman;male +Saitama;male +Jotaro Kujo;male +Guts;male +Alucard;male +-animal- like human;genderless +Kermit the Frog;male +Miss Piggy;female +Santa;male +Stormtrooper;genderless \ No newline at end of file diff --git a/csvfiles/genderdescription.csv b/csvfiles/genderdescription.csv index f17c3d2..7fdaa9d 100644 --- a/csvfiles/genderdescription.csv +++ b/csvfiles/genderdescription.csv @@ -1,3 +1,4 @@ -feminine -masculine -androgynous \ No newline at end of file +description;gender +feminine;female +masculine;male +androgynous;undetermined \ No newline at end of file diff --git a/csvfiles/malefemale.csv b/csvfiles/malefemale.csv index 34fd740..d6a77b6 100644 --- a/csvfiles/malefemale.csv +++ b/csvfiles/malefemale.csv @@ -1,2 +1,3 @@ -Male -Female \ No newline at end of file +malefemale;gender +Male;male +Female;female \ No newline at end of file diff --git a/csvfiles/manwoman.csv b/csvfiles/manwoman.csv index 4bf9f4a..d3b3db5 100644 --- a/csvfiles/manwoman.csv +++ b/csvfiles/manwoman.csv @@ -1,2 +1,3 @@ -Man -Woman \ No newline at end of file +manwoman;gender +Man;male +Woman;female \ No newline at end of file diff --git a/csvfiles/manwomanrelations.csv b/csvfiles/manwomanrelations.csv index 168b78b..f90b27a 100644 --- a/csvfiles/manwomanrelations.csv +++ b/csvfiles/manwomanrelations.csv @@ -1,16 +1,17 @@ -Boy -Girl -Mother -Father -Grandma -Grandpa -Aunt -Uncle -Sister -Brother -Sibling -Parent -Wife -Husband -Girlfriend -Boyfriend \ No newline at end of file +manwomanrelation;gender +Boy;male +Girl;female +Mother;female +Father;male +Grandma;female +Grandpa;male +Aunt;female +Uncle;male +Sister;female +Brother;male +Sibling;undetermined +Parent;undetermined +Wife;female +Husband;male +Girlfriend;female +Boyfriend;male \ No newline at end of file From edebb8a824376604ca53482c9ef43f8bab73f6d1 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Fri, 7 Jul 2023 14:15:54 +0200 Subject: [PATCH 09/18] busy with gender --- build_dynamic_prompt.py | 4 +- csvfiles/nonfictional characters.csv | 2325 +++++++++++++------------- prompttester.py | 6 +- scripts/onebuttonprompt.py | 17 +- 4 files changed, 1185 insertions(+), 1167 deletions(-) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index fa19d69..b844fb3 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -33,7 +33,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all materiallist = csv_to_list("materials",antilist) objectlist = csv_to_list("objects",antilist) fictionallist = csv_to_list(csvfilename="fictional characters",antilist=antilist,skipheader=True,gender=gender) - nonfictionallist = csv_to_list("nonfictional characters",antilist) + nonfictionallist = csv_to_list(csvfilename="nonfictional characters",antilist=antilist,skipheader=True,gender=gender) conceptsuffixlist = csv_to_list("concept_suffix",antilist) buildinglist = csv_to_list("buildings",antilist) vehiclelist = csv_to_list("vehicles",antilist) @@ -1296,6 +1296,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all hybridorswap = "" if(subjectchooser == "humanoid"): + if(gender != "all"): + completeprompt += "-malefemale- " if rare_dist(insanitylevel): hybridorswaplist = ["hybrid", "swap"] hybridorswap = random.choice(hybridorswaplist) diff --git a/csvfiles/nonfictional characters.csv b/csvfiles/nonfictional characters.csv index 9e9090f..e6e65b1 100644 --- a/csvfiles/nonfictional characters.csv +++ b/csvfiles/nonfictional characters.csv @@ -1,1162 +1,1163 @@ -Tom Hanks -Leonardo DiCaprio -Robert De Niro -Al Pacino -Marlon Brando -Morgan Freeman -Denzel Washington -Samuel L. Jackson -Anthony Hopkins -Sean Connery -Clint Eastwood -Harrison Ford -Johnny Depp -Brad Pitt -George Clooney -Matt Damon -Will Smith -Mark Wahlberg -Christian Bale -Tom Cruise -Daniel Day-Lewis -Robin Williams -Jim Carrey -Eddie Murphy -Bill Murray -Michael Keaton -Steve Martin -John Travolta -Kevin Costner -Mel Gibson -Ben Affleck -Hugh Jackman -Chris Hemsworth -Ryan Reynolds -Chris Evans -Robert Downey Jr. -Nicolas Cage -Keanu Reeves -Pierce Brosnan -Colin Firth -Sean Bean -Tim Robbins -Gary Oldman -Sean Penn -Laurence Fishburne -Jamie Foxx -Hugh Grant -Jude Law -Matthew McConaughey -Liam Neeson -Joaquin Phoenix -Eddie Redmayne -Adam Sandler -Will Ferrell -Ben Stiller -Owen Wilson -Jason Bateman -Seth Rogen -Zac Efron -John Goodman -Jeff Goldblum -Robin Wright -Mark Ruffalo -Tom Hardy -Jake Gyllenhaal -Joseph Gordon-Levitt -Ryan Gosling -Robert Pattinson -Orlando Bloom -Channing Tatum -Shia LaBeouf -Michael Fassbender -Jeremy Renner -Chris Pine -Armie Hammer -Ashton Kutcher -Timothy Olyphant -Terrence Howard -Michael B. Jordan -Rami Malek -Henry Cavill -Idris Elba -Tom Holland -Taron Egerton -Richard Gere -Hugh Laurie -Benedict Cumberbatch -David Tennant -Matt Smith -Peter Capaldi -Christopher Eccleston -Jon Hamm -Bryan Cranston -Aaron Paul -Paul Rudd -Adam Driver -Daniel Radcliffe -Meryl Streep -Julia Roberts -Angelina Jolie -Cate Blanchett -Nicole Kidman -Emma Watson -Scarlett Johansson -Charlize Theron -Sandra Bullock -Jennifer Aniston -Jennifer Lawrence -Reese Witherspoon -Kate Winslet -Anne Hathaway -Natalie Portman -Mila Kunis -Emma Stone -Anya Taylor-Joy -Keira Knightley -Julianne Moore -Viola Davis -Brie Larson -Helen Mirren -Amy Adams -Michelle Pfeiffer -Sigourney Weaver -Rachel McAdams -Tilda Swinton -Zoe Saldana -Octavia Spencer -Salma Hayek -Lupita Nyong'o -Uma Thurman -Halle Berry -Catherine Zeta-Jones -Diane Keaton -Shirley MacLaine -Judi Dench -Maggie Smith -Maggie Gyllenhaal -Rachel Weisz -Naomi Watts -Liv Tyler -Michelle Rodriguez -Emma Thompson -Kirsten Dunst -Thandie Newton -Mira Sorvino -Jessica Chastain -Bette Davis -Joan Crawford -Grace Kelly -Audrey Hepburn -Elizabeth Taylor -Marilyn Monroe -Marlene Dietrich -Greta Garbo -Judy Garland -Ginger Rogers -Emilia Clarke -Bryce Dallas Howard -Mae West -Katharine Hepburn -Vivien Leigh -Ingrid Bergman -Jane Fonda -Faye Dunaway -Diana Ross -Liza Minnelli -Glenn Close -Annette Bening -Laura Linney -Frances McDormand -Toni Collette -Sandra Oh -Gong Li -Michelle Yeoh -Fan Bingbing -Zhang Ziyi -Zhao Wei -Brigitte Lin -Isabelle Huppert -Juliette Binoche -Catherine Deneuve -Isabelle Adjani -Emmanuelle Béart -Monica Bellucci -Marion Cotillard -Audrey Tautou -Bérénice Bejo -Ludivine Sagnier -Mélanie Laurent -Carole Bouquet -Sophie Marceau -Eva Green -Charlotte Gainsbourg -Léa Seydoux -Isabelle Fuhrman -Tilda Cobham-Hervey -Elle Fanning -Margot Robbie -Saoirse Ronan -Gisele Bündchen -Kate Moss -Naomi Campbell -Cindy Crawford -Heidi Klum -Tyra Banks -Christy Turlington -Adriana Lima -Claudia Schiffer -Karlie Kloss -Bella Hadid -Gigi Hadid -Kendall Jenner -Iman -Joan Smalls -Linda Evangelista -Natalia Vodianova -Doutzen Kroes -Cara Delevingne -Jourdan Dunn -Chanel Iman -Alessandra Ambrosio -Karolina Kurkova -Amber Valletta -Irina Shayk -Elvis Presley -Michael Jackson -Frank Sinatra -Freddie Mercury -Stevie Wonder -Paul McCartney -John Lennon -David Bowie -Prince -Bob Dylan -Marvin Gaye -Bruce Springsteen -Elton John -Mick Jagger -Ray Charles -James Brown -Bono -Phil Collins -Eric Clapton -Johnny Cash -George Michael -Justin Timberlake -Bruno Mars -Chris Martin -Ed Sheeran -Harry Styles -Shawn Mendes -Adam Levine -Robbie Williams -Enrique Iglesias -Usher -Justin Bieber -Drake -The Weeknd -Lionel Richie -Rod Stewart -Billy Joel -Jon Bon Jovi -Steven Tyler -Ozzy Osbourne -Jim Morrison -Mick Hucknall -Tom Jones -Morrissey -Kurt Cobain -John Mayer -Sting -Tom Petty -Chris Cornell -Axl Rose -Beyoncé -Adele -Taylor Swift -Rihanna -Whitney Houston -Mariah Carey -Ariana Grande -Lady Gaga -Madonna -Katy Perry -Jennifer Lopez -Pink -Shakira -Celine Dion -Christina Aguilera -Dua Lipa -Selena Gomez -Billie Eilish -Janet Jackson -Demi Lovato -Sia -Kelly Clarkson -Amy Winehouse -Alicia Keys -Barbra Streisand -Gwen Stefani -Britney Spears -Mary J. Blige -Carrie Underwood -Miley Cyrus -Ari Lennox -Lizzo -Florence Welch -H.E.R. -Janelle Monae -Kacey Musgraves -Lorde -Sade -Stevie Nicks -Tinashe -Tori Kelly -Vanessa Carlton -Zara Larsson -Jessie J -Duffy -Norah Jones -Kehlani -Jorja Smith -Ella Mai -oe Biden -Vladimir Putin -Xi Jinping -Angela Merkel -Emmanuel Macron -Justin Trudeau -Boris Johnson -Narendra Modi -Hassan Rouhani -Benjamin Netanyahu -Recep Tayyip Erdogan -Moon Jae-in -Jair Bolsonaro -Alberto Fernández -Andrés Manuel López Obrador -Scott Morrison -Jacinda Ardern -Tsai Ing-wen -Aung San Suu Kyi -Kim Jong-un -King Salman bin Abdulaziz Al Saud -Sheikh Hasina -Abdel Fattah el-Sisi -Bashar al-Assad -Hassan Diab -Pope Francis -Pope John Paul II -Pope Benedict XVI -Pope John XXIII -Pope Pius XII -Julius Caesar -Alexander the Great -Cleopatra -Joan of Arc -Leonardo da Vinci -Michelangelo -Galileo Galilei -William Shakespeare -Isaac Newton -George Washington -Napoleon Bonaparte -Abraham Lincoln -Charles Darwin -Queen Victoria -Mahatma Gandhi -Albert Einstein -Franklin D. Roosevelt -Winston Churchill -Joseph Stalin -Adolf Hitler -Martin Luther King Jr. -John F. Kennedy -Neil Armstrong -Mao Zedong -Che Guevara -Pablo Picasso -Ronald Reagan -Margaret Thatcher -Nelson Mandela -Mother Teresa -Princess Diana -Saddam Hussein -Osama bin Laden -Steve Jobs -Bill Gates -Barack Obama -Queen Elizabeth II -Elon Musk -Jeff Bezos -Mark Zuckerberg -Oprah Winfrey -Serena Williams -Usain Bolt -Michael Jordan -a.j. cook -abbie cornish -adrianne palicki -agam darshi -aimee garcia -aishwariya rai -alanna ubach -alexa penavega -alexandra daddario -alexis bledel -ali cobrin -ali larter -alice braga -alice eve -alice greczyn -alicia silverstone -alicia vikander -alicia witt -alison lohman -alison pill -aly michalka -alyson hannigan -alyssa milano -amanda bynes -amanda peet -amanda seyfried -amber heard -amrita acharia -amy smart -ana de la reguera -andie macdowell -andrea navedo -andrea savage -angela trimbur -anita ekberg -ann-margret -anna chlumsky -anna faris -anna kendrick -antoinette kalaj -april bowlby -april hernandez castillo -ashley greene -ashley judd -ashley olsen -ashley scott -astrid bergès-frisbey -aubrey plaza -ava gardner -berenice marlohe -beverly d'angelo -bianca kajlich -blake lively -bo derek -bree turner -briana evigan -bridget fonda -bridgette wilson-sampras -brigitte bardot -brittany daniel -brittany murphy -brittany snow -brooke burns -brooke d'orsay -brooke shields -brooklyn decker -cameron diaz -cameron richardson -camilla belle -candace cameron bure -carey mulligan -carla gallo -carla gugino -carly craig -carmen electra -casey wilson -chandra west -chloë grace moretz -chloë sevigny -christian serratos -christina applegate -christina ricci -christine lakin -christine taylor -chyler leigh -claire danes -claire forlani -cobie smulders -cody horn -connie nielsen -courteney cox -courtney thorne-smith -dakota fanning -dana davis -dania ramirez -danica mckellar -daniela bobadilla -danielle fishel -danielle harris -danneel ackles -daryl hannah -deborah ann woll -debra messing -demi moore -denise richards -diane kruger -diane lane -dianna agron -drea de matteo -drew barrymore -elena anaya -elisha cuthbert -eliza coupe -eliza dushku -elizabeth banks -elizabeth berkley -elizabeth hurley -elizabeth olsen -ellen wong -ellie kemper -elliot page -emily blunt -emily browning -emily deschanel -emma greenwell -emma roberts -emmanuelle chriqui -emmanuelle vaugier -emmy rossum -esmé bianco -estella warren -eva longoria -eva mendes -evan rachel wood -frankie shaw -freida pinto -gabrielle anwar -gabrielle union -gal gadot -garcelle beauvais -gemma arterton -gemma ward -gene tierney -genesis rodriguez -genevieve padalecki -gina gershon -ginnifer goodwin -goldie hawn -gugu mbatha-raw -gwyneth paltrow -hayden panettiere -heather graham -heather locklear -helena boham carter -helena christensen -helena mattsson -hilary duff -isla fisher -izabella miko -izabella scorupco -jada pinkett smith -jaime king -jaime murray -jaime pressly -jamie chung -jamie-lynn sigler -janina gavankar -january jones -jayne mansfield -jeanne tripplehorn -jenna coleman -jenna elfman -jenna fischer -jennie garth -jennifer carpenter -jennifer connelly -jennifer esposito -jennifer garner -jennifer hudson -jennifer love hewitt -jennifer morrison -jennifer taylor -jenny mccarthy-wahlberg -jeri ryan -jessica alba -jessica biel -jessica lange -jessica szohr -joanne whalley -jodi lyn o'keefe -jordan ladd -jordana brewster -jud tylor -julianna guill -julie benz -julie bowen -julie christie -juliette lewis -k.d. aubert -kaitlin doubleday -kaley cuoco -kat dennings -kate beckinsale -kate bosworth -kate hudson -kate mara -katherine heigl -katherine lanasa -kathryn hahn -katie cassidy -katie holmes -katrina bowden -katy mixon -kelly carlson -kelly hu -kelly stables -keri russell -kerry washington -kim basinger -krista allen -kristen bell -kristen stewart -kristen wiig -kristin chenoweth -kristin davis -kristin kreuk -kristina klebe -kristy swanson -lacey chabert -lake bell -lalaine -lara flynn boyle -lark voorhies -laura wiggins -lauren ambrose -lauren bacall -lauren holly -lauren london -lea michele -leah remini -leighton meester -lena headey -leslie bibb -leslie mann -li gong -lily collins -linda cardellini -lindsay lohan -lisa bonet -lizzy caplan -lucy lawless -lucy liu -lynda carter -lyndsy fonseca -madeleine stowe -madison riley -mae whitman -maggie q -mahaley patel -majandra delfino -malin akerman -maria bello -maria grazia cucinotta -maria thayer -marin hinkle -marisa coughlan -marisa tomei -marley shelton -marsha thomason -mary elizabeth winstead -mary mccormack -mary-kate olsen -mary-louise parker -meg ryan -megan fox -megyn price -melanie lynskey -melissa george -melissa sagemiller -melora hardin -mena suvari -mia wasikowska -michelle borth -michelle burke -michelle monaghan -michelle trachtenberg -michelle williams -milla jovovich -ming-na wen -mini anden -minka kelly -molly ringwald -molly sims -moon bloodgood -natalia tena -natalie dormer -natasha henstridge -nathalie kelley -neve campbell -nicky whelan -nicole ari parker -nicole eggert -nikki reed -nina dobrev -noureen dewulf -odette annable -olga kurylenko -olivia thirlby -olivia wilde -paget brewster -pamela anderson -parker posey -patricia arquette -paula garcés -paula patton -paz vega -penelope cruz -penélope cruz -phoebe cates -piper perabo -qi shu -rachael leigh cook -rachel bilson -rachel nichols -rachel specter -rachel true -raquel welch -rashida jones -rebecca hall -rebecca romijn -regina hall -renée zellweger -rhona mitra -rita hayworth -robin tunney -rochelle aytes -rooney mara -rosario dawson -rose byrne -rose mcgowan -roselyn sanchez -rumer willis -saffron burrows -samantha mathis -sara paxton -sarah chalke -sarah hyland -sarah lancaster -sarah michelle gellar -sarah roemer -sarah shahi -sarah silverman -sasha alexander -scout taylor-compton -selma blair -seychelle gabriel -shailene woodley -shannon elizabeth -shannyn sossamon -shanola hampton -sharon stone -shawnee smith -sheri moon zombie -shu qi -sienna miller -sofia vergara -sofía vergara -sophia loren -sophie winkleman -stacey dash -stella maeve -stephanie fantauzzi -stephanie szostak -susan ward -sydney tamiia poitier -tara reid -teresa palmer -teri polo -thandiwe newton -thora birch -tia carrere -tiffani thiessen -traci bingham -tracie thoms -ursula andress -vanessa angel -vanessa ferlito -vanessa hudgens -vanessa lengies -vanessa williams -vera farmiga -veronica lake -vinessa shaw -vivica a. fox -winona ryder -yvonne de carlo -yvonne strahovski -ziyi zhang -zooey deschanel -zoë bell -zoë kravitz -zulay henao -arnold schwarzenegger -bruce willis -chris pratt -daniel craig -david duchovny -dustin hoffman -dwayne johnson -emile hirsch -erik per sullivan -gerald butler -grant gustin -ian somerhalder -jack nicholson -jackie chan -jason momoa -jimmy fallon -john boyega -john cusack -johnny deep -josh brolin -kevin hart -kit harington -michael douglas -michael j. fox -michael sheen -michael weatherly -mike myers -nathan fillion -nathan lane -paul walker -ray romano -russel crowe -scott speedman -sebastian stan -shah rukh khan -stephen amell -taylor lautner -timothée chalamet -toby kebbell -tom hiddleston -tommy lee jones -tony goldwyn -tyler hoechlin -vince vaughn -Addison Rae -Adèle Exarchopoulos -Aimee Lou Wood -AJ Lee -Alanna Masterson -Alejandra Guilmant -Alex Morgan -Alexa Bliss -Alexis Ren -Alica Schmidt -Alison Brie -Allison Stokke -Allison Williams -Aly Raisman -Alycia Debnam-Carey -Amanda Cerny -Ana de Armas -Angela Kinsey -Angela Sarafyan -Anitta -Anna Akana -Anna Kournikova -Anna Paquin -AnnaSophia Robb -Anya Chalotra -Ariel Winter -Ashley Benson -Ashley Graham -Ashley Park -Ashley Tisdale -Auli’i Cravalho -Avril Lavigne -Awkwafina -Bailee Madison -Bar Refaeli -Barbara Palvin -Bebe Rexha -Becky G -Becky Lynch -Bella Thorne -Beth Behrs -Betty Gilpin -Bonnie Wright -Brenda Song -Brianna Hildebrand -Brie Bella -Brighton Sharbino -Caity Lotz -Camila Cabello -Camila Mendes -Camilla Luddington -Candice Swanepoel -Cardi B -Carice van Houten -Carly Rae Jepsen -Caroline Vreeland -Caylee Cowan -Charisma Carpenter -Charli D’Amelio -Charli XCX -Charlotte Flair -Charlotte McKinney -Chelsea Handler -Chloe Bennet -Chloe Kim -Chrissy Teigen -Christen Harper -Christina Hendricks -CJ Perry -Cristin Milioti -Daisy Edgar-Jones -Daisy Ridley -Dakota Johnson -Danielle Panabaker -Debby Ryan -Demi Rose -Diana Silvers -Diane Guerrero -Diora Baird -Disha Patani -Dixie D’Amelio -Doja Cat -Dominique McElligott -Dove Cameron -Eiza González -Eleanor Tomlinson -Elisabeth Shue -Elizabeth Debicki -Elizabeth Gillies -Elizabeth Turner -Ellie Goulding -Elsa Hosk -Elsa Pataky -Elsie Hewitt -Emily Bett Rickards -Emily Kinney -Emily Osment -Emily Ratajkowski -Emily VanCamp -Emma Kenney -Emma Mackey -Emma Raducanu -Erin Moriarty -Eugenie Bouchard -Eva Amurri -Evangeline Lilly -Felicity Jones -Florence Pugh -Freya Allan -Giada De Laurentiis -Gillian Anderson -Gillian Jacobs -Gina Carano -Hailee Steinfeld -Hailey Bieber -Halsey -Hannah Simone -Hayley Atwell -Helene Fischer -Holly Willoughby -HoYeon Jung -Hunter King -Hunter Schafer -Iggy Azalea -Ilana Glazer -Iliza Shlesinger -Imogen Poots -Ireland Baldwin -Iris Apatow -Isabela Merced -Isidora Goreshter -Jackie Cruz -Jaimie Alexander -Jamie Lee Curtis -Jane Levy -Jenna Dewan -Jennette McCurdy -Jennifer Holland -Jenny Slate -Jessica Parker Kennedy -Jessica Paré -Jessica Simpson -Jewel Staite -Jodie Comer -Joey King -JoJo -Jordyn Huitema -Jordyn Jones -Josephine Skriver -Judy Greer -Julia Fox -Julia Garner -Julianne Hough -Juno Temple -Jutta Leerdam -Kaia Gerber -Kaitlyn Dever -Karen Fukuhara -Karen Gillan -Kate Upton -Katelyn Nacon -Katelyn Ohashi -Katherine Langford -Katherine McNamara -Katherine Waterston -Katheryn Winnick -Kaya Scodelario -Kelly Brook -Kelly Rohrbach -Kesha -Khloé Kardashian -Kiernan Shipka -Kim Kardashian -Kimberley Garner -Kimiko Glenn -Kira Kosarin -Kourtney Kardashian -Krysten Ritter -Kylie Jenner -Kylie Minogue -Lais Ribeiro -Lana Del Rey -Larsen Thompson -Laura Harrier -Laura Prepon -Lauren Cohan -Lea Seydoux -Leelee Sobieski -Leila Lowfire -Lena Gercke -Lena Meyer-Landrut -Lili Reinhart -Lili Simmons -Lily Chee -Lily James -Lily Sheen -Lily-Rose Depp -Lindsey Pelas -Lindsey Vonn -Lisa Kudrow -Lucy Hale -Lucy Pinder -Lupita Nyong’o -Mackenzie Davis -Mackenzie Foy -Mackenzie Ziegler -Maddie Ziegler -Madelaine Petsch -Madison Beer -Madison Pettis -Madisyn Shipman -Maggie Grace -Maia Mitchell -Maisie Williams -Malin Åkerman -Mandy Moore -Margaret Qualley -Maria Bakalova -Maria Menounos -Maria Sharapova -Maryse -María Pedraza -Maude Apatow -Maya Hawke -McKayla Maroney -Meagan Good -Megan Thee Stallion -Meghan Markle -Melissa Benoist -Melissa Fumero -Melissa Rauch -Michelle Jenneke -Miesha Tate -Milana Vayntrub -Millie Bobby Brown -Miranda Cosgrove -Miranda Kerr -Morena Baccarin -Naomi Scott -Natalia Dyer -Natalie Alyn Lind -Natasha Lyonne -Nathalie Emmanuel -Nicki Minaj -Nicole Scherzinger -Nikki Bella -Nikki Glaser -Nina Agdal -Normani -Olivia Culpo -Olivia Munn -Olivia Rodrigo -Olivia Taylor Dudley -Padma Lakshmi -Paige -Paige Spiranac -Paige VanZant -Palina Rojinski -Paris Hilton -Paulina Gaitán -Peyton List -Phoebe Tonkin -Pokimane -Pom Klementieff -Priyanka Chopra -Rachel Brosnahan -Rachel Cook -Rachel Zegler -Rebecca Black -Rebecca Ferguson -Rhea Seehorn -Rita Ora -Ronda Rousey -Ronja Forcher -Rosamund Pike -Rose Leslie -Rose McIver -Rosie Huntington-Whiteley -Ruby O. Fee -Ruby Rose -Sabrina Carpenter -Sadie Sink -Samara Weaving -Sammi Hanratty -Sara Sampaio -Sara Underwood -Sarah McDaniel -Sarah Paulson -Sasha Banks -Saweetie -Shantel VanSanten -Simone Biles -Sophia Lillis -Sophia Thomalla -Sophie Turner -Stacy Keibler -Stephanie Beatriz -Stephanie McMahon -Susan Sarandon -Sydney Sweeney -Taylor Hill -Taylor Schilling -Tessa Thompson -Thomasin McKenzie -Tina Fey -Torrie Wilson -Tove Lo -Ursula Corberó -Vanessa Kirby -Vica Kerekes -Victoria De Angelis -Victoria Justice -Whitney Cummings -Willa Fitzgerald -Willa Holland -Yanet Garcia -Zazie Beetz -Zendaya -Zoey Deutch \ No newline at end of file +character;gender +Tom Hanks;male +Leonardo DiCaprio;male +Robert De Niro;male +Al Pacino;male +Marlon Brando;male +Morgan Freeman;male +Denzel Washington;male +Samuel L. Jackson;male +Anthony Hopkins;male +Sean Connery;male +Clint Eastwood;male +Harrison Ford;male +Johnny Depp;male +Brad Pitt;male +George Clooney;male +Matt Damon;male +Will Smith;male +Mark Wahlberg;male +Christian Bale;male +Tom Cruise;male +Daniel Day-Lewis;male +Robin Williams;male +Jim Carrey;male +Eddie Murphy;male +Bill Murray;male +Michael Keaton;male +Steve Martin;male +John Travolta;male +Kevin Costner;male +Mel Gibson;male +Ben Affleck;male +Hugh Jackman;male +Chris Hemsworth;male +Ryan Reynolds;male +Chris Evans;male +Robert Downey Jr.;male +Nicolas Cage;male +Keanu Reeves;male +Pierce Brosnan;male +Colin Firth;male +Sean Bean;male +Tim Robbins;male +Gary Oldman;male +Sean Penn;male +Laurence Fishburne;male +Jamie Foxx;male +Hugh Grant;male +Jude Law;male +Matthew McConaughey;male +Liam Neeson;male +Joaquin Phoenix;male +Eddie Redmayne;male +Adam Sandler;male +Will Ferrell;male +Ben Stiller;male +Owen Wilson;male +Jason Bateman;male +Seth Rogen;male +Zac Efron;male +John Goodman;male +Jeff Goldblum;male +Robin Wright;female +Mark Ruffalo;male +Tom Hardy;male +Jake Gyllenhaal;male +Joseph Gordon-Levitt;male +Ryan Gosling;male +Robert Pattinson;male +Orlando Bloom;male +Channing Tatum;male +Shia LaBeouf;male +Michael Fassbender;male +Jeremy Renner;male +Chris Pine;male +Armie Hammer;male +Ashton Kutcher;male +Timothy Olyphant;male +Terrence Howard;male +Michael B. Jordan;male +Rami Malek;male +Henry Cavill;male +Idris Elba;male +Tom Holland;male +Taron Egerton;male +Richard Gere;male +Hugh Laurie;male +Benedict Cumberbatch;male +David Tennant;male +Matt Smith;male +Peter Capaldi;male +Christopher Eccleston;male +Jon Hamm;male +Bryan Cranston;male +Aaron Paul;male +Paul Rudd;male +Adam Driver;male +Daniel Radcliffe;male +Meryl Streep;female +Julia Roberts;female +Angelina Jolie;female +Cate Blanchett;female +Nicole Kidman;female +Emma Watson;female +Scarlett Johansson;female +Charlize Theron;female +Sandra Bullock;female +Jennifer Aniston;female +Jennifer Lawrence;female +Reese Witherspoon;female +Kate Winslet;female +Anne Hathaway;female +Natalie Portman;female +Mila Kunis;female +Emma Stone;female +Anya Taylor-Joy;female +Keira Knightley;female +Julianne Moore;female +Viola Davis;female +Brie Larson;female +Helen Mirren;female +Amy Adams;female +Michelle Pfeiffer;female +Sigourney Weaver;female +Rachel McAdams;female +Tilda Swinton;female +Zoe Saldana;female +Octavia Spencer;female +Salma Hayek;female +Lupita Nyong'o;female +Uma Thurman;female +Halle Berry;female +Catherine Zeta-Jones;female +Diane Keaton;female +Shirley MacLaine;female +Judi Dench;female +Maggie Smith;female +Maggie Gyllenhaal;female +Rachel Weisz;female +Naomi Watts;female +Liv Tyler;female +Michelle Rodriguez;female +Emma Thompson;female +Kirsten Dunst;female +Thandie Newton;female +Mira Sorvino;female +Jessica Chastain;female +Bette Davis;female +Joan Crawford;female +Grace Kelly;female +Audrey Hepburn;female +Elizabeth Taylor;female +Marilyn Monroe;female +Marlene Dietrich;female +Greta Garbo;female +Judy Garland;female +Ginger Rogers;female +Emilia Clarke;female +Bryce Dallas Howard;female +Mae West;female +Katharine Hepburn;female +Vivien Leigh;female +Ingrid Bergman;female +Jane Fonda;female +Faye Dunaway;female +Diana Ross;female +Liza Minnelli;female +Glenn Close;female +Annette Bening;female +Laura Linney;female +Frances McDormand;female +Toni Collette;female +Sandra Oh;female +Gong Li;female +Michelle Yeoh;female +Fan Bingbing;female +Zhang Ziyi;female +Zhao Wei;female +Brigitte Lin;female +Isabelle Huppert;female +Juliette Binoche;female +Catherine Deneuve;female +Isabelle Adjani;female +Emmanuelle Béart;female +Monica Bellucci;female +Marion Cotillard;female +Audrey Tautou;female +Bérénice Bejo;female +Ludivine Sagnier;female +Mélanie Laurent;female +Carole Bouquet;female +Sophie Marceau;female +Eva Green;female +Charlotte Gainsbourg;female +Léa Seydoux;female +Isabelle Fuhrman;female +Tilda Cobham-Hervey;female +Elle Fanning;female +Margot Robbie;female +Saoirse Ronan;female +Gisele Bündchen;female +Kate Moss;female +Naomi Campbell;female +Cindy Crawford;female +Heidi Klum;female +Tyra Banks;female +Christy Turlington;female +Adriana Lima;female +Claudia Schiffer;female +Karlie Kloss;female +Bella Hadid;female +Gigi Hadid;female +Kendall Jenner;female +Iman;female +Joan Smalls;female +Linda Evangelista;female +Natalia Vodianova;female +Doutzen Kroes;female +Cara Delevingne;female +Jourdan Dunn;female +Chanel Iman;female +Alessandra Ambrosio;female +Karolina Kurkova;female +Amber Valletta;female +Irina Shayk;female +Elvis Presley;male +Michael Jackson;male +Frank Sinatra;male +Freddie Mercury;male +Stevie Wonder;male +Paul McCartney;male +John Lennon;male +David Bowie;male +Prince;male +Bob Dylan;male +Marvin Gaye;male +Bruce Springsteen;male +Elton John;male +Mick Jagger;male +Ray Charles;male +James Brown;male +Bono;male +Phil Collins;male +Eric Clapton;male +Johnny Cash;male +George Michael;male +Justin Timberlake;male +Bruno Mars;male +Chris Martin;male +Ed Sheeran;male +Harry Styles;male +Shawn Mendes;male +Adam Levine;male +Robbie Williams;male +Enrique Iglesias;male +Usher;male +Justin Bieber;male +Drake;male +The Weeknd;male +Lionel Richie;male +Rod Stewart;male +Billy Joel;male +Jon Bon Jovi;male +Steven Tyler;male +Ozzy Osbourne;male +Jim Morrison;male +Mick Hucknall;male +Tom Jones;male +Morrissey;male +Kurt Cobain;male +John Mayer;male +Sting;male +Tom Petty;male +Chris Cornell;male +Axl Rose;male +Beyoncé;female +Adele;female +Taylor Swift;female +Rihanna;female +Whitney Houston;female +Mariah Carey;female +Ariana Grande;female +Lady Gaga;female +Madonna;female +Katy Perry;female +Jennifer Lopez;female +Pink;female +Shakira;female +Celine Dion;female +Christina Aguilera;female +Dua Lipa;female +Selena Gomez;female +Billie Eilish;female +Janet Jackson;female +Demi Lovato;female +Sia;female +Kelly Clarkson;female +Amy Winehouse;female +Alicia Keys;female +Barbra Streisand;female +Gwen Stefani;female +Britney Spears;female +Mary J. Blige;female +Carrie Underwood;female +Miley Cyrus;female +Ari Lennox;female +Lizzo;female +Florence Welch;female +H.E.R.;female +Janelle Monae;female +Kacey Musgraves;female +Lorde;female +Sade;female +Stevie Nicks;female +Tinashe;female +Tori Kelly;female +Vanessa Carlton;female +Zara Larsson;female +Jessie J;female +Duffy;female +Norah Jones;female +Kehlani;female +Jorja Smith;female +Ella Mai;female +Joe Biden;male +Vladimir Putin;male +Xi Jinping;male +Angela Merkel;female +Emmanuel Macron;male +Justin Trudeau;male +Boris Johnson;male +Narendra Modi;male +Hassan Rouhani;male +Benjamin Netanyahu;male +Recep Tayyip Erdogan;male +Moon Jae-in;male +Jair Bolsonaro;male +Alberto Fernández;male +Andrés Manuel López Obrador;male +Scott Morrison;male +Jacinda Ardern;female +Tsai Ing-wen;female +Aung San Suu Kyi;female +Kim Jong-un;male +King Salman bin Abdulaziz Al Saud;male +Sheikh Hasina;female +Abdel Fattah el-Sisi;male +Bashar al-Assad;male +Hassan Diab;male +Pope Francis;male +Pope John Paul II;male +Pope Benedict XVI;male +Pope John XXIII;male +Pope Pius XII;male +Julius Caesar;male +Alexander the Great;male +Cleopatra;female +Joan of Arc;female +Leonardo da Vinci;male +Michelangelo;male +Galileo Galilei;male +William Shakespeare;male +Isaac Newton;male +George Washington;male +Napoleon Bonaparte;male +Abraham Lincoln;male +Charles Darwin;male +Queen Victoria;female +Mahatma Gandhi;male +Albert Einstein;male +Franklin D. Roosevelt;male +Winston Churchill;male +Joseph Stalin;male +Adolf Hitler;male +Martin Luther King Jr.;male +John F. Kennedy;male +Neil Armstrong;male +Mao Zedong;male +Che Guevara;male +Pablo Picasso;male +Ronald Reagan;male +Margaret Thatcher;female +Nelson Mandela;male +Mother Teresa;female +Princess Diana;female +Saddam Hussein;male +Osama bin Laden;male +Steve Jobs;male +Bill Gates;male +Barack Obama;male +Queen Elizabeth II;female +Elon Musk;male +Jeff Bezos;male +Mark Zuckerberg;male +Oprah Winfrey;female +Serena Williams;female +Usain Bolt;male +Michael Jordan;male +A.J. Cook;female +Abbie Cornish;female +Adrianne Palicki;female +Agam Darshi;female +Aimee Garcia;female +Aishwariya Rai;female +Alanna Ubach;female +Alexa PenaVega;female +Alexandra Daddario;female +Alexis Bledel;female +Ali Cobrin;female +Ali Larter;female +Alice Braga;female +Alice Eve;female +Alice Greczyn;female +Alicia Silverstone;female +Alicia Vikander;female +Alicia Witt;female +Alison Lohman;female +Alison Pill;female +Aly Michalka;female +Alyson Hannigan;female +Alyssa Milano;female +Amanda Bynes;female +Amanda Peet;female +Amanda Seyfried;female +Amber Heard;female +Amrita Acharia;female +Amy Smart;female +Ana de la Reguera;female +Andie MacDowell;female +Andrea Navedo;female +Andrea Savage;female +Angela Trimbur;female +Anita Ekberg;female +Ann-Margret;female +Anna Chlumsky;female +Anna Faris;female +Anna Kendrick;female +Antoinette Kalaj;female +April Bowlby;female +April Hernandez Castillo;female +Ashley Greene;female +Ashley Judd;female +Ashley Olsen;female +Ashley Scott;female +Astrid Bergès-Frisbey;female +Aubrey Plaza;female +Ava Gardner;female +Bérénice Marlohe;female +Beverly D'Angelo;female +Bianca Kajlich;female +Blake Lively;female +Bo Derek;female +Bree Turner;female +Briana Evigan;female +Bridget Fonda;female +Bridgette Wilson-Sampras;female +Brigitte Bardot;female +Brittany Daniel;female +Brittany Murphy;female +Brittany Snow;female +Brooke Burns;female +Brooke D'Orsay;female +Brooke Shields;female +Brooklyn Decker;female +Cameron Diaz;female +Cameron Richardson;female +Camilla Belle;female +Candace Cameron Bure;female +Carey Mulligan;female +Carla Gallo;female +Carla Gugino;female +Carly Craig;female +Carmen Electra;female +Casey Wilson;female +Chandra West;female +Chloë Grace Moretz;female +Chloë Sevigny;female +Christian Serratos;female +Christina Applegate;female +Christina Ricci;female +Christine Lakin;female +Christine Taylor;female +Chyler Leigh;female +Claire Danes;female +Claire Forlani;female +Cobie Smulders;female +Cody Horn;female +Connie Nielsen;female +Courteney Cox;female +Courtney Thorne-Smith;female +Dakota Fanning;female +Dana Davis;female +Dania Ramirez;female +Danica McKellar;female +Daniela Bobadilla;female +Danielle Fishel;female +Danielle Harris;female +Danneel Ackles;female +Daryl Hannah;female +Deborah Ann Woll;female +Debra Messing;female +Demi Moore;female +Denise Richards;female +Diane Kruger;female +Diane Lane;female +Dianna Agron;female +Drea de Matteo;female +Drew Barrymore;female +Elena Anaya;female +Elisha Cuthbert;female +Eliza Coupe;female +Eliza Dushku;female +Elizabeth Banks;female +Elizabeth Berkley;female +Elizabeth Hurley;female +Elizabeth Olsen;female +Ellen Wong;female +Ellie Kemper;female +Elliot Page;female +Emily Blunt;female +Emily Browning;female +Emily Deschanel;female +Emma Greenwell;female +Emma Roberts;female +Emmanuelle Chriqui;female +Emmanuelle Vaugier;female +Emmy Rossum;female +Esmé Bianco;female +Estella Warren;female +Eva Longoria;female +Eva Mendes;female +Evan Rachel Wood;female +Frankie Shaw;female +Freida Pinto;female +Gabrielle Anwar;female +Gabrielle Union;female +Gal Gadot;female +Garcelle Beauvais;female +Gemma Arterton;female +Gemma Ward;female +Gene Tierney;female +Genesis Rodriguez;female +Genevieve Padalecki;female +Gina Gershon;female +Ginnifer Goodwin;female +Goldie Hawn;female +Gugu Mbatha-Raw;female +Gwyneth Paltrow;female +Hayden Panettiere;female +Heather Graham;female +Heather Locklear;female +Helena Bonham Carter;female +Helena Christensen;female +Helena Mattsson;female +Hilary Duff;female +Isla Fisher;female +Izabella Miko;female +Izabella Scorupco;female +Jada Pinkett Smith;female +Jaime King;female +Jaime Murray;female +Jaime Pressly;female +Jamie Chung;female +Jamie-Lynn Sigler;female +Janina Gavankar;female +January Jones;female +Jayne Mansfield;female +Jeanne Tripplehorn;female +Jenna Coleman;female +Jenna Elfman;female +Jenna Fischer;female +Jennie Garth;female +Jennifer Carpenter;female +Jennifer Connelly;female +Jennifer Esposito;female +Jennifer Garner;female +Jennifer Hudson;female +Jennifer Love Hewitt;female +Jennifer Morrison;female +Jennifer Taylor;female +Jenny McCarthy-Wahlberg;female +Jeri Ryan;female +Jessica Alba;female +Jessica Biel;female +Jessica Lange;female +Jessica Szohr;female +Joanne Whalley;female +Jodi Lyn O'Keefe;female +Jordan Ladd;female +Jordana Brewster;female +Jud Tylor;female +Julianna Guill;female +Julie Benz;female +Julie Bowen;female +Julie Christie;female +Juliette Lewis;female +K.D. Aubert;female +Kaitlin Doubleday;female +Kaley Cuoco;female +Kat Dennings;female +Kate Beckinsale;female +Kate Bosworth;female +Kate Hudson;female +Kate Mara;female +Katherine Heigl;female +Katherine LaNasa;female +Kathryn Hahn;female +Katie Cassidy;female +Katie Holmes;female +Katrina Bowden;female +Katy Mixon;female +Kelly Carlson;female +Kelly Hu;female +Kelly Stables;female +Keri Russell;female +Kerry Washington;female +Kim Basinger;female +Krista Allen;female +Kristen Bell;female +Kristen Stewart;female +Kristen Wiig;female +Kristin Chenoweth;female +Kristin Davis;female +Kristin Kreuk;female +Kristina Klebe;female +Kristy Swanson;female +Lacey Chabert;female +Lake Bell;female +Lalaine;female +Lara Flynn Boyle;female +Lark Voorhies;female +Laura Wiggins;female +Lauren Ambrose;female +Lauren Bacall;female +Lauren Holly;female +Lauren London;female +Lea Michele;female +Leah Remini;female +Leighton Meester;female +Lena Headey;female +Leslie Bibb;female +Leslie Mann;female +Li Gong;female +Lily Collins;female +Linda Cardellini;female +Lindsay Lohan;female +Lisa Bonet;female +Lizzy Caplan;female +Lucy Lawless;female +Lucy Liu;female +Lynda Carter;female +Lyndsy Fonseca;female +Madeleine Stowe;female +Madison Riley;female +Mae Whitman;female +Maggie Q;female +Mahaley Patel;female +Majandra Delfino;female +Malin Akerman;female +Maria Bello;female +Maria Grazia Cucinotta;female +Maria Thayer;female +Marin Hinkle;female +Marisa Coughlan;female +Marisa Tomei;female +Marley Shelton;female +Marsha Thomason;female +Mary Elizabeth Winstead;female +Mary McCormack;female +Mary-Kate Olsen;female +Mary-Louise Parker;female +Meg Ryan;female +Megan Fox;female +Megyn Price;female +Melanie Lynskey;female +Melissa George;female +Melissa Sagemiller;female +Melora Hardin;female +Mena Suvari;female +Mia Wasikowska;female +Michelle Borth;female +Michelle Burke;female +Michelle Monaghan;female +Michelle Trachtenberg;female +Michelle Williams;female +Milla Jovovich;female +Ming-Na Wen;female +Mini Anden;female +Minka Kelly;female +Molly Ringwald;female +Molly Sims;female +Moon Bloodgood;female +Natalia Tena;female +Natalie Dormer;female +Natasha Henstridge;female +Nathalie Kelley;female +Neve Campbell;female +Nicky Whelan;female +Nicole Ari Parker;female +Nicole Eggert;female +Nikki Reed;female +Nina Dobrev;female +Noureen DeWulf;female +Odette Annable;female +Olga Kurylenko;female +Olivia Thirlby;female +Olivia Wilde;female +Paget Brewster;female +Pamela Anderson;female +Parker Posey;female +Patricia Arquette;female +Paula Garcés;female +Paula Patton;female +Paz Vega;female +Penelope Cruz;female +Penélope Cruz;female +Phoebe Cates;female +Piper Perabo;female +Qi Shu;female +Rachael Leigh Cook;female +Rachel Bilson;female +Rachel Nichols;female +Rachel Specter;female +Rachel True;female +Raquel Welch;female +Rashida Jones;female +Rebecca Hall;female +Rebecca Romijn;female +Regina Hall;female +Renée Zellweger;female +Rhona Mitra;female +Rita Hayworth;female +Robin Tunney;female +Rochelle Aytes;female +Rooney Mara;female +Rosario Dawson;female +Rose Byrne;female +Rose McGowan;female +Roselyn Sanchez;female +Rumer Willis;female +Saffron Burrows;female +Samantha Mathis;female +Sara Paxton;female +Sarah Chalke;female +Sarah Hyland;female +Sarah Lancaster;female +Sarah Michelle Gellar;female +Sarah Roemer;female +Sarah Shahi;female +Sarah Silverman;female +Sasha Alexander;female +Scout Taylor-Compton;female +Selma Blair;female +Seychelle Gabriel;female +Shailene Woodley;female +Shannon Elizabeth;female +Shannyn Sossamon;female +Shanola Hampton;female +Sharon Stone;female +Shawnee Smith;female +Sheri Moon Zombie;female +Shu Qi;female +Sienna Miller;female +Sofia Vergara;female +Sofía Vergara;female +Sophia Loren;female +Sophie Winkleman;female +Stacey Dash;female +Stella Maeve;female +Stephanie Fantauzzi;female +Stephanie Szostak;female +Susan Ward;female +Sydney Tamiia Poitier;female +Tara Reid;female +Teresa Palmer;female +Teri Polo;female +Thandiwe Newton;female +Thora Birch;female +Tia Carrere;female +Tiffani Thiessen;female +Traci Bingham;female +Tracie Thoms;female +Ursula Andress;female +Vanessa Angel;female +Vanessa Ferlito;female +Vanessa Hudgens;female +Vanessa Lengies;female +Vanessa Williams;female +Vera Farmiga;female +Veronica Lake;female +Vinessa Shaw;female +Vivica A. Fox;female +Winona Ryder;female +Yvonne De Carlo;female +Yvonne Strahovski;female +Ziyi Zhang;female +Zooey Deschanel;female +Zoë Bell;female +Zoë Kravitz;female +Zulay Henao;female +Arnold Schwarzenegger;male +Bruce Willis;male +Chris Pratt;male +Daniel Craig;male +David Duchovny;male +Dustin Hoffman;male +Dwayne Johnson;male +Emile Hirsch;male +Erik Per Sullivan;male +Gerald Butler;male +Grant Gustin;male +Ian Somerhalder;male +Jack Nicholson;male +Jackie Chan;male +Jason Momoa;male +Jimmy Fallon;male +John Boyega;male +John Cusack;male +Johnny Depp;male +Josh Brolin;male +Kevin Hart;male +Kit Harington;male +Michael Douglas;male +Michael J. Fox;male +Michael Sheen;male +Michael Weatherly;male +Mike Myers;male +Nathan Fillion;male +Nathan Lane;male +Paul Walker;male +Ray Romano;male +Russell Crowe;male +Scott Speedman;male +Sebastian Stan;male +Shah Rukh Khan;male +Stephen Amell;male +Taylor Lautner;male +Timothée Chalamet;male +Toby Kebbell;male +Tom Hiddleston;male +Tommy Lee Jones;male +Tony Goldwyn;male +Tyler Hoechlin;male +Vince Vaughn;male +Addison Rae;female +Adèle Exarchopoulos;female +Aimee Lou Wood;female +AJ Lee;female +Alanna Masterson;female +Alejandra Guilmant;female +Alex Morgan;female +Alexa Bliss;female +Alexis Ren;female +Alica Schmidt;female +Alison Brie;female +Allison Stokke;female +Allison Williams;female +Aly Raisman;female +Alycia Debnam-Carey;female +Amanda Cerny;female +Ana de Armas;female +Angela Kinsey;female +Angela Sarafyan;female +Anitta;female +Anna Akana;female +Anna Kournikova;female +Anna Paquin;female +AnnaSophia Robb;female +Anya Chalotra;female +Ariel Winter;female +Ashley Benson;female +Ashley Graham;female +Ashley Park;female +Ashley Tisdale;female +Auli’i Cravalho;female +Avril Lavigne;female +Awkwafina;female +Bailee Madison;female +Bar Refaeli;female +Barbara Palvin;female +Bebe Rexha;female +Becky G;female +Becky Lynch;female +Bella Thorne;female +Beth Behrs;female +Betty Gilpin;female +Bonnie Wright;female +Brenda Song;female +Brianna Hildebrand;female +Brie Bella;female +Brighton Sharbino;female +Caity Lotz;female +Camila Cabello;female +Camila Mendes;female +Camilla Luddington;female +Candice Swanepoel;female +Cardi B;female +Carice van Houten;female +Carly Rae Jepsen;female +Caroline Vreeland;female +Caylee Cowan;female +Charisma Carpenter;female +Charli D’Amelio;female +Charli XCX;female +Charlotte Flair;female +Charlotte McKinney;female +Chelsea Handler;female +Chloe Bennet;female +Chloe Kim;female +Chrissy Teigen;female +Christen Harper;female +Christina Hendricks;female +CJ Perry;female +Cristin Milioti;female +Daisy Edgar-Jones;female +Daisy Ridley;female +Dakota Johnson;female +Danielle Panabaker;female +Debby Ryan;female +Demi Rose;female +Diana Silvers;female +Diane Guerrero;female +Diora Baird;female +Disha Patani;female +Dixie D’Amelio;female +Doja Cat;female +Dominique McElligott;female +Dove Cameron;female +Eiza González;female +Eleanor Tomlinson;female +Elisabeth Shue;female +Elizabeth Debicki;female +Elizabeth Gillies;female +Elizabeth Turner;female +Ellie Goulding;female +Elsa Hosk;female +Elsa Pataky;female +Elsie Hewitt;female +Emily Bett Rickards;female +Emily Kinney;female +Emily Osment;female +Emily Ratajkowski;female +Emily VanCamp;female +Emma Kenney;female +Emma Mackey;female +Emma Raducanu;female +Erin Moriarty;female +Eugenie Bouchard;female +Eva Amurri;female +Evangeline Lilly;female +Felicity Jones;female +Florence Pugh;female +Freya Allan;female +Giada De Laurentiis;female +Gillian Anderson;female +Gillian Jacobs;female +Gina Carano;female +Hailee Steinfeld;female +Hailey Bieber;female +Halsey;female +Hannah Simone;female +Hayley Atwell;female +Helene Fischer;female +Holly Willoughby;female +HoYeon Jung;female +Hunter King;female +Hunter Schafer;female +Iggy Azalea;female +Ilana Glazer;female +Iliza Shlesinger;female +Imogen Poots;female +Ireland Baldwin;female +Iris Apatow;female +Isabela Merced;female +Isidora Goreshter;female +Jackie Cruz;female +Jaimie Alexander;female +Jamie Lee Curtis;female +Jane Levy;female +Jenna Dewan;female +Jennette McCurdy;female +Jennifer Holland;female +Jenny Slate;female +Jessica Parker Kennedy;female +Jessica Paré;female +Jessica Simpson;female +Jewel Staite;female +Jodie Comer;female +Joey King;female +JoJo;female +Jordyn Huitema;female +Jordyn Jones;female +Josephine Skriver;female +Judy Greer;female +Julia Fox;female +Julia Garner;female +Julianne Hough;female +Juno Temple;female +Jutta Leerdam;female +Kaia Gerber;female +Kaitlyn Dever;female +Karen Fukuhara;female +Karen Gillan;female +Kate Upton;female +Katelyn Nacon;female +Katelyn Ohashi;female +Katherine Langford;female +Katherine McNamara;female +Katherine Waterston;female +Katheryn Winnick;female +Kaya Scodelario;female +Kelly Brook;female +Kelly Rohrbach;female +Kesha;female +Khloé Kardashian;female +Kiernan Shipka;female +Kim Kardashian;female +Kimberley Garner;female +Kimiko Glenn;female +Kira Kosarin;female +Kourtney Kardashian;female +Krysten Ritter;female +Kylie Jenner;female +Kylie Minogue;female +Lais Ribeiro;female +Lana Del Rey;female +Larsen Thompson;female +Laura Harrier;female +Laura Prepon;female +Lauren Cohan;female +Lea Seydoux;female +Leelee Sobieski;female +Leila Lowfire;female +Lena Gercke;female +Lena Meyer-Landrut;female +Lili Reinhart;female +Lili Simmons;female +Lily Chee;female +Lily James;female +Lily Sheen;female +Lily-Rose Depp;female +Lindsey Pelas;female +Lindsey Vonn;female +Lisa Kudrow;female +Lucy Hale;female +Lucy Pinder;female +Lupita Nyong’o;female +Mackenzie Davis;female +Mackenzie Foy;female +Mackenzie Ziegler;female +Maddie Ziegler;female +Madelaine Petsch;female +Madison Beer;female +Madison Pettis;female +Madisyn Shipman;female +Maggie Grace;female +Maia Mitchell;female +Maisie Williams;female +Malin Åkerman;female +Mandy Moore;female +Margaret Qualley;female +Maria Bakalova;female +Maria Menounos;female +Maria Sharapova;female +Maryse;female +María Pedraza;female +Maude Apatow;female +Maya Hawke;female +McKayla Maroney;female +Meagan Good;female +Megan Thee Stallion;female +Meghan Markle;female +Melissa Benoist;female +Melissa Fumero;female +Melissa Rauch;female +Michelle Jenneke;female +Miesha Tate;female +Milana Vayntrub;female +Millie Bobby Brown;female +Miranda Cosgrove;female +Miranda Kerr;female +Morena Baccarin;female +Naomi Scott;female +Natalia Dyer;female +Natalie Alyn Lind;female +Natasha Lyonne;female +Nathalie Emmanuel;female +Nicki Minaj;female +Nicole Scherzinger;female +Nikki Bella;female +Nikki Glaser;female +Nina Agdal;female +Normani;female +Olivia Culpo;female +Olivia Munn;female +Olivia Rodrigo;female +Olivia Taylor Dudley;female +Padma Lakshmi;female +Paige;female +Paige Spiranac;female +Paige VanZant;female +Palina Rojinski;female +Paris Hilton;female +Paulina Gaitán;female +Peyton List;female +Phoebe Tonkin;female +Pokimane;female +Pom Klementieff;female +Priyanka Chopra;female +Rachel Brosnahan;female +Rachel Cook;female +Rachel Zegler;female +Rebecca Black;female +Rebecca Ferguson;female +Rhea Seehorn;female +Rita Ora;female +Ronda Rousey;female +Ronja Forcher;female +Rosamund Pike;female +Rose Leslie;female +Rose McIver;female +Rosie Huntington-Whiteley;female +Ruby O. Fee;female +Ruby Rose;female +Sabrina Carpenter;female +Sadie Sink;female +Samara Weaving;female +Sammi Hanratty;female +Sara Sampaio;female +Sara Underwood;female +Sarah McDaniel;female +Sarah Paulson;female +Sasha Banks;female +Saweetie;female +Shantel VanSanten;female +Simone Biles;female +Sophia Lillis;female +Sophia Thomalla;female +Sophie Turner;female +Stacy Keibler;female +Stephanie Beatriz;female +Stephanie McMahon;female +Susan Sarandon;female +Sydney Sweeney;female +Taylor Hill;female +Taylor Schilling;female +Tessa Thompson;female +Thomasin McKenzie;female +Tina Fey;female +Torrie Wilson;female +Tove Lo;female +Ursula Corberó;female +Vanessa Kirby;female +Vica Kerekes;female +Victoria De Angelis;female +Victoria Justice;female +Whitney Cummings;female +Willa Fitzgerald;female +Willa Holland;female +Yanet Garcia;female +Zazie Beetz;female +Zendaya;female +Zoey Deutch;female \ No newline at end of file diff --git a/prompttester.py b/prompttester.py index 834f026..0cd1b39 100644 --- a/prompttester.py +++ b/prompttester.py @@ -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): +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"): 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 - result = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance) + result = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender) print("") print("loop " + str(steps)) @@ -46,4 +46,4 @@ def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", im print("") print("All done!") -generateprompts(10,5,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100) \ No newline at end of file +generateprompts(10,5,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100, "female") \ No newline at end of file diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index 3b9aad5..f37b8df 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -22,6 +22,7 @@ promptmode = ["at the back", "in the front"] promptcompounder = ["1", "2", "3", "4", "5"] ANDtogglemode = ["none", "automatic", "prefix AND prompt + suffix", "prefix + prefix + prompt + suffix"] seperatorlist = ["comma", "AND", "BREAK"] +genders = ["all", "male", "female"] #for autorun and upscale sizelist = ["all", "portrait", "wide", "square", "ultrawide"] @@ -143,8 +144,10 @@ class Script(scripts.Script): with gr.Row(): givensubject = gr.Textbox(label="Overwrite subject: ", value="") smartsubject = gr.Checkbox(label="Smart subject", value = True) - with gr.Row(): giventypeofimage = gr.Textbox(label="Overwrite type of image: ", value="") + with gr.Row(): + chosengender = gr.Dropdown( + genders, "gender", value="all", visible=False) with gr.Row(): gr.Markdown(""" @@ -570,6 +573,18 @@ class Script(scripts.Script): 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]) automatedoutputsfolderbutton.click(openfolder) + + # turn things on and off for gender + def subjectsvalue(subject): + enable=(subject=="humanoid") + return { + chosengender: gr.update(visible=enable), + } + subject.change( + subjectsvalue, + [subject], + [chosengender] + ) # Turn things off and on for onlyupscale and txt2img def onlyupscalevalues(onlyupscale): From 5b16e878e9b9240231dbad17cf5d3b0c0f5c72f8 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Sat, 8 Jul 2023 09:02:19 +0200 Subject: [PATCH 10/18] Added in gender selection (complete) --- csvfiles/manwoman.csv | 6 +++++- csvfiles/manwomanrelations.csv | 2 -- main.py | 4 ++-- scripts/api.py | 5 +++-- scripts/onebuttonprompt.py | 21 +++++++++++---------- 5 files changed, 21 insertions(+), 17 deletions(-) diff --git a/csvfiles/manwoman.csv b/csvfiles/manwoman.csv index d3b3db5..576063c 100644 --- a/csvfiles/manwoman.csv +++ b/csvfiles/manwoman.csv @@ -1,3 +1,7 @@ manwoman;gender Man;male -Woman;female \ No newline at end of file +Woman;female +Boy;male +Girl;female +Male;male +Female;female \ No newline at end of file diff --git a/csvfiles/manwomanrelations.csv b/csvfiles/manwomanrelations.csv index f90b27a..7376340 100644 --- a/csvfiles/manwomanrelations.csv +++ b/csvfiles/manwomanrelations.csv @@ -1,6 +1,4 @@ manwomanrelation;gender -Boy;male -Girl;female Mother;female Father;male Grandma;female diff --git a/main.py b/main.py index a77db0a..4c818bf 100644 --- a/main.py +++ b/main.py @@ -12,7 +12,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): +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"): loops = int(amount) # amount of images to generate steps = 0 upscalefilelist=[] @@ -70,7 +70,7 @@ def generateimages(amount = 1, size = "all",model = "currently selected model",s print(workprompt) else: - randomprompt = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, False,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance) + randomprompt = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, False,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender) # make the filename, from from a to the first comma start_index = randomprompt.find("of a ") + len("of a ") diff --git a/scripts/api.py b/scripts/api.py index 77c5bc6..9b3abc9 100644 --- a/scripts/api.py +++ b/scripts/api.py @@ -34,12 +34,13 @@ def one_button_prompt_api(_: gr.Blocks, app: FastAPI): givensubject: str =Body('',title="givensubject"), smartsubject:bool = Body(True,title='smart subject'), giventypeofimage: str = Body('',title='given type of image'), - imagemodechance: int = Body(20,title='image mode chance')): + imagemodechance: int = Body(20,title='image mode chance'), + gender: str = Body('all',title="gender")): keys = ['insanitylevel', 'forcesubject', 'artists', 'imagetype', 'onlyartists', 'antivalues', 'prefixprompt', 'suffixprompt', 'promptcompounderlevel', 'seperator', 'givensubject', 'smartsubject', 'giventypeofimage', - 'imagemodechance'] + 'imagemodechance', 'gender'] payload = {} for key in keys: payload[key] = locals()[key] diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index f37b8df..fcdb0f8 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -80,12 +80,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): + def gen_prompt(insanitylevel, subject, artist, imagetype, antistring, prefixprompt, suffixprompt, promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage, imagemodechance,chosengender): 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)) + promptlist.append(build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring,prefixprompt,suffixprompt,promptcompounderlevel,seperator,givensubject,smartsubject, giventypeofimage, imagemodechance,chosengender)) return promptlist @@ -127,6 +127,9 @@ class Script(scripts.Script): with gr.Column(scale=1, variant="compact"): artist = gr.Dropdown( artists, label="Artists", value="all") + with gr.Row(): + chosengender = gr.Dropdown( + genders, label="gender", value="all", visible=False) with gr.Row(): with gr.Column(scale=2, variant="compact"): imagetype = gr.Dropdown( @@ -144,10 +147,8 @@ class Script(scripts.Script): with gr.Row(): givensubject = gr.Textbox(label="Overwrite subject: ", value="") smartsubject = gr.Checkbox(label="Smart subject", value = True) - giventypeofimage = gr.Textbox(label="Overwrite type of image: ", value="") with gr.Row(): - chosengender = gr.Dropdown( - genders, "gender", value="all", visible=False) + giventypeofimage = gr.Textbox(label="Overwrite type of image: ", value="") with gr.Row(): gr.Markdown(""" @@ -562,7 +563,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], 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], outputs=[prompt1, prompt2, prompt3,prompt4,prompt5]) prompt1toworkflow.click(prompttoworkflowprompt, inputs=prompt1, outputs=workprompt) prompt2toworkflow.click(prompttoworkflowprompt, inputs=prompt2, outputs=workprompt) @@ -570,7 +571,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]) + 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]) automatedoutputsfolderbutton.click(openfolder) @@ -688,12 +689,12 @@ class Script(scripts.Script): - return [insanitylevel,subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring, seperator, givensubject, smartsubject, giventypeofimage, imagemodechance] + return [insanitylevel,subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring, seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender] - def run(self, p, insanitylevel, subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring,seperator, givensubject, smartsubject, giventypeofimage, imagemodechance): + def run(self, p, insanitylevel, subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring,seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender): images = [] infotexts = [] @@ -765,7 +766,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) + preppedprompt += build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring, prefixprompt, suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance,chosengender) # set the artist mode back when done (for automatic mode) artist = artistcopy From b9d59b927db8e3989da82c344dc5c7004471eec0 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Sat, 8 Jul 2023 11:04:56 +0200 Subject: [PATCH 11/18] added subtype options + interface changes --- build_dynamic_prompt.py | 39 +++++++- main.py | 4 +- prompttester.py | 6 +- scripts/api.py | 8 +- scripts/onebuttonprompt.py | 192 ++++++++++++++++++++++++++++++++++--- 5 files changed, 225 insertions(+), 24 deletions(-) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index b844fb3..3fe8a12 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -10,7 +10,7 @@ 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"): +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"): # load the config file @@ -872,11 +872,33 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all if(mainchooser == "humanoid"): #humanoidsubjectchooserlist = ["human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] subjectchooser = random.choice(humanoidsubjectchooserlist) + if(subtypehumanoid != "all"): + if(subtypehumanoid == "generic humans"): + subjectchooser = "human" + if(subtypehumanoid == "generic human relations"): + subjectchooser = "manwomanrelation" + if(subtypehumanoid == "celebrities e.a."): + subjectchooser = "non fictional" + if(subtypehumanoid == "fictional characters"): + subjectchooser = "fictional" + if(subtypehumanoid == "humanoids"): + subjectchooser = "humanoid" + if(subtypehumanoid == "based on job or title"): + subjectchooser = "job" if(mainchooser == "landscape"): subjectchooser = "landscape" if(mainchooser == "concept"): - #eventsubjectchooserlist = ["event", "concept"] + #eventsubjectchooserlist = ["event", "concept", "poemline", "songline"] subjectchooser = random.choice(eventsubjectchooserlist) + if(subtypeconcept != "all"): + if(subtypeconcept == "event"): + subjectchooser = "event" + if(subtypeconcept == "the X of Y concepts"): + subjectchooser = "concept" + if(subtypeconcept == "lines from poems"): + subjectchooser = "poemline" + if(subtypeconcept == "lines from songs"): + subjectchooser = "songline" @@ -1189,7 +1211,18 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all completeprompt += "-culture- " if(mainchooser == "object"): - objectwildcardlist = ["-object-", "-building-","-vehicle-","-food-", "-space-"] # using wildcards for replacements + # if we have an overwrite, then make sure we only take the override + if(subtypeobject != "all"): + if(subtypeobject == "generic objects"): + objectwildcardlist = ["-object-"] + if(subtypeobject == "vehicles"): + objectwildcardlist = ["-vehicle-"] + if(subtypeobject == "food"): + objectwildcardlist = ["-food-"] + if(subtypeobject == "buildings"): + objectwildcardlist = ["-building-"] + if(subtypeobject == "space"): + objectwildcardlist = ["-space-"] # if we have a given subject, we should skip making an actual subject if(givensubject == ""): diff --git a/main.py b/main.py index 4c818bf..2c60b6a 100644 --- a/main.py +++ b/main.py @@ -12,7 +12,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"): +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"): loops = int(amount) # amount of images to generate steps = 0 upscalefilelist=[] @@ -70,7 +70,7 @@ def generateimages(amount = 1, size = "all",model = "currently selected model",s print(workprompt) else: - randomprompt = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, False,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender) + randomprompt = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, False,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept) # make the filename, from from a to the first comma start_index = randomprompt.find("of a ") + len("of a ") diff --git a/prompttester.py b/prompttester.py index 0cd1b39..3d6528d 100644 --- a/prompttester.py +++ b/prompttester.py @@ -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"): +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"): 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 - result = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender) + result = build_dynamic_prompt(insanitylevel,subject,artist,imagetype, onlyartists,antistring,prefixprompt,suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance, gender, subtypeobject, subtypehumanoid, subtypeconcept) print("") print("loop " + str(steps)) @@ -46,4 +46,4 @@ def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", im print("") print("All done!") -generateprompts(10,5,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100, "female") \ No newline at end of file +generateprompts(10,5,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100, "female", "all", "fictional characters", "all") \ No newline at end of file diff --git a/scripts/api.py b/scripts/api.py index 9b3abc9..34def4d 100644 --- a/scripts/api.py +++ b/scripts/api.py @@ -35,12 +35,16 @@ def one_button_prompt_api(_: gr.Blocks, app: FastAPI): smartsubject:bool = Body(True,title='smart subject'), giventypeofimage: str = Body('',title='given type of image'), imagemodechance: int = Body(20,title='image mode chance'), - gender: str = Body('all',title="gender")): + gender: str = Body('all',title='gender'), + subtypeobject: str = Body('all',title='subtypeobject'), + subtypehumanoid: str = Body('all', title='subtypehumanoid'), + subtypeconcept: str = Body('all', title='subtypeconcept') + ): keys = ['insanitylevel', 'forcesubject', 'artists', 'imagetype', 'onlyartists', 'antivalues', 'prefixprompt', 'suffixprompt', 'promptcompounderlevel', 'seperator', 'givensubject', 'smartsubject', 'giventypeofimage', - 'imagemodechance', 'gender'] + 'imagemodechance', 'gender', 'subtypeobject','subtypehumanoid','subtypeconcept'] payload = {} for key in keys: payload[key] = locals()[key] diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index fcdb0f8..a30d41d 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -15,7 +15,12 @@ from main import * from model_lists import * from csv_reader import * -subjects = ["all","object","animal","humanoid", "landscape", "concept"] + +#subjects = ["all","object","animal","humanoid", "landscape", "concept"] +subjects =["all"] +subjectsubtypesobject = ["all"] +subjectsubtypeshumanoid = ["all"] +subjectsubtypesconcept = ["all"] artists = ["all", "none", "popular", "greg mode", "3D", "abstract", "angular", "anime" ,"architecture", "art nouveau", "art deco", "baroque", "bauhaus", "cartoon", "character", "children's illustration", "cityscape", "clean", "cloudscape", "collage", "colorful", "comics", "cubism", "dark", "detailed", "digital", "expressionism", "fantasy", "fashion", "fauvism", "figurativism", "gore", "graffiti", "graphic design", "high contrast", "horror", "impressionism", "installation", "landscape", "light", "line drawing", "low contrast", "luminism", "magical realism", "manga", "melanin", "messy", "monochromatic", "nature", "nudity", "photography", "pop art", "portrait", "primitivism", "psychedelic", "realism", "renaissance", "romanticism", "scene", "sci-fi", "sculpture", "seascape", "space", "stained glass", "still life", "storybook realism", "street art", "streetscape", "surrealism", "symbolism", "textile", "ukiyo-e", "vibrant", "watercolor", "whimsical"] imagetypes = ["all", "all - force multiple", "photograph", "octane render","digital art","concept art", "painting", "portrait", "anime key visual", "only other types", "only templates mode", "art blaster mode", "quality vomit mode", "color cannon mode", "unique art mode", "massive madness mode", "photo fantasy mode", "subject only mode"] promptmode = ["at the back", "in the front"] @@ -67,8 +72,124 @@ for filename in os.listdir(userfilesfolder): artists.insert(2, name) # on startup, check if we have a config file, or else create it -load_config_csv() - +config = load_config_csv() + +# load subjects stuff from config +generatevehicle = True +generateobject = True +generatefood = True +generatebuilding = True +generatespace = True +generateanimal = True +generatemanwoman = True +generatemanwomanrelation = True +generatefictionalcharacter = True +generatenonfictionalcharacter = True +generatehumanoids = True +generatejob = True +generatelandscape = True +generateevent = True +generateconcepts = True +generatepoemline = True +generatesongline = True + + +for item in config: + # objects + if item[0] == 'subject_vehicle' and item[1] != 'on': + generatevehicle = False + if item[0] == 'subject_object' and item[1] != 'on': + generateobject = False + if item[0] == 'subject_food' and item[1] != 'on': + generatefood = False + if item[0] == 'subject_building' and item[1] != 'on': + generatebuilding = False + if item[0] == 'subject_space' and item[1] != 'on': + generatespace = False + # animals + if item[0] == 'subject_animal' and item[1] != 'on': + generateanimal = False + # humanoids + if item[0] == 'subject_manwoman' and item[1] != 'on': + generatemanwoman = False + if item[0] == 'subject_manwomanrelation' and item[1] != 'on': + generatemanwomanrelation = False + if item[0] == 'subject_fictional' and item[1] != 'on': + generatefictionalcharacter = False + if item[0] == 'subject_nonfictional' and item[1] != 'on': + generatenonfictionalcharacter = False + if item[0] == 'subject_humanoid' and item[1] != 'on': + generatehumanoids = False + if item[0] == 'subject_job' and item[1] != 'on': + generatejob = False + # landscape + if item[0] == 'subject_landscape' and item[1] != 'on': + generatelandscape = False + # concept + if item[0] == 'subject_event' and item[1] != 'on': + generateevent = False + if item[0] == 'subject_concept' and item[1] != 'on': + generateconcepts = False + if item[0] == 'poemline' and item[1] != 'on': + generatepoemline = False + if item[0] == 'songline' and item[1] != 'on': + generatesongline = False + +# build up all subjects we can choose based on the loaded config file +if(generatevehicle or generateobject or generatefood or generatebuilding or generatespace): + subjects.append("object") +if(generateanimal): + subjects.append("animal") +if(generatemanwoman or generatemanwomanrelation or generatefictionalcharacter or generatenonfictionalcharacter or generatehumanoids or generatejob): + subjects.append("humanoid") +if(generatelandscape): + subjects.append("landscape") +if(generateevent or generateconcepts or generatepoemline or generatesongline): + subjects.append("concept") + + +# do the same for the subtype subjects +# subjectsubtypesobject = ["all"] +# subjectsubtypeshumanoid = ["all"] +# subjectsubtypesconcept = ["all"] + +# objects first +if(generateobject): + subjectsubtypesobject.append("generic objects") +if(generatevehicle): + subjectsubtypesobject.append("vehicles") +if(generatefood): + subjectsubtypesobject.append("food") +if(generatebuilding): + subjectsubtypesobject.append("buildings") +if(generatespace): + subjectsubtypesobject.append("space") + +# humanoids (should I review descriptions??) +if(generatemanwoman): + subjectsubtypeshumanoid.append("generic humans") +if(generatemanwomanrelation): + subjectsubtypeshumanoid.append("generic human relations") +if(generatenonfictionalcharacter): + subjectsubtypeshumanoid.append("celebrities e.a.") +if(generatefictionalcharacter): + subjectsubtypeshumanoid.append("fictional characters") +if(generatehumanoids): + subjectsubtypeshumanoid.append("humanoids") +if(generatejob): + subjectsubtypeshumanoid.append("based on job or title") + +# concepts +if(generateevent): + subjectsubtypesconcept.append("event") +if(generateconcepts): + subjectsubtypesconcept.append("the X of Y concepts") +if(generatepoemline): + subjectsubtypesconcept.append("lines from poems") +if(generatesongline): + subjectsubtypesconcept.append("lines from songs") + + class Script(scripts.Script): @@ -80,12 +201,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): + def gen_prompt(insanitylevel, subject, artist, imagetype, antistring, prefixprompt, suffixprompt, promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage, imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept): 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)) + promptlist.append(build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring,prefixprompt,suffixprompt,promptcompounderlevel,seperator,givensubject,smartsubject, giventypeofimage, imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept)) return promptlist @@ -128,6 +249,12 @@ class Script(scripts.Script): artist = gr.Dropdown( artists, label="Artists", value="all") with gr.Row(): + chosensubjectsubtypeobject = gr.Dropdown( + subjectsubtypesobject, label="Type of object", value="all", visible=False) + chosensubjectsubtypehumanoid = gr.Dropdown( + subjectsubtypeshumanoid, label="Type of humanoids", value="all", visible=False) + chosensubjectsubtypeconcept = gr.Dropdown( + subjectsubtypesconcept, label="Type of concept", value="all", visible=False) chosengender = gr.Dropdown( genders, label="gender", value="all", visible=False) with gr.Row(): @@ -147,8 +274,6 @@ class Script(scripts.Script): with gr.Row(): givensubject = gr.Textbox(label="Overwrite subject: ", value="") smartsubject = gr.Checkbox(label="Smart subject", value = True) - with gr.Row(): - giventypeofimage = gr.Textbox(label="Overwrite type of image: ", value="") with gr.Row(): gr.Markdown(""" @@ -168,6 +293,8 @@ class Script(scripts.Script): """ ) + with gr.Row(): + giventypeofimage = gr.Textbox(label="Overwrite type of image: ", value="") with gr.Row(): with gr.Column(): antistring = gr.Textbox(label="Filter out following properties (comma seperated). Example ""film grain, purple, cat"" ") @@ -415,11 +542,11 @@ class Script(scripts.Script): """ ### TXT2IMG - Start WebUi with option --api for this to work. This is not needed for Vlad. + Start WebUi with option --api for this to work. This is not needed for Vlad SD Next. Note: This part is entirely optional and you can use the normal generate button. - This part is intended for running an upscaling at the same time. + This part is only intended for running an upscaling at the same time. """ ) @@ -563,7 +690,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], 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], outputs=[prompt1, prompt2, prompt3,prompt4,prompt5]) prompt1toworkflow.click(prompttoworkflowprompt, inputs=prompt1, outputs=workprompt) prompt2toworkflow.click(prompttoworkflowprompt, inputs=prompt2, outputs=workprompt) @@ -571,7 +698,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]) + 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]) automatedoutputsfolderbutton.click(openfolder) @@ -586,7 +713,44 @@ class Script(scripts.Script): [subject], [chosengender] ) + + # turn things on and off for subject subtype object + def subjectsvalueforsubtypeobject(subject): + enable=(subject=="object") + return { + chosensubjectsubtypeobject: gr.update(visible=enable), + } + subject.change( + subjectsvalueforsubtypeobject, + [subject], + [chosensubjectsubtypeobject] + ) + # turn things on and off for subject subtype humanoid + def subjectsvalueforsubtypeobject(subject): + enable=(subject=="humanoid") + return { + chosensubjectsubtypehumanoid: gr.update(visible=enable), + } + subject.change( + subjectsvalueforsubtypeobject, + [subject], + [chosensubjectsubtypehumanoid] + ) + + # turn things on and off for subject subtype concept + def subjectsvalueforsubtypeconcept(subject): + enable=(subject=="concept") + return { + chosensubjectsubtypeconcept: gr.update(visible=enable), + } + subject.change( + subjectsvalueforsubtypeconcept, + [subject], + [chosensubjectsubtypeconcept] + ) + + # Turn things off and on for onlyupscale and txt2img def onlyupscalevalues(onlyupscale): onlyupscale = not onlyupscale @@ -689,12 +853,12 @@ class Script(scripts.Script): - return [insanitylevel,subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring, seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender] + return [insanitylevel,subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring, seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept] - def run(self, p, insanitylevel, subject, artist, imagetype, prefixprompt,suffixprompt,negativeprompt, promptcompounderlevel, ANDtoggle, silentmode, workprompt, antistring,seperator, givensubject, smartsubject, giventypeofimage, imagemodechance, chosengender): + 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): images = [] infotexts = [] @@ -766,7 +930,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) + preppedprompt += build_dynamic_prompt(insanitylevel,subject,artist, imagetype, False, antistring, prefixprompt, suffixprompt,promptcompounderlevel, seperator,givensubject,smartsubject,giventypeofimage,imagemodechance,chosengender, chosensubjectsubtypeobject, chosensubjectsubtypehumanoid, chosensubjectsubtypeconcept) # set the artist mode back when done (for automatic mode) artist = artistcopy From b2f29a32edec7c02aa6f91921bbdb156a3e25819 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Sat, 8 Jul 2023 12:51:59 +0200 Subject: [PATCH 12/18] Update onebuttonprompt.py --- scripts/onebuttonprompt.py | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index a30d41d..4a2370b 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -957,6 +957,7 @@ class Script(scripts.Script): p.prompt = promptlist p.batch_size = batchsize + p.hr_prompt = promptlist processed = process_images(p) images += processed.images infotexts += processed.infotexts From e5083da95a20c26aaa0757d4fd456d54c6aa7ade Mon Sep 17 00:00:00 2001 From: AIrjen Date: Sat, 8 Jul 2023 15:52:55 +0200 Subject: [PATCH 13/18] Added logic for running on firstnames added giant first name list --- build_dynamic_prompt.py | 54 +- csvfiles/config/default_config.csv | 1 + csvfiles/cultures.csv | 1 - csvfiles/firstnames.csv | 1596 ++++++++++++++++++++++++++++ csvfiles/nature.csv | 81 ++ csvfiles/objects.csv | 20 - prompttester.py | 2 +- scripts/onebuttonprompt.py | 5 + 8 files changed, 1724 insertions(+), 36 deletions(-) create mode 100644 csvfiles/firstnames.csv create mode 100644 csvfiles/nature.csv diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index 3fe8a12..305f6c4 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -88,6 +88,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all manwomanrelationlist = csv_to_list(csvfilename="manwomanrelations",antilist=antilist,skipheader=True,gender=gender) waterlocationlist = csv_to_list("waterlocations", antilist) containerlist = csv_to_list("containers", antilist) + firstnamelist = csv_to_list(csvfilename="firstnames",antilist=antilist,skipheader=True,gender=gender) humanlist = fictionallist + nonfictionallist + humanoidlist objecttotallist = objectlist + buildinglist + vehiclelist + foodlist + spacelist @@ -163,6 +164,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all generatenonfictionalcharacter = True generatehumanoids = True generatejob = True + generatefirstnames = True generatelandscape = True generateevent = True generateconcepts = True @@ -270,6 +272,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all generatehumanoids = False if item[0] == 'subject_job' and item[1] != 'on': generatejob = False + if item[0] == 'subject_firstnames' and item[1] != 'on': + generatefirstnames = False # landscape if item[0] == 'subject_landscape' and item[1] != 'on': generatelandscape = False @@ -459,7 +463,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all generatemanwoman = bool(manwomanlist) and generatemanwoman generatemanwomanrelation = bool(manwomanrelationlist) and generatemanwomanrelation generatejob = bool(joblist) and generatejob - generatehumanoid = generatefictionalcharacter or generatenonfictionalcharacter or generatehumanoids or generatemanwoman or generatejob or generatemanwomanrelation + generatefirstnames = bool(firstnamelist) and generatefirstnames + generatehumanoid = generatefictionalcharacter or generatenonfictionalcharacter or generatehumanoids or generatemanwoman or generatejob or generatemanwomanrelation or generatefirstnames if(generatefictionalcharacter): @@ -488,6 +493,9 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all if(generatehumanoid): mainchooserlist.append("humanoid") + + if(generatefirstnames): + humanoidsubjectchooserlist.append("firstname") generateanimal = bool(animallist) and generateanimal @@ -870,7 +878,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all else: subjectchooser = "animal as human" if(mainchooser == "humanoid"): - #humanoidsubjectchooserlist = ["human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] + #humanoidsubjectchooserlist = ["human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation", "firstname"] subjectchooser = random.choice(humanoidsubjectchooserlist) if(subtypehumanoid != "all"): if(subtypehumanoid == "generic humans"): @@ -885,6 +893,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all subjectchooser = "humanoid" if(subtypehumanoid == "based on job or title"): subjectchooser = "job" + if(subtypehumanoid == "based on first name"): + subjectchooser = "firstname" if(mainchooser == "landscape"): subjectchooser = "landscape" if(mainchooser == "concept"): @@ -1204,10 +1214,10 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all if(chance_roll(insanitylevel, subjectdescriptor2chance) and generatedescriptors == True): completeprompt += "-descriptor- " - if(subjectchooser in ["animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, subjectbodytypechance) and generatebodytype == True): + if(subjectchooser in ["animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation","firstname"] and chance_roll(insanitylevel, subjectbodytypechance) and generatebodytype == True): completeprompt += "-bodytype- " - if(subjectchooser in ["object","animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, subjectculturechance) and generatedescriptors == True): + if(subjectchooser in ["object","animal as human,","human", "job", "fictional", "non fictional", "humanoid", "manwomanrelation","firstname"] and chance_roll(insanitylevel, subjectculturechance) and generatedescriptors == True): completeprompt += "-culture- " if(mainchooser == "object"): @@ -1344,6 +1354,21 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all completeprompt += ":" + random.choice(hybridhumanlist) + ":" + str(random.randint(1,5)) + "] " hybridorswap = "" + if(subjectchooser == "firstname"): + if rare_dist(insanitylevel): + hybridorswaplist = ["hybrid", "swap"] + hybridorswap = random.choice(hybridorswaplist) + completeprompt += "[" + + completeprompt += "-firstname- " + + if(hybridorswap == "hybrid"): + completeprompt += "|" + "-firstname-" + "] " + if(hybridorswap == "swap"): + completeprompt += ":" + "-firstname-" + ":" + str(random.randint(1,5)) + "] " + hybridorswap = "" + + else: completeprompt += " " + givensubject + " " @@ -1412,7 +1437,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # riding an animal, holding an object or driving a vehicle, rare - if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, humanadditionchance) and generatehumanaddition == True): + if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation","firstname"] and chance_roll(insanitylevel, humanadditionchance) and generatehumanaddition == True): humanspecial = 1 completeprompt += "-humanaddition- " @@ -1428,7 +1453,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # SD understands emoji's. Can be used to manipulate facial expressions. # emoji, legendary - if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, emojichance) and generateemoji== True): + if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation","firstname"] and chance_roll(insanitylevel, emojichance) and generateemoji== True): completeprompt += "-emoji-, " @@ -1439,7 +1464,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all # Job # either go job or activity, not both - if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, joboractivitychance) and humanspecial != 1 and generatesubject == True): + if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation","firstname"] and chance_roll(insanitylevel, joboractivitychance) and humanspecial != 1 and generatesubject == True): joboractivitylist = [joblist,humanactivitylist] completeprompt += random.choice(random.choice(joboractivitylist)) + ", " @@ -1458,16 +1483,16 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all completeprompt += " -minivomit-, " # outfit builder - if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, outfitchance) and generateoutfit == True and humanspecial != 1): + if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation", "firstname"] and chance_roll(insanitylevel, outfitchance) and generateoutfit == True and humanspecial != 1): completeprompt += ", wearing " + random.choice(buildoutfitlist) + ", " - if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, posechance) and humanspecial != 1 and generatepose == True): + if(subjectchooser in ["animal as human","human","fictional", "non fictional", "humanoid", "manwomanrelation", "firstname"] and chance_roll(insanitylevel, posechance) and humanspecial != 1 and generatepose == True): completeprompt += random.choice(poselist) + ", " - if(subjectchooser in ["human","job","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, hairchance) and generatehairstyle == True): + if(subjectchooser in ["human","job","fictional", "non fictional", "humanoid", "manwomanrelation", "firstname"] and chance_roll(insanitylevel, hairchance) and generatehairstyle == True): completeprompt += random.choice(buildhairlist) + ", " - if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation"] and chance_roll(insanitylevel, accessorychance) and generateaccessorie == True and generateaccessories == True): + if(subjectchooser in ["animal as human,","human","fictional", "non fictional", "humanoid", "manwomanrelation", "firstname"] and chance_roll(insanitylevel, accessorychance) and generateaccessorie == True and generateaccessories == True): completeprompt += random.choice(buildaccessorielist) + ", " if(chance_roll(insanitylevel, humanoidinsideshotchance) and subjectchooser not in ["landscape", "concept"] and generateinsideshot == True): @@ -1871,9 +1896,10 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all "-styletilora-" in completeprompt or "-manwomanrelation-" in completeprompt or "-waterlocation-" in completeprompt or - "-container-" in completeprompt): - allwildcardslistnohybrid = [ "-color-","-object-", "-animal-", "-fictional-","-nonfictional-","-building-","-vehicle-","-location-","-conceptprefix-","-food-","-haircolor-","-hairstyle-","-job-", "-accessory-", "-humanoid-", "-manwoman-", "-human-", "-colorscheme-", "-mood-", "-genderdescription-", "-artmovement-", "-malefemale-", "-bodytype-", "-minilocation-", "-minilocationaddition-", "-pose-", "-season-", "-minioutfit-", "-elaborateoutfit-", "-minivomit-", "-vomit-", "-rpgclass-", "-subjectfromfile-", "-brand-", "-space-", "-artist-", "-imagetype-", "-othertype-", "-quality-", "-lighting-", "-camera-", "-lens-","-imagetypequality-", "-poemline-", "-songline-", "-greatwork-", "-artistfantasy-", "-artistpopular-", "-artistromanticism-", "-artistphotography-", "-emoji-", "-timeperiod-", "-shotsize-", "-musicgenre-", "-animaladdition-", "-addontolocationinside-", "-addontolocation-", "-objectaddition-", "-humanaddition-", "-overalladdition-", "-focus-", "-direction-", "-styletilora-", "-manwomanrelation-", "-waterlocation-", "-container-"] - allwildcardslistnohybridlists = [colorlist, objectlist, animallist, fictionallist, nonfictionallist, buildinglist, vehiclelist, locationlist,conceptprefixlist,foodlist,haircolorlist, hairstylelist,joblist, accessorielist, humanoidlist, manwomanlist, humanlist, colorschemelist, moodlist, genderdescriptionlist, artmovementlist, malefemalelist, bodytypelist, minilocationlist, minilocationadditionslist, poselist, seasonlist, minioutfitlist, elaborateoutfitlist, minivomitlist, vomitlist, rpgclasslist, customsubjectslist, brandlist, spacelist, artistlist, imagetypelist, othertypelist, qualitylist, lightinglist, cameralist, lenslist, imagetypequalitylist, poemlinelist, songlinelist, greatworklist, fantasyartistlist, popularartistlist, romanticismartistlist, photographyartistlist, emojilist, timeperiodlist, shotsizelist, musicgenrelist, animaladditionlist, addontolocationinsidelist, addontolocationlist, objectadditionslist, humanadditionlist, overalladditionlist, focuslist, directionlist, stylestiloralist, manwomanrelationlist, waterlocationlist, containerlist] + "-container-" in completeprompt or + "-firstname-" in completeprompt): + allwildcardslistnohybrid = [ "-color-","-object-", "-animal-", "-fictional-","-nonfictional-","-building-","-vehicle-","-location-","-conceptprefix-","-food-","-haircolor-","-hairstyle-","-job-", "-accessory-", "-humanoid-", "-manwoman-", "-human-", "-colorscheme-", "-mood-", "-genderdescription-", "-artmovement-", "-malefemale-", "-bodytype-", "-minilocation-", "-minilocationaddition-", "-pose-", "-season-", "-minioutfit-", "-elaborateoutfit-", "-minivomit-", "-vomit-", "-rpgclass-", "-subjectfromfile-", "-brand-", "-space-", "-artist-", "-imagetype-", "-othertype-", "-quality-", "-lighting-", "-camera-", "-lens-","-imagetypequality-", "-poemline-", "-songline-", "-greatwork-", "-artistfantasy-", "-artistpopular-", "-artistromanticism-", "-artistphotography-", "-emoji-", "-timeperiod-", "-shotsize-", "-musicgenre-", "-animaladdition-", "-addontolocationinside-", "-addontolocation-", "-objectaddition-", "-humanaddition-", "-overalladdition-", "-focus-", "-direction-", "-styletilora-", "-manwomanrelation-", "-waterlocation-", "-container-", "-firstname-"] + allwildcardslistnohybridlists = [colorlist, objectlist, animallist, fictionallist, nonfictionallist, buildinglist, vehiclelist, locationlist,conceptprefixlist,foodlist,haircolorlist, hairstylelist,joblist, accessorielist, humanoidlist, manwomanlist, humanlist, colorschemelist, moodlist, genderdescriptionlist, artmovementlist, malefemalelist, bodytypelist, minilocationlist, minilocationadditionslist, poselist, seasonlist, minioutfitlist, elaborateoutfitlist, minivomitlist, vomitlist, rpgclasslist, customsubjectslist, brandlist, spacelist, artistlist, imagetypelist, othertypelist, qualitylist, lightinglist, cameralist, lenslist, imagetypequalitylist, poemlinelist, songlinelist, greatworklist, fantasyartistlist, popularartistlist, romanticismartistlist, photographyartistlist, emojilist, timeperiodlist, shotsizelist, musicgenrelist, animaladditionlist, addontolocationinsidelist, addontolocationlist, objectadditionslist, humanadditionlist, overalladditionlist, focuslist, directionlist, stylestiloralist, manwomanrelationlist, waterlocationlist, containerlist, firstnamelist] allwildcardslistwithhybrid = ["-material-", "-descriptor-", "-outfit-", "-conceptsuffix-","-culture-", "-objecttotal-"] allwildcardslistwithhybridlists = [materiallist, descriptorlist,outfitlist,conceptsuffixlist,culturelist, objecttotallist] diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index a308b13..3ccc7d8 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -19,6 +19,7 @@ subject_fictional;on subject_nonfictional;on subject_humanoid;on subject_job;on +subject_firstnames;on # landscape; subject_landscape;on # concept; diff --git a/csvfiles/cultures.csv b/csvfiles/cultures.csv index 0fa6488..d8f7286 100644 --- a/csvfiles/cultures.csv +++ b/csvfiles/cultures.csv @@ -199,7 +199,6 @@ Papuan Mennonite Basque Hmong -Basque Catalan Bavarian Swiss diff --git a/csvfiles/firstnames.csv b/csvfiles/firstnames.csv new file mode 100644 index 0000000..21dc518 --- /dev/null +++ b/csvfiles/firstnames.csv @@ -0,0 +1,1596 @@ +firstname;gender +AIrjen;god +Aarav;male +Abdel;male +Abdi;male +Abdul;male +Abdullah;male +Achille;male +Adam;male +Ádám;male +Adama;male +Adi;male +Adil;male +Adrian;male +Agus;male +Ahmad;male +Ahmed;male +Ahmet;male +Ahsan;male +Aidan;male +Aisea;male +Akihiko;male +Akira;male +Alain;male +Alejandro;male +Aleksandar;male +Aleksandr;male +Alem;male +Alessandro;male +Alexander;male +Alexandre;male +Alexandros;male +Alexandru;male +Ali;male +Aliaksandr;male +Aliaksei;male +Alik;male +Alioune;male +Amadou;male +Ambrose;male +Amer;male +Amin;male +Amir;male +Amr;male +An;male +Andre;male +André;male +Andrea;male +Andreas;male +Andrei;male +Andrej;male +Andrés;male +Andriy;male +Angus;male +Anil;male +Anis;male +Ante;male +Antoine;male +Antonio;male +Antonis;male +Antonius;male +Anupong;male +Arash;male +Arben;male +Ariel;male +Arjun;male +Arjuna;male +Armand;male +Arturo;male +Asad;male +Ashwin;male +Augustus;male +Avraham;male +Awad;male +Babacar;male +Baptiste;male +Basil;male +Bence;male +Benjamin;male +Benjamín;male +Binh;male +Binod;male +Blerim;male +Bongani;male +Boonma;male +Boris;male +Bram;male +Brian;male +Bruno;male +Budi;male +Burak;male +Caleb;male +Callum;male +Calvin;male +Carlo;male +Carlos;male +Cem;male +Chamara;male +Chanwit;male +Charbel;male +Chatchai;male +Cheick;male +Cheikh;male +Chen;male +Chen Wei;male +Cheng;male +Cheuk;male +Chih-Hao;male +Chinedu;male +Chinnawat;male +Christian;male +Christopher;male +Christos;male +Chun;male +Cillian;male +Claude;male +Collins;male +Connor;male +Constantine;male +Cooper;male +Cristóbal;male +Daan;male +Daichi;male +Daiki;male +Damian;male +Damien;male +Daniel;male +Darius;male +Darko;male +David;male +Dávid;male +Davide;male +Dawit;male +Decimus;male +Declan;male +Dedi;male +Dejan;male +Dennis;male +Dev;male +Diego;male +Dieudonné;male +Dilshan;male +Dimitar;male +Dimitrios;male +Dinesh;male +Dmitri;male +Dmitry;male +Dmytro;male +Dominic;male +Donovan;male +Dritan;male +Duc;male +Dylan;male +Dženan;male +Dzmitry;male +Edey;male +Edgar;male +Eduardo;male +Eiji;male +Eitan;male +Elias;male +Elijah;male +Emeka;male +Émile;male +Emir;male +Emmanuel;male +Emre;male +Eric;male +Erik;male +Ernst;male +Ethan;male +Étienne;male +Evan;male +Ewan;male +Fa'afetai;male +Fadi;male +Faisal;male +Faizal;male +Farah;male +Farhad;male +Farhan;male +Farid;male +Faruk;male +Fathi;male +Felipe;male +Felix;male +Feng;male +Finlay;male +Finn;male +Florian;male +Florin;male +Floris;male +Francesco;male +Francis;male +Francisco;male +François;male +Gabriel;male +Gaius;male +Gareth;male +Gentian;male +Georges;male +Georgi;male +Georgios;male +Gergő;male +Gilbert;male +Giovanni;male +Giuseppe;male +Goran;male +Govinda;male +Gunnar;male +Guo;male +Gustave;male +Habtamu;male +Hafiz;male +Hailu;male +Hamid;male +Hamish;male +Hamza;male +Hani;male +Hannes;male +Harald;male +Haris;male +Harrison;male +Haruki;male +Haruto;male +Hasan;male +Hassan;male +Hassen;male +Hector;male +Hendra;male +Henri;male +Henrik;male +Henry;male +Hideki;male +Hieu;male +Hiroshi;male +Hisham;male +Ho;male +Huang;male +Hugo;male +Hussein;male +Huw;male +Hyun-woo;male +Ibrahim;male +Ibrahima;male +Ieuan;male +Ifan;male +Ignacio;male +Igor;male +Ikerior;male +Ilaisa;male +Ilir;male +Imran;male +Innocent;male +Ioannis;male +Ion;male +Iosefa;male +Iram;male +Isaac;male +Isamu;male +Iskandar;male +István;male +Itay;male +Ivan;male +Jabulani;male +Jack;male +Jakub;male +Jamal;male +James;male +Jan;male +Ján;male +Jasmin;male +Jason;male +Javier;male +Jean;male +Jean-Claude;male +Jean-Paul;male +Jelani;male +Jerome;male +Ji-hoon;male +Ji-hyeon;male +Ji-hyun;male +Jia Hui;male +Jian;male +Jiang;male +Jirayu;male +John;male +Joko;male +Jonathan;male +Jone;male +Joon-ho;male +José;male +Josef;male +Joseph;male +Joshua;male +Josip;male +Juan;male +Jules;male +Julian;male +Julius;male +Juma;male +Jun;male +Junichi;male +Justinian;male +Kabuo;male +Kacper;male +Kai;male +Kai Jie;male +Kaito;male +Kamal;male +Kameli;male +Kamran;male +Kapila;male +Kareem;male +Karim;male +Kazuki;male +Kazuo;male +Kebekl;male +Kendrick;male +Kenji;male +Kenjiro;male +Kevin;male +Kgosi;male +Khairul;male +Khaled;male +Khalid;male +Khoa;male +Kiril;male +Koffi;male +Kofi;male +Koji;male +Kota;male +Krishna;male +Krit;male +Kwame;male +Lachlan;male +Lars;male +Leif;male +Lekinio;male +Leo;male +Leonardo;male +Levente;male +Levi;male +Li;male +Lial;male +Liam;male +Liang;male +Likin;male +Lin;male +Liu;male +Long;male +Lorenzo;male +Louis;male +Luan;male +Luca;male +Lucas;male +Lucian;male +Lucius;male +Ludwig;male +Luis;male +Luka;male +Lukáš;male +Łukasz;male +Mackerel;male +Magnus;male +Mahfuz;male +Mahinda;male +Mahmoud;male +Malakai;male +Malcolm;male +Malik;male +Mamadou;male +Man;male +Mandla;male +Manu;male +Manuel;male +Marcel;male +Marcello;male +Marcelo;male +Marco;male +Marcos;male +Marcus;male +Marián;male +Mario;male +Marius;male +Marko;male +Martin;male +Martín;male +Masaru;male +Masashi;male +Mason;male +Matagi;male +Máté;male +Matej;male +Mateusz;male +Mathieu;male +Matías;male +Matthew;male +Matthias;male +Max;male +Maxim;male +Maximilian;male +Maximus;male +Mees;male +Mehdi;male +Mehmet;male +Mehran;male +Mejit;male +Melekeok;male +Michael;male +Michal;male +Michał;male +Michel;male +Miguel;male +Mika;male +Mikalai;male +Mikhail;male +Milan;male +Min-ho;male +Min-joon;male +Ming;male +Ming Wei;male +Ming-Hui;male +Minh;male +Mirza;male +Modibo;male +Mohamed;male +Mohammad;male +Mohammed;male +Mohd;male +Mortimer;male +Mosese;male +Moshe;male +Mostafa;male +Moussa;male +Mpho;male +Murat;male +Murray;male +Musa;male +Mustafa;male +Mykhailo;male +Nabil;male +Nadav;male +Nalin;male +Nam;male +Naoki;male +Narong;male +Nasir;male +Nasser;male +Nassim;male +Nathan;male +Natnael;male +Nattapong;male +Navid;male +Neimo;male +Nemo;male +Nenad;male +Nermin;male +Ngerulmud;male +Niall;male +Nicolae;male +Nicolas;male +Niels;male +Nigel;male +Nikola;male +Nikolai;male +Nikolaos;male +Nikolay;male +Nima;male +Niroshan;male +Nizar;male +Noah;male +Noboru;male +Octavius;male +Odin;male +Olaf;male +Olamide;male +Oleg;male +Oleksandr;male +Olis;male +Oliver;male +Olivier;male +Ollei;male +Oluwaseun;male +Omar;male +Oscar;male +Oskar;male +Osman;male +Othman;male +Oumar;male +Ousmane;male +Owain;male +Owen;male +Pak;male +Pakorn;male +Panagiotis;male +Pascal;male +Patrick;male +Paul;male +Paulo;male +Pavel;male +Pavlo;male +Paweł;male +Pekoi;male +Petar;male +Peter;male +Péter;male +Petr;male +Philippe;male +Pierre;male +Pieter;male +Pietro;male +Piyus;male +Pongpol;male +Pradeep;male +Prakash;male +Pranav;male +Prasit;male +Qiang;male +Quang;male +Quintus;male +Rachid;male +Radu;male +Raed;male +Rafael;male +Raffaele;male +Rafiq;male +Ragnar;male +Rahul;male +Raj;male +Rajen;male +Rajesh;male +Ramesh;male +Rami;male +Rashid;male +Ratu;male +Ravi;male +Rémi;male +Ren;male +René;male +Reza;male +Rhys;male +Ricardo;male +Richard;male +Ridel;male +Riley;male +Rilometo;male +Rizal;male +Robert;male +Roberto;male +Roger;male +Roland;male +Roman;male +Rory;male +Ross;male +Rudi;male +Ryan;male +Ryo;male +Ryoichi;male +Ryota;male +Saad;male +Said;male +Saiful;male +Saleh;male +Samba;male +Sami;male +Samir;male +Samuel;male +Sanjay;male +Sanjeeva;male +Satoshi;male +Scott;male +Sean;male +Sebastian;male +Sebastián;male +Semere;male +Semisi;male +Semwen;male +Seo-jin;male +Seo-joon;male +Serge;male +Sergei;male +Sergio;male +Serhiy;male +Serkan;male +Shahid;male +Shahram;male +Shinichi;male +Shinji;male +Shinjiro;male +Shiro;male +Shota;male +Shpetim;male +Siarhei;male +Sigurd;male +Simon;male +Sing;male +Sione;male +Sipho;male +Sizwe;male +Slamet;male +Slobodan;male +Sofiane;male +Sokol;male +Sombat;male +Somchai;male +Sora;male +Souleymane;male +Spyridon;male +Stefan;male +Stefano;male +Steffan;male +Stephen;male +Stjepan;male +Stojan;male +Stoyan;male +Stuart;male +Surangel;male +Suresh;male +Surin;male +Surya;male +Suthep;male +Sven;male +Syafiq;male +Szymon;male +Tak;male +Takashi;male +Takumi;male +Tama;male +Tamás;male +Taniela;male +Tao;male +Taras;male +Tarek;male +Tarik;male +Tariq;male +Taro;male +Tatsuya;male +Taua;male +Tawee;male +Temol;male +Terrence;male +Thabo;male +Themba;male +Theodore;male +Theodosius;male +Thiago;male +Thierry;male +Thijs;male +Thomas;male +Thor;male +Tiago;male +Titus;male +Tobias;male +Tobolar;male +Todor;male +Tomáš;male +Tomasi;male +Tomasz;male +Tomislav;male +Tomos;male +Toshio;male +Toshiro;male +Trevor;male +Tuan;male +Uche;male +Uladzimir;male +Ulf;male +Václav;male +Vadim;male +Valentin;male +Valerius;male +Valon;male +Vančo;male +Vasil;male +Vasyl;male +Victor;male +Viggo;male +Vikram;male +Viktor;male +Viliame;male +Viliamu;male +Vincent;male +Vincenzo;male +Vladimir;male +Wahyu;male +Wai;male +Wakna;male +Walid;male +Walter;male +Wang;male +Warit;male +Wei;male +Wei Jie;male +Wen-Hao;male +Wilhelm;male +William;male +Winston;male +Wisit;male +Wojciech;male +Woo-jin;male +Wouter;male +Xandii;male +Xavier;male +Xhevat;male +Xian;male +Xiang;male +Xing;male +Xu;male +Yahor;male +Yair;male +Yang;male +Yasushi;male +Yau;male +Yauheni;male +Yaw;male +Yaya;male +Yevgeny;male +Yew Meng;male +Yonas;male +Yordan;male +Yosef;male +Yoshihiro;male +Yoshio;male +Youssef;male +Youssou;male +Youssouf;male +Yu;male +Yu-Hsuan;male +Yuji;male +Yuki;male +Yukihiro;male +Yuriy;male +Yusuf;male +Yusuke;male +Yuta;male +Yutaka;male +Yuto;male +Yuttana;male +Yves;male +Zachary;male +Zahid;male +Zahir;male +Zaid;male +Zainal;male +Zakaria;male +Zayd;male +Zayn;male +Zedeki;male +Zenjiro;male +Zerihun;male +Zhang;male +Zhi Hao;male +Zhi-Yuan;male +Zhou;male +Zoltán;male +Zoran;male +Zuberi;male +Zulkifli;male +Zweli;male +Aaliyah;female +Aarti;female +Abena;female +Abigail;female +Achara;female +Adaeze;female +Adama;female +Adi;female +Adriana;female +Adwoa;female +Agnes;female +Ágnes;female +Aida;female +Aiko;female +Aileen;female +Aisha;female +Aishwarya;female +Aisling;female +Aissatou;female +Aiyana;female +Ajurin;female +Akari;female +Akemi;female +Akinyi;female +Akosua;female +Akua;female +Alaima;female +Alba;female +Albana;female +Alejandra;female +Aleksandra;female +Alena;female +Alessia;female +Alexandra;female +Alice;female +Alina;female +Aline;female +Alma;female +Alofa;female +Altantsetseg;female +Ama;female +Amaia;female +Amal;female +Amanda;female +Amani;female +Amara;female +Amelia;female +Amina;female +Aminata;female +Amira;female +Amma;female +Amna;female +Amra;female +Ana;female +Anaïs;female +Anastasia;female +Anastasiya;female +Andrea;female +Andreea;female +Ane;female +Angelica;female +Anh;female +Ani;female +Anika;female +Anjali;female +Anna;female +Anni;female +Anong;female +Antonia;female +Anwen;female +Anyango;female +Aoi;female +Aoibhinn;female +Aoife;female +Arisa;female +Arooj;female +Asha;female +Asma;female +Astou;female +Astrid;female +Athena;female +Aurelia;female +Aurora;female +Ava;female +Aya;female +Ayako;female +Ayan;female +Ayanda;female +Ayesha;female +Ayşe;female +Aysel;female +Ayu;female +Ayumi;female +Azadeh;female +Azar;female +Aziza;female +Azra;female +Bakuii;female +Barbora;female +Bayarmaa;female +Beatriz;female +Bells;female +Bertha;female +Bina;female +Brigid;female +Bronwyn;female +Buhle;female +Busisiwe;female +Caitriona;female +Camila;female +Camille;female +Caoimhe;female +Carla;female +Carlotta;female +Carmen;female +Carolina;female +Carys;female +Catalina;female +Caterina;female +Catherine;female +Catrin;female +Celeste;female +Celia;female +Celine;female +Cerys;female +Charlotte;female +Charmaine;female +Cheryl;female +Chia-Hui;female +Chia-Ying;female +Chiara;female +Chidinma;female +Ching-Yi;female +Chioma;female +Chiyo;female +Chizuru;female +Chloé;female +Choekyi;female +Christine;female +Chun;female +Ciara;female +Citlali;female +Citra;female +Clara;female +Clarisse;female +Claudia;female +Coatl;female +Cornelia;female +Coumba;female +Cynthia;female +Dalia;female +Daniela;female +Daria;female +Darya;female +Deepika;female +Delau;female +Despina;female +Dewi;female +Diana;female +Dilhani;female +Dimitra;female +Djeneba;female +Dolma;female +Dominika;female +Dóra;female +Dragana;female +Eden;female +Efua;female +Eiko;female +Eileen;female +Eilidh;female +Eimear;female +Eirene;female +Ekaterina;female +Elena;female +Eleni;female +Eleonora;female +Eliana;female +Elida;female +Elif;female +Elin;female +Elizabeth;female +Ella;female +Elma;female +Elona;female +Elsa;female +Ema;female +Emebet;female +Emese;female +Emi;female +Emiko;female +Emilia;female +Emily;female +Emine;female +Emma;female +Emmanuella;female +Enkhtuya;female +Eposi;female +Erika;female +Erza;female +Esi;female +Esmeralda;female +Esra;female +Estelle;female +Esther;female +Eszter;female +Eun-Ji;female +Eva;female +Evangeline;female +Evelyn;female +Fang;female +Farah;female +Fardowsa;female +Farhana;female +Farida;female +Fatemeh;female +Fatima;female +Fatma;female +Fatou;female +Fatoumata;female +Fatuma;female +Fernanda;female +Ffion;female +Fia;female +Fien;female +Fiona;female +Fitri;female +Flavia;female +Fleur;female +Florencia;female +Francesca;female +Francine;female +Franziska;female +Freya;female +Frida;female +Fusako;female +Gabriela;female +Gabriella;female +Galia;female +Gertrud;female +Gianna;female +Gita;female +Giulia;female +Gloria;female +Grace;female +Grainne;female +Greta;female +Gudrun;female +Gülay;female +Hae-Won;female +Hafsa;female +Hala;female +Halima;female +Hana;female +Hanna;female +Hannah;female +Harper;female +Haruka;female +Haruki;female +Haruko;female +Hawa;female +Heidi;female +Helena;female +Helene;female +Hilda;female +Hina;female +Hira;female +Hiroko;female +Hisako;female +Hiu;female +Houda;female +Hsiao-Ling;female +Hua;female +Huda;female +Hui;female +Huong;female +Ida;female +Idoia;female +Ifeoma;female +Ikureo;female +Imara;female +Inat;female +Indah;female +Ines;female +Inès;female +Inês;female +Ingrid;female +Inoni;female +Ioana;female +Irati;female +Irena;female +Irene;female +Irina;female +Isabella;female +Isidora;female +Isla;female +Itzel;female +Iva;female +Ivana;female +Iztaccíhuatl;female +Jahanara;female +Jana;female +Janelle;female +Janice;female +Jasmine;female +Javiera;female +Jeirok;female +Jelena;female +Jennifer;female +Jessica;female +Ji-Eun;female +Ji-Hye;female +Ji-Hyun;female +Ji-Yeon;female +Ji-Yeong;female +Jing;female +Joanna;female +Jolien;female +Josephine;female +Josiane;female +Julia;female +Júlia;female +Juliana;female +Julie;female +Kadiatou;female +Kala;female +Kalina;female +Kamala;female +Kanna;female +Kaoru;female +Karla;female +Karolina;female +Kata;female +Katarina;female +Katarína;female +Katarzyna;female +Katerina;female +Kateřina;female +Kateryna;female +Katharina;female +Katsiaryna;female +Kavisha;female +Kavita;female +Kaya;female +Kazuko;female +Keiko;female +Keira;female +Keisha;female +Kelsang;female +Kemi;female +Khadija;female +Khadijah;female +Khady;female +Khanyisile;female +Khulan;female +Kiara;female +Kimberly;female +Kinga;female +Kiyoko;female +Klara;female +Kristina;female +Kristína;female +Kunda;female +Kwamboka;female +Kyoko;female +Lai;female +Laia;female +Laila;female +Laisa;female +Lama;female +Lamia;female +Lamija;female +Lan;female +Lana;female +Lanora;female +Lara;female +Larissa;female +Latoya;female +Laura;female +Lavinia;female +Layla;female +Lea;female +Léa;female +Leah;female +Leena;female +Lei;female +Leiko;female +Leila;female +Leilani;female +Leire;female +Lejla;female +Lemlem;female +Lena;female +Leonie;female +Leonor;female +Lerato;female +Lethabo;female +Lhamo;female +Li;female +Li Wei;female +Lieke;female +Likiak;female +Likiep;female +Lila;female +Liliya;female +Lillian;female +Lily;female +Lin;female +Lina;female +Ling;female +Linh;female +Linnea;female +Liora;female +Liridona;female +Lisa;female +Litiana;female +Livia;female +Liya;female +Losalini;female +Lotte;female +Louise;female +Lowri;female +Lucia;female +Lucía;female +Lucie;female +Lucy;female +Luisa;female +Luljeta;female +Lulu;female +Luluk;female +Lwandle;female +Lydia;female +Maddi;female +Maeve;female +Mafalda;female +Magdalena;female +Mahira;female +Mahlet;female +Mai;female +Mairi;female +Maite;female +Maja;female +Makeda;female +Makereta;female +Mala;female +Malaika;female +Malak;female +Malani;female +Malia;female +Malsol;female +Mami;female +Mandukhai;female +Manel;female +Manka;female +Manon;female +Manuela;female +Marcella;female +Maria;female +María;female +Mariam;female +Mariama;female +Mariana;female +Marianne;female +Marie;female +Mariem;female +Marija;female +Marina;female +Markéta;female +Marta;female +Martha;female +Martina;female +Mary;female +Maryam;female +Masako;female +Mathilda;female +Mathilde;female +Matilde;female +Maya;female +Mayahuel;female +Mbali;female +Mballa;female +Mboma;female +Medina;female +Meera;female +Megan;female +Megumi;female +Mei;female +Mei Ling;female +Mei-Ling;female +Mejrak;female +Mekeya;female +Mele;female +Melia;female +Melissa;female +Mere;female +Mereoni;female +Mi-Young;female +Mia;female +Michaela;female +Michelle;female +Mihaela;female +Mila;female +Milena;female +Milica;female +Min-Ji;female +Ming;female +Mira;female +Miriam;female +Mirna;female +Misako;female +Mitsuko;female +Moira;female +Monique;female +Moran;female +Muhorakeye;female +Mukamana;female +Mukeshimana;female +Mutesi;female +Mwanaidi;female +Nada;female +Nadege;female +Nadia;female +Nafi;female +Nafisa;female +Nakalembe;female +Nakato;female +Nakawunde;female +Nala;female +Nalwadda;female +Namatovu;female +Namazzi;female +Nambi;female +Namgyal;female +Namutebi;female +Nana;female +Nanami;female +Nandi;female +Nannake;female +Nao;female +Naomi;female +Narantsetseg;female +Naree;female +Naresuan;female +Nari;female +Nasira;female +Nasra;female +Nassali;female +Natalia;female +Natallia;female +Natasa;female +Nathalie;female +Natsumi;female +Natthida;female +Nazanin;female +Ndella;female +Ndèye;female +Neda;female +Neema;female +Neha;female +Nene;female +Nenem;female +Nerea;female +Ngaruen;female +Ngeremes;female +Ngoc;female +Ngozi;female +Nia;female +Niamh;female +Nikolina;female +Nima;female +Nina;female +Nisha;female +Njeri;female +Noa;female +Nobuko;female +Noluthando;female +Nomvula;female +Nongnuch;female +Noor;female +Nora;female +Norazila;female +Noriko;female +Norma;female +Nour;female +Noura;female +Ntombi;female +Nuria;female +Nurul;female +Nusrat;female +Nyakio;female +Nyambura;female +Nyiramana;female +Nyota;female +Octavia;female +Odval;female +Oihana;female +Olena;female +Olga;female +Olivia;female +Orlaith;female +Orly;female +Ottilie;female +Oumou;female +Oyunbileg;female +Parisa;female +Patcharapimol;female +Pearl;female +Pei-Chen;female +Pema;female +Petra;female +Polina;female +Pooja;female +Prisca;female +Priya;female +Putri;female +Raarik;female +Rabia;female +Rachel;female +Radha;female +Rana;female +Rani;female +Rania;female +Rebecca;female +Rehema;female +Rekha;female +Renata;female +Rhiannon;female +Ria;female +Rika;female +Rima;female +Rina;female +Riona;female +Rita;female +Rokhaya;female +Roksana;female +Romany;female +Romina;female +Rosalia;female +Rose;female +Roxana;female +Ruby;female +Ruma;female +Runa;female +Ruqaya;female +Ruth;female +Saba;female +Sabina;female +Sachiko;female +Safa;female +Saffron;female +Safia;female +Saga;female +Sahar;female +Sahra;female +Sainimili;female +Saioa;female +Sakura;female +Salima;female +Salma;female +Salote;female +Samantha;female +Samanthi;female +Samar;female +Samara;female +Samia;female +Samira;female +Sana;female +Sanaa;female +Sandra;female +Sanduni;female +Sanja;female +Saoirse;female +Sara;female +Sarah;female +Sarangerel;female +Sari;female +Sarita;female +Sarnai;female +Sasi;female +Sekreteri;female +Selam;female +Selina;female +Selma;female +Seren;female +Serena;female +Sevgi;female +Shahad;female +Shahrzad;female +Shanice;female +Shaniqua;female +Shantelle;female +Shila;female +Shira;female +Shqipe;female +Shreya;female +Sibongile;female +Signe;female +Sigrid;female +Simona;female +Simone;female +Sina;female +Siobhan;female +Sirikit;female +Sita;female +Siti;female +Sofia;female +Sofía;female +Sofie;female +Sokhna;female +Solange;female +Solveig;female +Soo-Min;female +Sophia;female +Sophie;female +Sora;female +Stephanie;female +Subhashini;female +Sumaya;female +Supalak;female +Suri;female +Susanna;female +Suvannarat;female +Svetlana;female +Sviatlana;female +Syafiqah;female +Sze;female +Takeko;female +Talane;female +Talia;female +Tamar;female +Tamara;female +Tansinee;female +Tasha;female +Tashi;female +Tasi;female +Tatiana;female +Tema;female +Tenzin;female +Teresia;female +Tereza;female +Tessa;female +Teuila;female +Teuta;female +Thandiwe;female +Thao;female +Tharika;female +Theodora;female +Theresa;female +Thu;female +Thuy;female +Thyra;female +Tia;female +Tlalli;female +Tlazoltéotl;female +Tlongel;female +Tmetuchl;female +Tomiko;female +Tomoko;female +Tomomi;female +Trang;female +Tsion;female +Tsomo;female +Uila;female +Umutoni;female +Uwase;female +Uwimana;female +Valentina;female +Valeria;female +Valerie;female +Vasiti;female +Veronika;female +Victoria;female +Viktoria;female +Viktória;female +Viktorija;female +Viktoriya;female +Viktoryia;female +Vitória;female +Vivian;female +Vjollca;female +Wai;female +Wan-Chen;female +Wangari;female +Wanjiru;female +Waranya;female +Wei;female +Wing;female +Wulan;female +Xhuliana;female +Xiao;female +Xin;female +Xitlali;female +Xiu;female +Xiuhtecuhtli;female +Xochitl;female +Ya-Ting;female +Yaa;female +Yangchen;female +Yao;female +Yaritza;female +Yasmin;female +Yasuko;female +Yee;female +Yelena;female +Ying;female +Yoko;female +Yoshiko;female +Yu;female +Yu-Hsuan;female +Yu-Ju;female +Yuen;female +Yui;female +Yuka;female +Yukiko;female +Yuko;female +Yulia;female +Yuliya;female +Yumi;female +Yuna;female +Yupin;female +Yvette;female +Zahra;female +Zainab;female +Zainabu;female +Zara;female +Zeina;female +Zeynep;female +Zinhle;female +Zoe;female +Zoé;female +Zola;female +Zsófia;female +Zulaikha;female +Zuri;female +Zuwena;female +Zuzana;female \ No newline at end of file diff --git a/csvfiles/nature.csv b/csvfiles/nature.csv new file mode 100644 index 0000000..3582bc6 --- /dev/null +++ b/csvfiles/nature.csv @@ -0,0 +1,81 @@ +Tree +Bush +Flower +Oak tree +Maple tree +Pine tree +Apple tree +Cherry blossom tree +Redwood tree +Birch tree +Willow tree +Palm tree +Magnolia tree +Roses +Sunflowers +Daisies +Tulips +Orchids +Lilies +Poppies +Hydrangeas +Irises +Marigolds +Leaf +Twig +Pinecone +Acorn +Moss +Seedling +Petal +Fern +Mushroom +Mossy rock +Beehive +Vine +Willow basket +Coral reef +Honeycomb +Wildflower bouquet +Cactus spines +Pebble +Bamboo shoot +Sunflower field +Pine needle carpet +River stone +Seashell +Autumn leaf pile +Seaweed +Pine bark +Butterfly cocoon +Dandelion fluff +Bird nest +Water lily pad +Herb garden +Wild berry bush +Tree stump +Coral reef +Wild mushroom patch +Tulip bulb +Oak tree branch +Hummingbird feeder +Pond water lilies +Straw bale +Bouquet +Forest +Meadow +Garden +-waterlocation- +Rainforest +Waterfall +Rock formation +Foliage +Wilderness +Biodiversity +Ecosystem +Flora +Fauna +Woodland +Arboretum +Orchard +Herb garden \ No newline at end of file diff --git a/csvfiles/objects.csv b/csvfiles/objects.csv index d95ca6f..9371150 100644 --- a/csvfiles/objects.csv +++ b/csvfiles/objects.csv @@ -281,26 +281,6 @@ Fractal Pentagram -conceptsuffix-potion Roast beef -Oak tree -Maple tree -Pine tree -Apple tree -Cherry blossom tree -Redwood tree -Birch tree -Willow tree -Palm tree -Magnolia tree -Roses -Sunflowers -Daisies -Tulips -Orchids -Lilies -Poppies -Hydrangeas -Irises -Marigolds -object- in a bottle Faberge egg Quilt diff --git a/prompttester.py b/prompttester.py index 3d6528d..c1ae999 100644 --- a/prompttester.py +++ b/prompttester.py @@ -46,4 +46,4 @@ def generateprompts(amount = 1,insanitylevel="5",subject="all", artist="all", im print("") print("All done!") -generateprompts(10,5,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100, "female", "all", "fictional characters", "all") \ No newline at end of file +generateprompts(10,5,"humanoid","all","all",False,"","","PREFIXPROMPT" ,"SUFFIXPROMPT","",1,"","",True,"",100, "female", "all", "all", "all") \ No newline at end of file diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index 4a2370b..cee92a8 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -87,6 +87,7 @@ generatefictionalcharacter = True generatenonfictionalcharacter = True generatehumanoids = True generatejob = True +generatefirstnames = True generatelandscape = True generateevent = True generateconcepts = True @@ -122,6 +123,8 @@ for item in config: generatehumanoids = False if item[0] == 'subject_job' and item[1] != 'on': generatejob = False + if item[0] == 'subject_firstnames' and item[1] != 'on': + generatefirstnames = False # landscape if item[0] == 'subject_landscape' and item[1] != 'on': generatelandscape = False @@ -178,6 +181,8 @@ if(generatehumanoids): subjectsubtypeshumanoid.append("humanoids") if(generatejob): subjectsubtypeshumanoid.append("based on job or title") +if(generatefirstnames): + subjectsubtypeshumanoid.append("based on first name") # concepts if(generateevent): From e0c50094ca78501c2f3eb4836a1e52d51a8ae777 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Sun, 9 Jul 2023 07:57:20 +0200 Subject: [PATCH 14/18] Adding in Flora --- build_dynamic_prompt.py | 23 +- csvfiles/config/default_config.csv | 1 + csvfiles/{nature.csv => flora.csv} | 204 +++++++++++------- csvfiles/special_lists/backgroundtypes.csv | 3 +- csvfiles/special_lists/humanadditions.csv | 2 + .../special_lists/minilocationadditions.csv | 3 +- csvfiles/special_lists/objectadditions.csv | 3 +- csvfiles/special_lists/overalladditions.csv | 5 +- csvfiles/waterlocations.csv | 5 +- scripts/onebuttonprompt.py | 5 + 10 files changed, 167 insertions(+), 87 deletions(-) rename csvfiles/{nature.csv => flora.csv} (50%) diff --git a/build_dynamic_prompt.py b/build_dynamic_prompt.py index 305f6c4..b277720 100644 --- a/build_dynamic_prompt.py +++ b/build_dynamic_prompt.py @@ -89,9 +89,10 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all waterlocationlist = csv_to_list("waterlocations", antilist) containerlist = csv_to_list("containers", antilist) firstnamelist = csv_to_list(csvfilename="firstnames",antilist=antilist,skipheader=True,gender=gender) + floralist = csv_to_list("flora", antilist) humanlist = fictionallist + nonfictionallist + humanoidlist - objecttotallist = objectlist + buildinglist + vehiclelist + foodlist + spacelist + objecttotallist = objectlist + buildinglist + vehiclelist + foodlist + spacelist + floralist # build artists list artistlist = [] @@ -157,6 +158,7 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all generatefood = True generatebuilding = True generatespace = True + generateflora = True generateanimal = True generatemanwoman = True generatemanwomanrelation = True @@ -256,6 +258,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all generatebuilding = False if item[0] == 'subject_space' and item[1] != 'on': generatespace = False + if item[0] == 'subject_flora' and item[1] != 'on': + generateflora = False # animals if item[0] == 'subject_animal' and item[1] != 'on': generateanimal = False @@ -427,7 +431,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all generatefood = bool(foodlist) and generatefood generatebuilding = bool(buildinglist) and generatebuilding generatespace = bool(spacelist) and generatespace - generateobject = generatevehicle or generateobject or generatefood or generatebuilding or generatespace + generateflora = bool(floralist) and generateflora + generateobject = generatevehicle or generateobject or generatefood or generatebuilding or generatespace or generateflora if(generatevehicle): @@ -454,6 +459,11 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all addontolocationlist.append("-building-") addontolocationinsidelist.append("-building-") + if(generateflora): + objectwildcardlist.append("-flora-") + hybridlist.append("-flora-") + addontolocationlist.append("-flora-") + if(generateobject): mainchooserlist.append("object") @@ -1233,6 +1243,8 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all objectwildcardlist = ["-building-"] if(subtypeobject == "space"): objectwildcardlist = ["-space-"] + if(subtypeobject == "flora"): + objectwildcardlist = ["-flora-"] # if we have a given subject, we should skip making an actual subject if(givensubject == ""): @@ -1897,9 +1909,10 @@ def build_dynamic_prompt(insanitylevel = 5, forcesubject = "all", artists = "all "-manwomanrelation-" in completeprompt or "-waterlocation-" in completeprompt or "-container-" in completeprompt or - "-firstname-" in completeprompt): - allwildcardslistnohybrid = [ "-color-","-object-", "-animal-", "-fictional-","-nonfictional-","-building-","-vehicle-","-location-","-conceptprefix-","-food-","-haircolor-","-hairstyle-","-job-", "-accessory-", "-humanoid-", "-manwoman-", "-human-", "-colorscheme-", "-mood-", "-genderdescription-", "-artmovement-", "-malefemale-", "-bodytype-", "-minilocation-", "-minilocationaddition-", "-pose-", "-season-", "-minioutfit-", "-elaborateoutfit-", "-minivomit-", "-vomit-", "-rpgclass-", "-subjectfromfile-", "-brand-", "-space-", "-artist-", "-imagetype-", "-othertype-", "-quality-", "-lighting-", "-camera-", "-lens-","-imagetypequality-", "-poemline-", "-songline-", "-greatwork-", "-artistfantasy-", "-artistpopular-", "-artistromanticism-", "-artistphotography-", "-emoji-", "-timeperiod-", "-shotsize-", "-musicgenre-", "-animaladdition-", "-addontolocationinside-", "-addontolocation-", "-objectaddition-", "-humanaddition-", "-overalladdition-", "-focus-", "-direction-", "-styletilora-", "-manwomanrelation-", "-waterlocation-", "-container-", "-firstname-"] - allwildcardslistnohybridlists = [colorlist, objectlist, animallist, fictionallist, nonfictionallist, buildinglist, vehiclelist, locationlist,conceptprefixlist,foodlist,haircolorlist, hairstylelist,joblist, accessorielist, humanoidlist, manwomanlist, humanlist, colorschemelist, moodlist, genderdescriptionlist, artmovementlist, malefemalelist, bodytypelist, minilocationlist, minilocationadditionslist, poselist, seasonlist, minioutfitlist, elaborateoutfitlist, minivomitlist, vomitlist, rpgclasslist, customsubjectslist, brandlist, spacelist, artistlist, imagetypelist, othertypelist, qualitylist, lightinglist, cameralist, lenslist, imagetypequalitylist, poemlinelist, songlinelist, greatworklist, fantasyartistlist, popularartistlist, romanticismartistlist, photographyartistlist, emojilist, timeperiodlist, shotsizelist, musicgenrelist, animaladditionlist, addontolocationinsidelist, addontolocationlist, objectadditionslist, humanadditionlist, overalladditionlist, focuslist, directionlist, stylestiloralist, manwomanrelationlist, waterlocationlist, containerlist, firstnamelist] + "-firstname-" in completeprompt or + "-flora-" in completeprompt): + allwildcardslistnohybrid = [ "-color-","-object-", "-animal-", "-fictional-","-nonfictional-","-building-","-vehicle-","-location-","-conceptprefix-","-food-","-haircolor-","-hairstyle-","-job-", "-accessory-", "-humanoid-", "-manwoman-", "-human-", "-colorscheme-", "-mood-", "-genderdescription-", "-artmovement-", "-malefemale-", "-bodytype-", "-minilocation-", "-minilocationaddition-", "-pose-", "-season-", "-minioutfit-", "-elaborateoutfit-", "-minivomit-", "-vomit-", "-rpgclass-", "-subjectfromfile-", "-brand-", "-space-", "-artist-", "-imagetype-", "-othertype-", "-quality-", "-lighting-", "-camera-", "-lens-","-imagetypequality-", "-poemline-", "-songline-", "-greatwork-", "-artistfantasy-", "-artistpopular-", "-artistromanticism-", "-artistphotography-", "-emoji-", "-timeperiod-", "-shotsize-", "-musicgenre-", "-animaladdition-", "-addontolocationinside-", "-addontolocation-", "-objectaddition-", "-humanaddition-", "-overalladdition-", "-focus-", "-direction-", "-styletilora-", "-manwomanrelation-", "-waterlocation-", "-container-", "-firstname-", "-flora-"] + allwildcardslistnohybridlists = [colorlist, objectlist, animallist, fictionallist, nonfictionallist, buildinglist, vehiclelist, locationlist,conceptprefixlist,foodlist,haircolorlist, hairstylelist,joblist, accessorielist, humanoidlist, manwomanlist, humanlist, colorschemelist, moodlist, genderdescriptionlist, artmovementlist, malefemalelist, bodytypelist, minilocationlist, minilocationadditionslist, poselist, seasonlist, minioutfitlist, elaborateoutfitlist, minivomitlist, vomitlist, rpgclasslist, customsubjectslist, brandlist, spacelist, artistlist, imagetypelist, othertypelist, qualitylist, lightinglist, cameralist, lenslist, imagetypequalitylist, poemlinelist, songlinelist, greatworklist, fantasyartistlist, popularartistlist, romanticismartistlist, photographyartistlist, emojilist, timeperiodlist, shotsizelist, musicgenrelist, animaladditionlist, addontolocationinsidelist, addontolocationlist, objectadditionslist, humanadditionlist, overalladditionlist, focuslist, directionlist, stylestiloralist, manwomanrelationlist, waterlocationlist, containerlist, firstnamelist, floralist] allwildcardslistwithhybrid = ["-material-", "-descriptor-", "-outfit-", "-conceptsuffix-","-culture-", "-objecttotal-"] allwildcardslistwithhybridlists = [materiallist, descriptorlist,outfitlist,conceptsuffixlist,culturelist, objecttotallist] diff --git a/csvfiles/config/default_config.csv b/csvfiles/config/default_config.csv index 3ccc7d8..d2fe8ba 100644 --- a/csvfiles/config/default_config.csv +++ b/csvfiles/config/default_config.csv @@ -10,6 +10,7 @@ subject_vehicle;on subject_food;on subject_space;on subject_building;on +subject_flora;on # animals; subject_animal;on # humanoids; diff --git a/csvfiles/nature.csv b/csvfiles/flora.csv similarity index 50% rename from csvfiles/nature.csv rename to csvfiles/flora.csv index 3582bc6..9eccaed 100644 --- a/csvfiles/nature.csv +++ b/csvfiles/flora.csv @@ -1,81 +1,133 @@ -Tree -Bush -Flower -Oak tree -Maple tree -Pine tree -Apple tree -Cherry blossom tree -Redwood tree -Birch tree -Willow tree -Palm tree -Magnolia tree -Roses -Sunflowers -Daisies -Tulips -Orchids -Lilies -Poppies -Hydrangeas -Irises -Marigolds -Leaf -Twig -Pinecone +Acacia Acorn -Moss -Seedling -Petal -Fern -Mushroom -Mossy rock -Beehive -Vine -Willow basket -Coral reef -Honeycomb -Wildflower bouquet -Cactus spines -Pebble -Bamboo shoot -Sunflower field -Pine needle carpet -River stone -Seashell +Alder +Algae +Apple tree +Ash Autumn leaf pile -Seaweed -Pine bark -Butterfly cocoon -Dandelion fluff -Bird nest -Water lily pad -Herb garden -Wild berry bush -Tree stump -Coral reef -Wild mushroom patch -Tulip bulb -Oak tree branch -Hummingbird feeder -Pond water lilies -Straw bale +Azalea +Bark +Bamboo +Bamboo shoot +Banyan +Baobab +Beech +Beehive +Birch +Birch tree +Black oak +Branch Bouquet -Forest -Meadow -Garden --waterlocation- -Rainforest -Waterfall -Rock formation -Foliage -Wilderness -Biodiversity -Ecosystem +Bush +Cactus +Cactus spines +Camellia +Carnation +Catalpa +Cedar +Cherry blossom tree +Chestnut +Chrysanthemum +Coral reef +Cypress +Daffodil +Daisies +Daisy +Dandelion +Dandelion fluff +Dogwood +Elm +Eucalyptus +Fern +Fir Flora -Fauna -Woodland -Arboretum +Flower +Foliage +Forest +Fungus +Garden +Geranium +Ginkgo +Grass +Hazel +Herb garden +Hickory +Holly +Honeycomb +Hummingbird feeder +Hydrangea +Iris +Ironwood +Ivy +Jasmine +Juniper +Lavender +Leaf +Lichen +Lilac +Lily +Linden +Locust +Magnolia tree +Mahogany +Maple tree +Marigold +Marigolds +Meadow +Moss +Mossy rock +Mulberry +Mushroom +Nature +Oak tree +Olive Orchard -Herb garden \ No newline at end of file +Orchid +Palm tree +Pear +Pebble +Pecan +Peony +Petal +Petunia +Pine needle carpet +Pine tree +Pinecone +Poinsettia +Pond water lilies +Poplar +Poppies +Red oak +Redwood tree +River stone +Rose +Roses +Sagebrush +Sassafras +Seagrass +Seaweed +Seedling +Sequoia +Shrub +Spruce +Succulent +Sunflower +Sycamore +Tree +Tree stump +Tulip +Flower Bulb +Twig +Vine +Violet +Walnut +Water lily pad +Waterfall +White oak +Wild berry bush +Wild mushroom patch +Wilderness +Wildflower bouquet +Willow +Willow tree +Yew \ No newline at end of file diff --git a/csvfiles/special_lists/backgroundtypes.csv b/csvfiles/special_lists/backgroundtypes.csv index 798e587..0c399a9 100644 --- a/csvfiles/special_lists/backgroundtypes.csv +++ b/csvfiles/special_lists/backgroundtypes.csv @@ -23,4 +23,5 @@ simple -color- background -descriptor- background -descriptor- -color- background -culture- background --space- background \ No newline at end of file +-space- background +-flora- in background \ No newline at end of file diff --git a/csvfiles/special_lists/humanadditions.csv b/csvfiles/special_lists/humanadditions.csv index bb30852..c1fa9eb 100644 --- a/csvfiles/special_lists/humanadditions.csv +++ b/csvfiles/special_lists/humanadditions.csv @@ -5,6 +5,8 @@ visiting a -building- visiting -location- with a -animal- surrounded by -object-s +surrounded by -flora-s +surrounded by -space- eating -food- and -human- holding hands with -human- diff --git a/csvfiles/special_lists/minilocationadditions.csv b/csvfiles/special_lists/minilocationadditions.csv index 027b72d..fe6454a 100644 --- a/csvfiles/special_lists/minilocationadditions.csv +++ b/csvfiles/special_lists/minilocationadditions.csv @@ -6,4 +6,5 @@ -color- -minilocation- lush -minilocation- dense -minilocation- --season- -minilocation- \ No newline at end of file +-season- -minilocation- +-minilocation- with -flora- \ No newline at end of file diff --git a/csvfiles/special_lists/objectadditions.csv b/csvfiles/special_lists/objectadditions.csv index f570ed3..61bcc7c 100644 --- a/csvfiles/special_lists/objectadditions.csv +++ b/csvfiles/special_lists/objectadditions.csv @@ -10,4 +10,5 @@ detailed with -material- -descriptor- patterns intricate details smooth designed by -brand- -made from -space- \ No newline at end of file +made from -space- +made from -flora- \ No newline at end of file diff --git a/csvfiles/special_lists/overalladditions.csv b/csvfiles/special_lists/overalladditions.csv index 305a5d6..db0b502 100644 --- a/csvfiles/special_lists/overalladditions.csv +++ b/csvfiles/special_lists/overalladditions.csv @@ -6,7 +6,7 @@ flying distant nuclear explosion de dia los muertos mechanical -lord of the rings scenery landscape +lord of the rings scenery landscape, -flora- between the stars surrounded by fire and ice infused with ethereal color @@ -41,4 +41,5 @@ clean, soap bubbles, iridescent -color- light shining from within and the genre is -musicgenre- displayed in a rainbow pattern -inside a -container- \ No newline at end of file +inside a -container- +-flora-, -flora-, -flora-, -flora- \ No newline at end of file diff --git a/csvfiles/waterlocations.csv b/csvfiles/waterlocations.csv index bf43b4c..35f1655 100644 --- a/csvfiles/waterlocations.csv +++ b/csvfiles/waterlocations.csv @@ -24,4 +24,7 @@ Glacier Underwater Cave Onsen Bath -Shower \ No newline at end of file +Shower +Sauna +Spa +Thermal baths \ No newline at end of file diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index cee92a8..db62683 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -80,6 +80,7 @@ generateobject = True generatefood = True generatebuilding = True generatespace = True +generateflora = True generateanimal = True generatemanwoman = True generatemanwomanrelation = True @@ -107,6 +108,8 @@ for item in config: generatebuilding = False if item[0] == 'subject_space' and item[1] != 'on': generatespace = False + if item[0] == 'subject_flora' and item[1] != 'on': + generateflora = False # animals if item[0] == 'subject_animal' and item[1] != 'on': generateanimal = False @@ -167,6 +170,8 @@ if(generatebuilding): subjectsubtypesobject.append("buildings") if(generatespace): subjectsubtypesobject.append("space") +if(generateflora): + subjectsubtypesobject.append("flora") # humanoids (should I review descriptions??) if(generatemanwoman): From ec03e4161a8d01f4bf3ebf83512a5be20b018171 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Sun, 9 Jul 2023 08:21:30 +0200 Subject: [PATCH 15/18] =?UTF-8?q?=C3=80dded=20descriptions=20in=20text?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/onebuttonprompt.py | 60 +++++++++++++++++++++++++++++++++++++- 1 file changed, 59 insertions(+), 1 deletion(-) diff --git a/scripts/onebuttonprompt.py b/scripts/onebuttonprompt.py index db62683..c9c7d6e 100644 --- a/scripts/onebuttonprompt.py +++ b/scripts/onebuttonprompt.py @@ -339,6 +339,62 @@ class Script(scripts.Script): 5. concept - Can be a concept, such as "a X of Y", or an historical event such as "The Trojan War". It can also generate a line from a poem or a song. + After choosing object, humanoid or concept a subselection menu will show. You can pick further details here. When choosing humanoid, you can also select the gender you wish to generate. + + Type of Object: + + 1. all - selects randomly (default) + + 2. generic objects - Hodgepodge of objects, can be household items, weapons or any other general object. + + 3. vehicles - Cars, but also planes, trains and boats. + + 4. food - Meals, fruits and others. + + 5. buildings - From churches to libraries to castles. + + 6. space - Some bigger objects, nebula's, black holes and constellations + + 7. flora - Flowers and trees. + + Type of humanoid: + + 1. all - selects randomly (default) + + 2. generic humans - Generic human descriptions. Example values would be Man, Woman, Male, etc + + 3. generic human relations - Human relations, example values would be Grandpa, Sister, Father, etc + + 4. celebrities e.a. - Known people, usually celebrities. + + 5. fictional characters - Movie and videogame characters, such as Mario and Peach. + + 6. humanoids - Humanoid type races, think Elves, Orcs, Dwarves, etc + + 7. based on job or title - Examples are Queen, Carpenter, Vampire hunter + + 8. based on first name - Examples are Anna, James, Emma etc. + + gender: + + 1. all - selects randomly + + 2. male + + 3. female + + Type of concept: + + 1. all - selects randomly (default) + + 2. event - an historical event, or even mythological event. Example The fall of Rome + + 3. the X of Y concepts - Randomly creates a small sentence, example The Ocean of Thought or The Fortress of Flame, etc + + 4. lines from poems - Picks a line from a poem + + 5. lines from songs - Picks a line from a song + ### Artists @@ -420,7 +476,9 @@ class Script(scripts.Script): Add a prompt prefix, suffix and the negative prompt in the respective fields. They will be automatically added during processing. - These can be used to add textual inversion and LoRA's. They can also be used to add your models trigger words. + These can be used to add textual inversion and LoRA's to always apply. They can also be used to add your models trigger words. + + Please read the custom_files documentation on how to apply random textual inversion and LoRA's. From b8bf7648d5c03b04f45253ada9313ef022474215 Mon Sep 17 00:00:00 2001 From: AIrjen <130234949+AIrjen@users.noreply.github.com> Date: Sun, 9 Jul 2023 08:40:42 +0200 Subject: [PATCH 16/18] Create config_file.md --- user_guides/config_file.md | 143 +++++++++++++++++++++++++++++++++++++ 1 file changed, 143 insertions(+) create mode 100644 user_guides/config_file.md diff --git a/user_guides/config_file.md b/user_guides/config_file.md new file mode 100644 index 0000000..8ba1972 --- /dev/null +++ b/user_guides/config_file.md @@ -0,0 +1,143 @@ +# Be in control with config.csv + +After you start up One Button Prompt for the first time, it will create a config.csv file in the /userfiles/ folder. + +In this file, you can not only set what to generate, but you can even set the randomness of certain parts of the generation process. + +To update the UI, you might need to restart WebUI. + +### On resetting/restoring the file + +If you made a mistake, or wish to fully restore the config.csv file in the /userfiles/ folder, simply remove it. It will be recreated by One Button Prompt. + +## Setting main generation options + +In the following part, you can set parts of subjects the generations on and off. Turning off all subjects within a group, turns the main group off. + +Example, if you don't want fictional characters or celebrities in the generation process, turn off subject_fictional and subject_nonfictional. + + + + # objects; + subject_object;on + subject_vehicle;on + subject_food;on + subject_space;on + subject_building;on + subject_flora;on + # animals; + subject_animal;on + # humanoids; + subject_manwoman;on + subject_manwomanrelation;on + subject_fictional;on + subject_nonfictional;on + subject_humanoid;on + subject_job;on + subject_firstnames;on + # landscape; + subject_landscape;on + # concept; + subject_event;on + subject_concept;on + subject_poemline;on + subject_songline;on + +## Other generation options + +These options apply to the default prompt generation mode only. Here you can set the random chance of something appearing in the prompt, or even turn things on and off. + +The config you see is the default config of One Button Prompt. + +You can overwrite these, so for example, if you always want a pose to be generated change __posechance;uncommon__ to __posechance;always__ + +You can use the following random chances, in order of increasing appearing chance: + +- always +- common +- normal +- uncommon +- rare +- legendary +- unique +- extraordinary +- novel +- never + + + + + # other main lists, in order of appearance; + # setting the random chance, for normal generation; + # these can be, in order of most appearing to least appearing; + # always, common, normal, uncommon, rare, legendary, unique, extraordinary, novel, never; + custominputprefixrepeats;2 + custominputprefixchance;uncommon + imagetypechance;normal + imagetypequalitychance;rare + # some prefixes that happen rarely; + minilocationadditionchance;unique + artmovementprefixchance;unique + minivomitprefix1chance;rare + minivomitprefix2chance;unique + # shot size generation; + shotsizechance;uncommon + # subject specific stuff; + subjectdescriptor1chance;common + subjectdescriptor2chance;uncommon + subjectbodytypechance;normal + subjectculturechance;normal + subjectconceptsuffixchance;unique + # subjectlandscape specific stuff; + subjectlandscapeinsideshotchance;unique + subjectlandscapeaddonlocationchance;normal + subjectlandscapeaddonlocationdescriptorchance;rare + subjectlandscapeaddonlocationculturechance;rare + # all additions; + objectadditionsrepeats;2 + objectadditionschance;uncommon + humanadditionchance;rare + overalladditionchance;extraordinary + # humanoid other stuff; + emojichance;legendary + joboractivitychance;normal + # things in the middle of the prompt; + custominputmidrepeats;2 + custominputmidchance;uncommon + minivomitmidchance;unique + # humanoid main stuff; + outfitchance;normal + posechance;uncommon + hairchance;normal + accessorychance;normal + humanoidinsideshotchance;legendary + humanoidbackgroundchance;uncommon + # minilocation stuff; + landscapeminilocationchance;uncommon + generalminilocationchance;rare + # general stuff add the end of the prompt; + timperiodchance;normal + focuschance;normal + directionchance;normal + moodchance;normal + minivomitsuffixchance;unique + artmovementchance;normal + lightingchance;normal + photoadditionchance;common + lenschance;normal + colorschemechance;normal + vomit1chance;uncommon + vomit2chance;uncommon + greatworkchance;novel + poemlinechance;novel + songlinechance;novel + quality1chance;uncommon + quality2chance;uncommon + # custom style list (lora and tis); + customstyle1chance;uncommon + customstyle2chance;uncommon + # suffix custom list; + custominputsuffixrepeats;2 + custominputsuffixchance;uncommon + # artists stuff; + artistsatbackchance;uncommon From 3df49abf7a4d2ea565861fc6b5674e7b9e4cd383 Mon Sep 17 00:00:00 2001 From: AIrjen <130234949+AIrjen@users.noreply.github.com> Date: Sun, 9 Jul 2023 08:42:32 +0200 Subject: [PATCH 17/18] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 519691f..88f2a32 100644 --- a/README.md +++ b/README.md @@ -25,6 +25,7 @@ A simple user guide for first time use and settings is available [here](https:// - Use __wildcards__, or __combine with Dynamic Prompts__ extension ==> [guide to using wildcards and Dynamic Prompts](https://github.com/AIrjen/OneButtonPrompt/blob/main/user_guides/wildcards_and_dynamic_prompts_extension.md) - Has a set of __template prompts__ from various sources, __fully wildcarded__ and usable with Subject Override ==> [guide to prompt templates](https://github.com/AIrjen/OneButtonPrompt/blob/main/user_guides/templates.md) - Has multiple __prompt generation modes__ to choose from ==> [guide to prompt generation modes](https://github.com/AIrjen/OneButtonPrompt/blob/main/user_guides/prompt_generation_modes.md) +- Stay in control, and fine-tune One Button Prompt with a __config__ file ==> [config file](https://github.com/AIrjen/OneButtonPrompt/blob/main/user_guides/config_file.md) ## How to use in automatic1111 In TXT2IMG or IMG2IMG, select the script "One Button Prompt". From ec29c6f064def384ac7359c755220c9a900f63a8 Mon Sep 17 00:00:00 2001 From: AIrjen Date: Sun, 9 Jul 2023 09:11:47 +0200 Subject: [PATCH 18/18] finalizing --- csvfiles/firstnames.csv | 2 +- csvfiles/manwomanrelations.csv | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/csvfiles/firstnames.csv b/csvfiles/firstnames.csv index 21dc518..7ed8865 100644 --- a/csvfiles/firstnames.csv +++ b/csvfiles/firstnames.csv @@ -1,5 +1,5 @@ firstname;gender -AIrjen;god +AIrjen;idiot Aarav;male Abdel;male Abdi;male diff --git a/csvfiles/manwomanrelations.csv b/csvfiles/manwomanrelations.csv index 7376340..f5375d4 100644 --- a/csvfiles/manwomanrelations.csv +++ b/csvfiles/manwomanrelations.csv @@ -7,8 +7,8 @@ Aunt;female Uncle;male Sister;female Brother;male -Sibling;undetermined -Parent;undetermined +Sibling;genderless +Parent;genderless Wife;female Husband;male Girlfriend;female