diff --git a/BaiHu/JSON/49/49_1.json b/BaiHu/JSON/49/49_1.json new file mode 100644 index 00000000..e60cb9d6 --- /dev/null +++ b/BaiHu/JSON/49/49_1.json @@ -0,0 +1,42 @@ +{ + "override_settings": { + "sd_model_checkpoint": "思悦简笔插画 siyue illustration_1.0.safetensors [52c125470a]", + "sd_vae": "vae-ft-mse-840000-ema-pruned.safetensors" + }, + "prompt": "", + "negative_prompt": "NSFW,blurry,low quality,watermark,monochrome,badhandv4,EasyNegative,ng_deepnegative_v1_75t,(bad eyes:1.5),(unclear eyes:1.5),bad proportions,mutated hands and fingers,poorly drawn face,extra limb,missing limb,malformed limbs,disconnected limbs,ugly,floating limbs,extra legs,mutation,bad body,long neck,cross-eyed,text,cleavage", + "steps": 23, + "sampler_name": "DPM++ 2M Karras", + "width": 0, + "height": 0, + "batch_size": 1, + "n_iter": 1, + "seed": 1, + "cfg_scale": 6, + "CLIP_stop_at_last_layers": 2, + "init_images": [ + "string" + ], + "restore_faces": false, + "enable_hr": true, + "denoising_strength": 0.75, + "alwayson_scripts": { + "ControlNet": { + "args": [ + { + "enabled": true, + "model": "control_v11p_sd15_softedge [a8575a2a]", + "module": "softedge_pidinet", + "weight": 1, + "resize_mode": "Crop and Resize", + "guidance_start": 0, + "guidance_end": 1, + "pixel_perfect": true, + "processor_res": 512, + "save_detected_map": true, + "control_mode": "Balanced" + } + ] + } + } +} \ No newline at end of file diff --git a/BaiHu/JSON/49/49_2.json b/BaiHu/JSON/49/49_2.json new file mode 100644 index 00000000..eb388ea5 --- /dev/null +++ b/BaiHu/JSON/49/49_2.json @@ -0,0 +1,42 @@ +{ + "override_settings": { + "sd_model_checkpoint": "潮玩IP形象设计 _ 3D Toy Style_v1.0.safetensors [d2915404de]", + "sd_vae": "vae-ft-mse-840000-ema-pruned.safetensors" + }, + "prompt": "", + "negative_prompt": "NSFW,blurry,low quality,watermark,monochrome,badhandv4,EasyNegative,ng_deepnegative_v1_75t,(bad eyes:1.5),(unclear eyes:1.5),bad proportions,mutated hands and fingers,poorly drawn face,extra limb,missing limb,malformed limbs,disconnected limbs,ugly,floating limbs,extra legs,mutation,bad body,long neck,cross-eyed,text,cleavage", + "steps": 23, + "sampler_name": "DPM++ 2M Karras", + "width": 0, + "height": 0, + "batch_size": 1, + "n_iter": 1, + "seed": 1, + "cfg_scale": 6, + "CLIP_stop_at_last_layers": 2, + "init_images": [ + "string" + ], + "restore_faces": false, + "enable_hr": true, + "denoising_strength": 0.75, + "alwayson_scripts": { + "ControlNet": { + "args": [ + { + "enabled": true, + "model": "control_v11p_sd15_softedge [a8575a2a]", + "module": "softedge_pidinet", + "weight": 1, + "resize_mode": "Crop and Resize", + "guidance_start": 0, + "guidance_end": 1, + "pixel_perfect": true, + "processor_res": 512, + "save_detected_map": true, + "control_mode": "Balanced" + } + ] + } + } +} \ No newline at end of file diff --git a/BaiHu/JSON/49/49_3.json b/BaiHu/JSON/49/49_3.json new file mode 100644 index 00000000..68befff6 --- /dev/null +++ b/BaiHu/JSON/49/49_3.json @@ -0,0 +1,42 @@ +{ + "override_settings": { + "sd_model_checkpoint": "次元幻想|SHMILY绚丽多彩_V3.0.safetensors [c1225fb71d]", + "sd_vae": "vae-ft-mse-840000-ema-pruned.safetensors" + }, + "prompt": "", + "negative_prompt": "NSFW,blurry,low quality,watermark,monochrome,badhandv4,EasyNegative,ng_deepnegative_v1_75t,(bad eyes:1.5),(unclear eyes:1.5),bad proportions,mutated hands and fingers,poorly drawn face,extra limb,missing limb,malformed limbs,disconnected limbs,ugly,floating limbs,extra legs,mutation,bad body,long neck,cross-eyed,text,cleavage", + "steps": 23, + "sampler_name": "DPM++ 2M Karras", + "width": 0, + "height": 0, + "batch_size": 1, + "n_iter": 1, + "seed": 1, + "cfg_scale": 6, + "CLIP_stop_at_last_layers": 2, + "init_images": [ + "string" + ], + "restore_faces": false, + "enable_hr": true, + "denoising_strength": 0.75, + "alwayson_scripts": { + "ControlNet": { + "args": [ + { + "enabled": true, + "model": "control_v11p_sd15_softedge [a8575a2a]", + "module": "softedge_pidinet", + "weight": 1, + "resize_mode": "Crop and Resize", + "guidance_start": 0, + "guidance_end": 1, + "pixel_perfect": true, + "processor_res": 512, + "save_detected_map": true, + "control_mode": "Balanced" + } + ] + } + } +} \ No newline at end of file diff --git a/BaiHu/JSON/49/49_4.json b/BaiHu/JSON/49/49_4.json new file mode 100644 index 00000000..67b71beb --- /dev/null +++ b/BaiHu/JSON/49/49_4.json @@ -0,0 +1,42 @@ +{ + "override_settings": { + "sd_model_checkpoint": "焕彩少女Colored girl_1.0.safetensors [820ffa0441]", + "sd_vae": "vae-ft-mse-840000-ema-pruned.safetensors" + }, + "prompt": "", + "negative_prompt": "NSFW,blurry,low quality,watermark,monochrome,badhandv4,EasyNegative,ng_deepnegative_v1_75t,(bad eyes:1.5),(unclear eyes:1.5),bad proportions,mutated hands and fingers,poorly drawn face,extra limb,missing limb,malformed limbs,disconnected limbs,ugly,floating limbs,extra legs,mutation,bad body,long neck,cross-eyed,text,cleavage", + "steps": 23, + "sampler_name": "DPM++ 2M Karras", + "width": 0, + "height": 0, + "batch_size": 1, + "n_iter": 1, + "seed": 1, + "cfg_scale": 6, + "CLIP_stop_at_last_layers": 2, + "init_images": [ + "string" + ], + "restore_faces": false, + "enable_hr": true, + "denoising_strength": 0.75, + "alwayson_scripts": { + "ControlNet": { + "args": [ + { + "enabled": true, + "model": "control_v11p_sd15_softedge [a8575a2a]", + "module": "softedge_pidinet", + "weight": 1, + "resize_mode": "Crop and Resize", + "guidance_start": 0, + "guidance_end": 1, + "pixel_perfect": true, + "processor_res": 512, + "save_detected_map": true, + "control_mode": "Balanced" + } + ] + } + } +} \ No newline at end of file diff --git a/BaiHu/JSON/49/49_5.json b/BaiHu/JSON/49/49_5.json new file mode 100644 index 00000000..6692ed66 --- /dev/null +++ b/BaiHu/JSON/49/49_5.json @@ -0,0 +1,42 @@ +{ + "override_settings": { + "sd_model_checkpoint": "儿童插画绘本Minimalism_v2.0.safetensors [3c8ed11a16]", + "sd_vae": "vae-ft-mse-840000-ema-pruned.safetensors" + }, + "prompt": "", + "negative_prompt": "NSFW,blurry,low quality,watermark,monochrome,badhandv4,EasyNegative,ng_deepnegative_v1_75t,(bad eyes:1.5),(unclear eyes:1.5),bad proportions,mutated hands and fingers,poorly drawn face,extra limb,missing limb,malformed limbs,disconnected limbs,ugly,floating limbs,extra legs,mutation,bad body,long neck,cross-eyed,text,cleavage", + "steps": 23, + "sampler_name": "DPM++ 2M Karras", + "width": 0, + "height": 0, + "batch_size": 1, + "n_iter": 1, + "seed": 1, + "cfg_scale": 6, + "CLIP_stop_at_last_layers": 2, + "init_images": [ + "string" + ], + "restore_faces": false, + "enable_hr": true, + "denoising_strength": 0.75, + "alwayson_scripts": { + "ControlNet": { + "args": [ + { + "enabled": true, + "model": "control_v11p_sd15_softedge [a8575a2a]", + "module": "softedge_pidinet", + "weight": 1, + "resize_mode": "Crop and Resize", + "guidance_start": 0, + "guidance_end": 1, + "pixel_perfect": true, + "processor_res": 512, + "save_detected_map": true, + "control_mode": "Balanced" + } + ] + } + } +} \ No newline at end of file diff --git a/BaiHu/JSON/49/49_6.json b/BaiHu/JSON/49/49_6.json new file mode 100644 index 00000000..1e0a2869 --- /dev/null +++ b/BaiHu/JSON/49/49_6.json @@ -0,0 +1,42 @@ +{ + "override_settings": { + "sd_model_checkpoint": "普通2.5D_V1.0.safetensors [00c373fc73]", + "sd_vae": "vae-ft-mse-840000-ema-pruned.safetensors" + }, + "prompt": ",", + "negative_prompt": "NSFW,blurry,low quality,watermark,monochrome,badhandv4,EasyNegative,ng_deepnegative_v1_75t,(bad eyes:1.5),(unclear eyes:1.5),bad proportions,mutated hands and fingers,poorly drawn face,extra limb,missing limb,malformed limbs,disconnected limbs,ugly,floating limbs,extra legs,mutation,bad body,long neck,cross-eyed,text,cleavage", + "steps": 23, + "sampler_name": "DPM++ 2M Karras", + "width": 0, + "height": 0, + "batch_size": 1, + "n_iter": 1, + "seed": 1, + "cfg_scale": 6, + "CLIP_stop_at_last_layers": 2, + "init_images": [ + "string" + ], + "restore_faces": false, + "enable_hr": true, + "denoising_strength": 0.75, + "alwayson_scripts": { + "ControlNet": { + "args": [ + { + "enabled": true, + "model": "control_v11p_sd15_softedge [a8575a2a]", + "module": "softedge_pidinet", + "weight": 1, + "resize_mode": "Crop and Resize", + "guidance_start": 0, + "guidance_end": 1, + "pixel_perfect": true, + "processor_res": 512, + "save_detected_map": true, + "control_mode": "Balanced" + } + ] + } + } +} \ No newline at end of file diff --git a/BaiHu/Temp/90bbb99e-ff45-d0c1-de37-f7747b8d9ce8.jpg b/BaiHu/Temp/90bbb99e-ff45-d0c1-de37-f7747b8d9ce8.jpg new file mode 100644 index 00000000..dbe72eb1 Binary files /dev/null and b/BaiHu/Temp/90bbb99e-ff45-d0c1-de37-f7747b8d9ce8.jpg differ diff --git a/BaiHu/doTask.py b/BaiHu/doTask.py index 7509da11..46962b4a 100644 --- a/BaiHu/doTask.py +++ b/BaiHu/doTask.py @@ -139,23 +139,15 @@ def webui_convert(model_id, json_data, input_image, target_folder): height = img.size[1] img.close() - # 然后需要干点啥? - # TODO + # 填充反推的提示词,以原图片的宽高为参数 + json_data['prompt'] = prompt+json_data['prompt'] + json_data['width'] = width + json_data['height'] = height # 图片 args = json_data['alwayson_scripts']['ControlNet']['args'] - pose_image = json_data['pose_image'] args[0]['input_image'] = encode_image(input_image[0]) - # 如果有特殊的姿态要求,那就用模板指定的姿态图 - if len(pose_image) > 0: - if len(args) > 1: - args[1]['input_image'] = encode_image(pose_image) - else: # 如果没有特殊的姿态要求,那么就统一用一张图片 - if len(args) > 1: - args[1]['input_image'] = encode_image(input_image[0]) - # 提示词 - json_data['prompt'] = prompt # 开始生成图片 printf("开始生成图片...") # 调用图生图服务 @@ -301,7 +293,6 @@ def get_task(): webui_convert(model_id=model_id, prompt_id=prompt_id, json_data=vjson_data, input_image=input_image, target_folder=output_path) - return task_id elif success == 0: printf("现在没有待处理的任务,休息1秒后再试...")