Skip to content

Allow independent background image in plantcv.visualize.pseudocolor() and others. #1650

@rayn-alex

Description

@rayn-alex

Is your feature request related to a problem? Please describe.
E.g. I'm using pseudocolor to visualize anthocyanin content (ARI). It is only possible to have a white, black or input grayscale as background. I would love to have either an RGB image or a monochromatic image which is not the index reflection result as background.

Describe the solution you'd like
Add and option/input for an image that will be uses as a background. E.g. like this:

plantcv.visualize.pseudocolor(gray_img, mask=None, background="image", bg_image=None, cmap=None, min_value=0, max_value=255, axes=True, colorbar=True, bad_mask=None, bad_color="red")

If background="image" and bg_image=None the gray_img will be used as background
If background="image" and bg_image=bg_img the bg_img will be used as background

Describe alternatives you've considered
Of course, this can be done outside plantCV using the original matplotlib functions. I just think it might be convenient and useful to more users.

I can implement this if you all think it makes sense.

Here is an example made with matplotlib
image

Metadata

Metadata

Assignees

Labels

new featureNew feature ideas and solutions

Type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions