Skip to content

Fix do_rembg flag being ignored in run_views_to_3d #13

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ncan33
Copy link

@ncan33 ncan33 commented Jul 28, 2025

This PR fixes a bug in run_views_to_3d where the do_rembg=False setting was being ignored, leading to unnecessary background removal.

Root Cause

The issue was caused by run_segmentation() defaulting to do_rembg=True and not being explicitly passed the do_rembg argument from run_views_to_3d.

Fix

The do_rembg parameter is now explicitly passed:

image_rgba = self.run_segmentation(image, do_rembg=do_rembg)

…ary background removal

- Fix bug where `remove_background()` was called even when `do_rembg=False` in `run_views_to_3d`.  
- This was due to `run_segmentation()` defaulting to `do_rembg=True` and not receiving the explicit flag.  
- Now passes `do_rembg=do_rembg` to ensure correct behavior.
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

Successfully merging this pull request may close these issues.

1 participant