How to write the request json when I call the img2img interface of the sd by Multi-frame rendering script, my original request json was as follows:
payload = {
"init_images": [image_base64],
# "prompt": prompt,
"prompt": prompts[i],
"negative_prompt": negative_prompt,
"styles": [],
"seed": 2694589603,
"subseed": -1,
"subseed_strength": 0,
"seed_resize_from_h": height,
"seed_resize_from_w": width,
"sampler_index": "Euler a",
"sampler_name": "Euler a",
"batch_size": 1,
"n_iter": 1,
"steps": 30,
"clip_skip": 1,
"cfg_scale": 8,
"width": width,
"height": height,
"restore_faces": True,
"tiling": False,
"do_not_save_samples": False,
"do_not_save_grid": False,
"eta": 0,
"denoising_strength": 0.4,
"s_min_uncond": 0,
"s_churn": 0,
"s_tmax": 0,
"s_tmin": 0,
"s_noise": 0,
#"override_settings": {
# "sd_model_checkpoint": "chosenMix_chosenMix.ckpt [dd0aacadb6]",
# "sd_vae": "pastel-waifu-diffusion.vae.pt"
#},
"override_settings_restore_afterwards": True,
"refiner_checkpoint": "",
"refiner_switch_at": 0,
"disable_extra_networks": False,
"comments": {},
"resize_mode": 0,
"image_cfg_scale": 1.5,
"mask": None,
"mask_blur_x": 4,
"mask_blur_y": 4,
"mask_blur": 0,
"inpainting_fill": 0,
"inpaint_full_res": True,
"inpaint_full_res_padding": 1,
"inpainting_mask_invert": 1,
"initial_noise_multiplier": 1.0,
"latent_mask": None,
"include_init_images": False,
"script_name": "",
"script_args": [],
"send_images": True,
"save_images": False,
"alwayson_scripts": {
"ControlNet": {
"args": [
{
"input_image": image_base64,
"enabled": True,
"lowvram": False,
"pixel_perfect": True,
"mask": None,
"module": "canny",
"model": "control_canny-fp16 [e3fe7712]",
"weight": 2,
"guidance_start": 0,
"guidance_end": 1,
"threshold_a": 100,
"threshold_b": 200,
"control_mode": 2,
"resize_mode": 1,
"processor_res": width
}
]
},
"face editor ex": {
"args": [
{
"prompt_for_face": "best quality, highly detailed, extremely detailed, shiny skin, shiny clothes, perfect face, beautiful face, white face, anime, cute, manga, green eyes, red lips",
"affected_areas": ["Face", "Hair"],
"use_minimal_area": True,
"save_original_image": True,
"face_size": width,
"upscaler": "R-ESRGAN 4x+"
}
]
}
}
}