Skip to content

Prevent image modification using rolling_ball #2

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: master
Choose a base branch
from

Conversation

caeduft
Copy link
Contributor

@caeduft caeduft commented Apr 7, 2021

Subtract_background_rolling_ball (line 57) seems to modify the original image that is used as an argument (even though a different object is created for the output). That is why plotting the original image (line 67) looks like the final image (line 69-70). This issue can also be seen in the YouTube tutorial 43 (min 6:40 - 7:30).

To solve this issue, a copy of the image is created, called image_rb (line 55). The copy of the image (image_rb) is used as an argument for subtract_background_rolling_ball (line 57)

Subtract_background_rolling_ball (line 57) seems to modify the original image that is used as an argument (even though a different object is created for the output). That is why plotting the original image (line 67) looks like the final image (line 69-70). This issue can also be seen in the YouTube tutorial 43 (min 6:40 - 7:30).

To solve this issue, a copy of the image is created, called image_rb (line 55). The copy of the image (image_rb) is used as an argument for subtract_background_rolling_ball (line 57)
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.

None yet

1 participant