Questions tagged [image-segmentation]

Segmentation is a basic operation in image processing: its purpose is to group similar pixels into coherent regions = segments.

In image processing, image segmentation is the process of partitioning an image into multiple segments (sets of pixels). The goal of segmentation is to simplify and/or change the representation of an image into something that is more meaningful and easier to analyze. More precisely, image segmentation is the process of assigning a label to every pixel in an image such that pixels with the same label share certain visual characteristics.

The result of image segmentation is a set of segments that collectively cover the entire image. Each of the pixels in a region are similar with respect to some characteristic or computed property, such as color, intensity, or texture. Adjacent regions are significantly different with respect to the same characteristic(s).

Image segmentation is somewhat related to perceptual grouping: the spatial organization of visual stimuli. Some image segmentation algorithms attempt to employ Gestalt Laws of perceptual grouping to produce visually meaningful image segments.

Some popular image segmentation algorithms are Normalized cuts (by Shi and malik) and Mean-shift (by Comaniciu and Meer).

2542 questions
0
votes
1 answer

Convert Numpy Array to Bitmap in C#, Keras.Net

I am working on image semantic segmentation, and trying to figure out how to convert the prediction (after argmax) to bitmap. If I use ArrayToImg from ImageUtil, it returns a system object. How do I convert it to bitmap from here? I trained the…
vuict
  • 72
  • 5
0
votes
0 answers

skimage reclassification using threshold_otsu

I am attempting to reclassify an image as binary using skimage's threshold_otsu. In theory, the image I am reclassifying SHOULD have values of 0, signifying no occurrence of phenomenon, and values != 0, meaning there is occurrence of the phenomenon…
Max Duso
  • 305
  • 1
  • 4
  • 15
0
votes
0 answers

Image Segmentation: How do I convert a png mask file to array?

I am working on a multi-class image segmentation problem but am having difficulty appropriately converting my .png mask files to arrays. Instead of values corresponding to the number of classes (13), the masks have seemingly random values between 30…
aiden
  • 1
0
votes
0 answers

Image Segmentation using MAML algorithm (same objects exist in all tasks)

I have an n-takes k-shots medical image segmentation problem. -Tasks: Different human organs ex: liver, spleen, kindness etc... -Shots: 10 CT scans NIFTI images, where all tasks(human organs) exist in all shots, but one of them is labelled to match…
0
votes
0 answers

Validation metrics for non background classes fluctating epoch to epoch

We are working on semantic segmenation for our thesis, aiming the goal to stratify lesions in T2W 2d-images of the prostate. What we're dealing with is a 3 class problem, having following labels: 0 = background, 1 = insignificant tumor, 2 =…
0
votes
1 answer

Instance Segmentation Using Mask R-CNN on Custom Dataset IndexError

I am working on semantic segmentation and I came across Instance Segmentation Using Mask R-CNN on Custom Dataset by Code With Aarohi. I met an error. This is the snippet of the code related to the error: def load_mask(self, image_id): …
0
votes
1 answer

Clean up region extraction with RGB color masking

I am developing a color masking algorithm to extract overlapped regions of interest in images, using Python 3.9 and cv2. To achieve this, I'm implementing K-Means clustering as a way to group up similar pixels and reduce the image's color palette to…
Johnny
  • 117
  • 10
0
votes
0 answers

keras-unet-collection training on custom dataset causes incompatible shapes error

Full code used: import os import numpy as np from keras_unet_collection import models, losses from tensorflow import keras from PIL import Image def hybrid_loss(y_true, y_pred): loss_focal = losses.focal_tversky(y_true, y_pred, alpha=0.5,…
0
votes
0 answers

improving the U-Net network results

I have 700 chest MRI images with related ground truths. i am trying to segment the images with the help of U-Net network.Firsly i resize the image and then normalize them. then split the data to traing, validation and test part. then after feed the…
0
votes
0 answers

unable to open file: 'mask_rcnn_coco_h5' in pixellib python

This is my code (as per pixellib documentation) import pixellib from pixellib.instance import instance_segmentation segment_image = instance_segmentation(infer_speed = "rapid"…
0
votes
0 answers

not producing right output in mean_shift algorithm and performing segmentation for the image

I have a problem like I have to implement shift algorithm and perform the segmentation for the image. here is vegetable image I have to use a suitable bandwidth such that the vegetables look as seprated as can. I used manually sklearn…
0
votes
0 answers

Detectron2 saving predicted annotation images to COCO file

I am doing semantic segmentation. Detectron2 can produce prediction mask labels as pictures. Can I save the predicted annotation images in COCO file instead of pictures. The COCO file can be used for editing in annotation tools like labelme. Do you…
0
votes
0 answers

ttributeError: module 'keras.api._v2.keras.utils' has no attribute 'data_utils

Whenever I use this line: keras.utils.data_utils.SequenceIterator([train_generator_object, train_generator_nonobject]) I get this error: AttributeError: module 'keras.api._v2.keras.utils' has no attribute 'data_utils' Is there a fix for this? P.S. I…
0
votes
0 answers

What is the best approach to generating prediction of heatmaps from fixation maps?

If I have an image (a) and corresponding fixation heatmaps (c) for those images, what model would be best for generating predicted heatmaps for images. I have tried implementing a U-Net segmentation model where the inputs are both (a) and (c).…
0
votes
2 answers

Image segmentations with gradient filled regions

I have to work on image segmentation. The idea is to divide an image into regions which have pixels either of the similar color or the ones which can be represented by a gradient equation (linear or radial). I have found many algorithms which do the…
Aarkan
  • 3,811
  • 6
  • 40
  • 54