IC-Light
IC-Light copied to clipboard
All images must be cutout before further processing. How can I skip the cutout step?
All images must be cutout before further processing. How can I skip the cutout step?
You can just comment out the line that says input_fg, matting = run_rmbg(input_fg)
in the process_relight
function in gradio_demo.py
, so the function looks like this:
@torch.inference_mode()
def process_relight(input_fg, prompt, image_width, image_height, num_samples, seed, steps, a_prompt, n_prompt, cfg, highres_scale, highres_denoise, lowres_denoise, bg_source):
#input_fg, matting = run_rmbg(input_fg)
results = process(input_fg, prompt, image_width, image_height, num_samples, seed, steps, a_prompt, n_prompt, cfg, highres_scale, highres_denoise, lowres_denoise, bg_source)
return input_fg, results