Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove object #10

Closed
Arcxml opened this issue Mar 31, 2024 · 6 comments
Closed

remove object #10

Arcxml opened this issue Mar 31, 2024 · 6 comments

Comments

@Arcxml
Copy link

Arcxml commented Mar 31, 2024

Hi, thanks for your code. I have a question, if I want to remove an object (for example I want to remove this blueberry), how should I write the prompt? If I wrote "remove the blueberry" it might not work well.
image

@juxuan27
Copy link
Collaborator

Hi, @Arcxml ! Thank you for your focus. The hugging face space uses the segmentation mask checkpoint, thus it will force a boundary in the mask region. I recommend you use a random segmentation mask checkpoint and add blueberry to the negative prompt. Since it is really hard for the diffusion model to understand remove xxx.

@Arcxml
Copy link
Author

Arcxml commented Mar 31, 2024 via email

@juxuan27
Copy link
Collaborator

I think the prompt will influence the results. But as I said, I believe the most important reason is the ckpt used in hugging face space. You can try locally changing the ckpt to the random mask one, which can be downloaded from the Google Drive link we provide. I think this may lead to a better result~

Using the segmentation mask ckpt can successfully remove the blueberry by putting blueberry in the negative prompt. However, it would lead to incoherent results due to the force of generating a boundary.

@Arcxml
Copy link
Author

Arcxml commented Apr 2, 2024

If I put the unnecessary objects in the negative prompt, new other objects will be generated. But I don’t want to create any new objects. I want them to complete the background. Do you have any other suggestions?

@juxuan27
Copy link
Collaborator

juxuan27 commented Apr 2, 2024

As mentioned in my previous comments, you need to use random mask ckpt instead of segmentation mask ckpt to remove objects.

@Arcxml
Copy link
Author

Arcxml commented Apr 2, 2024 via email

@juxuan27 juxuan27 closed this as completed Apr 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants