
).to("cuda") Generate an image from the base model, and set the model output to latent space:   Copied prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k"

image = base(prompt=prompt, output_type="latent").images[0] Pass the generated image to the refiner model:   Copied image = refiner(prompt=prompt, image=image[None, :]).images[0]  base model  base model + refiner model For inpainting, load the base and the refin