Open pseudo-swati opened 1 year ago
Could anybody please help me with this ? I am still not sure how to proceed .
I think you have to do it yourself, using image-manipulation libraries such as PIL, OpenCV or scikit-image.
Could anybody please help me with this ? I am still not sure how to proceed .
Have you solved this problem? Please guide me. Thank you.
Could anybody please help me with this ? I am still not sure how to proceed .
Have you solved this problem? Please guide me. Thank you.
Simple image composing in matplotlib as example:
import matplotlib.pyplot as plt
img = plt.imread(img_path)
mask = plt.imread(mask_path)
plt.figure(figsize = (15,5))
plt.imshow(img)
plt.imshow(mask, alpha=0.20)
This will draw mask with 20% transparency over image. I don't know how to draw mask borders, but I'm pretty sure it's doable, if not in Matplotlib then in Pillow.
If you want to save masked images, then you better compose mask and image using Pillow.
In Patchcore code utils.py about line 72 ,to obtain this predicted image ,I added axes[3].imshow ...as you written. There is an indexerror: index 3 is out of bounds for axis 0 with size 3. Did you have the predicted image with the Patchcore? If you did , how can I do in details.
In Patchcore code utils.py about line 72 ,to obtain this predicted image ,I added axes[3].imshow ...as you written. There is an indexerror: index 3 is out of bounds for axis 0 with size 3. Did you have the predicted image with the Patchcore? If you did , how can I do in details.
I'd advise create masks using Patchcore. Model saves them in some of its folders. And after that you can write your own script and mix original images with masks. This will be much faster and easier than edit and debug original code.
Thank you for providing this code. When I am trying to implement your code , I do not get the image with the segmented area .
Even by trying to save the segmentation images by setting "--save_segmentation_images" , I get the following result.
I am new to detection could someone please guide me as to how can I get the segmented image as output as shown