I am trying to do a in painting. AS per the api doc: https://platform.openai.com/docs/api-reference/images/createEdit provided snippet as below
if current_mask_path and os.path.exists(current_mask_path):
response = client.images.edit(
image=open(last_image_path, "rb"),
mask=open(current_mask_path, "rb"),
prompt=prompt,
size="1024x1024",
n=1,
)
else:
response = client.images.generate(
model="dall-e-3",
prompt=prompt,
size="1024x1024",
n=1,
)
mask is the same size image stored as RGBA 32 bit png. not sure what is missed here.
Prompts are ignored in the edit and alpha mask is filled as in original image.
Any clue around this will be of great help!