Ask Your Question

Raki's profile - activity

2019-01-16 06:43:44 -0500 edited question Image Classification

Image Classification I am trying to classify two kinds of images as follows: (1) (2) classes can be called unscrewabl

2019-01-16 06:43:31 -0500 commented question Image Classification

Python3. Sorry, I am adding that to the question too.

2019-01-16 06:12:35 -0500 commented question Image Classification

Thank you for your valuable input. I'll try it out and share the results.

2019-01-16 05:20:18 -0500 commented question Image Classification

@StevenPuttemans See my updated post, the images are really similar to each other, with only a slot being the difference

2019-01-16 05:19:26 -0500 edited question Image Classification

Image Classification I am trying to classify two kinds of images as follows: (1) (2) classes can be called unscrewabl

2019-01-16 05:17:59 -0500 commented question Image Classification

@gino0717 I thought of that too, but not all of them have circles, sometimes it is just a hole without a slot. So hough

2019-01-15 07:28:42 -0500 asked a question Image Classification

Image Classification I am trying to classify two kinds of images as follows: (1) (2) classes can be called unscrewabl

2019-01-14 00:58:55 -0500 marked best answer pointPolygonTest() throws error for some reason

I am using the following piece of code to check if a point is inside the contour or not:

    # form the contour from points 
    cnt = []
    for pose in component.part_outline.outline_poses.poses:
                    point = (pose.position.x, pose.position.y)
                    cnt.append(point)    
    cnt = np.array(cnt)

    # get the point to be tested
    point = (screw.pose.position.x, screw.pose.position.y)

    # run the test
    is_inside = cv2.pointPolygonTest(cnt,point, False) 
    if is_inside > 0:
             print("bla bla") # act upon the outcome

and I get the following error for some reason:

"error: OpenCV(3.4.4) /io/opencv/modules/imgproc/src/geometry.cpp:103: error: (-215:Assertion failed) total >= 0 && (depth == CV_32S || depth == CV_32F) in function 'pointPolygonTest'\n\n"

This error message does not tell much to be honest, and I have absolutely no idea why this is happening. I checked the image, it's there. The contour and the point are also there, nothing is null or whatsoever.

P.S: In case if it helps, I tried to print the variable is_inside and it prints (-1.0) for 4 times, then the error is thrown.

Any idea?

2019-01-14 00:58:52 -0500 commented question pointPolygonTest() throws error for some reason

@supra56 Mine works now yes.

2019-01-11 06:56:46 -0500 commented question pointPolygonTest() throws error for some reason

Okay, turns out one has to use int() to cast each value, as you said. I can accept your answer if you add it.

2019-01-11 05:08:39 -0500 commented question pointPolygonTest() throws error for some reason

(466, 43) (102, 37) (682, 458) (468, 459) (466, 43) these are the points that I feed into, what's wrong

2019-01-11 04:30:04 -0500 edited question pointPolygonTest() throws error for some reason

pointPolygonTest() throws error for some reason I am using the following piece of code to check if a point is inside the

2019-01-11 04:29:50 -0500 edited question pointPolygonTest() throws error for some reason

pointPolygonTest() throws error for some reason I am using the following piece of code to check if a point is inside the

2019-01-11 04:23:54 -0500 edited question pointPolygonTest() throws error for some reason

pointPolygonTest() throws error for some reason I am using the following piece of code to check if a point is inside the

2019-01-11 04:17:13 -0500 asked a question pointPolygonTest() throws error for some reason

pointPolygonTest() throws error for some reason I am using the following piece of code to check if a point is inside the

2018-12-03 02:18:13 -0500 commented answer How to get boundry and center information of a mask

Just a question: Is there a way to get the image coordinates of the moments? Like, given a contour, getting all the coor

2018-11-27 10:11:02 -0500 received badge  Commentator
2018-11-27 10:11:02 -0500 commented answer How to get boundry and center information of a mask

Indeed it does perform it. Marvelous, Thanks!

2018-11-27 10:10:23 -0500 marked best answer How to get boundry and center information of a mask

Hi,

I have the following mask:

mask

and I would like to get this mask's center position as well as its boundary positions. Since this is not a rigid geometric shape, I don't know how exactly one could get its center, hence my question.

As for the boundary information, do we need to use a contour detector? Is there a simpler way?

Thanks in advance.

2018-11-27 09:36:29 -0500 commented answer How to get boundry and center information of a mask

I have a boolean array and it does not work with it. I converted it into integer array but then TypeError: Layout of the

2018-11-27 09:25:35 -0500 commented answer How to get boundry and center information of a mask

Do these methods work with a binary image though? If not, is there a way to convert my mask to the format the contour fu

2018-11-27 09:24:21 -0500 commented answer How to get boundry and center information of a mask

Do these methods work with a binary image though? If not, is there a way to convert my mask to the format the contour fu

2018-11-27 08:32:09 -0500 edited question How to get boundry and center information of a mask

How to get boundry and center information of a mask Hi, I have the following mask: and I would like to get this ma

2018-11-27 08:31:28 -0500 asked a question How to get boundry and center information of a mask

How to get boundry and center information of a mask Hi, I have the following mask: and I would like to get this ma

2018-11-27 08:27:58 -0500 commented question Stereo Algorthim fails: cv2.StereoSGBM

Okay, noted, thanks

2018-11-27 07:51:29 -0500 commented question Stereo Algorthim fails: cv2.StereoSGBM

It worked, thanks

2018-11-27 07:37:51 -0500 commented question Stereo Algorthim fails: cv2.StereoSGBM

Sorry I didn't get what exactly I have to use. I don't have setNumthreads() in my code.

2018-11-27 02:41:06 -0500 asked a question Stereo Algorthim fails: cv2.StereoSGBM

Stereo Algorthim fails: cv2.StereoSGBM I am trying out various stereo matchers to build a disparity map of two image I t

2018-11-27 02:27:10 -0500 edited question Depth Map from Stereo-Imaging and Single Camera

Depth Map from Stereo-Imaging and Single Camera Hi all, I'm going to try to imitate stereo-imaging by having 1 camera

2018-11-23 08:51:56 -0500 edited question Depth Map from Stereo-Imaging and Single Camera

Depth Map from Stereo-Imaging and Single Camera Hi all, I'm going to try to imitate stereo-imaging by having 1 camera

2018-11-23 08:51:23 -0500 asked a question Depth Map from Stereo-Imaging and Single Camera

Depth Map from Stereo-Imaging and Single Camera Hi all, I'm going to try to imitate stereo-imaging by having 1 camera

2018-11-22 11:02:14 -0500 commented question Overlaying two different images

Anyway, I think I am going to ask it somewhere else. It's getting cynical here.

2018-11-22 10:54:20 -0500 commented question Overlaying two different images

Pasting the masked image on the depth image is what overlaying means. I don't know what else it could mean anyway. There

2018-11-22 10:53:03 -0500 commented question Overlaying two different images

Pasting the masked image on the depth image is what overlaying means. I don't know what else it could mean anyway. There

2018-11-22 10:49:36 -0500 edited question Overlaying two different images

Overlaying two different images I am trying to overlay two images on each other. One is the mask(called merged_mask) the

2018-11-22 10:46:53 -0500 edited question Overlaying two different images

Overlaying two different images I am trying to overlay two images on each other. One is the mask(called merged_mask) the

2018-11-22 10:43:52 -0500 commented question Overlaying two different images

It is related, since after the reading the overlaying part will come. How can you overlay images if they are not properl

2018-11-22 10:36:54 -0500 asked a question Overlaying two different images

Overlaying two different images I am trying to overlay two images on each other. One is the mask(called merged_mask) the

2018-11-14 06:43:07 -0500 commented question OpenCV 3 + Python 3 + Firewire Cameras

Ah yes, I have that DC1394: NO\n there too, now I saw. So okay this means it's not built, and one n

2018-11-14 06:42:37 -0500 commented question OpenCV 3 + Python 3 + Firewire Cameras

Ah yes, I have tat DC1394: NO\n there too, now I saw. So okay this means it's not built, and one ne

2018-11-14 06:34:44 -0500 commented question OpenCV 3 + Python 3 + Firewire Cameras

ittnotify libprotobuf libwebp libpng libtiff libjasper IlmImf\n\n OpenCV modules:\n To be built: aru

2018-11-14 06:26:39 -0500 commented question OpenCV 3 + Python 3 + Firewire Cameras

Oh my... Why are such things not coming with pip or ros, now one needs to do everything from the scratch... Anyway, tha

2018-11-14 05:17:40 -0500 commented question OpenCV 3 + Python 3 + Firewire Cameras

They return false, but that's the thing, I don't know if I use the proper OpenCV commands to get frames from a firewire

2018-11-14 05:17:15 -0500 commented question OpenCV 3 + Python 3 + Firewire Cameras

They return false, but that's the thing, I don't know if I use the proper OpenCV commands to get frames from a firewire