loading
 
Showing a specific blob
Dawson from Malaysia  [173 posts]
5 years
Hi STeven

If i used the blob filter to narrow down the blobs to say 4 blobs and used VBScript to choose only one, how do i get the display to show that particular blob that i want?
Anonymous 5 years
Dawson,

Use the blob filter again after your VBScript and use the Proximity->Nearest and then specify the COG of the blob you selected using

[my_cog_x]
[my_cog_y]

in the X and Y fields. That means select the blob nearest to the provided X and Y coordinates.

STeven.
Dawson from Malaysia  [173 posts] 5 years
Excellent. Thanks
Dawson from Malaysia  [173 posts] 5 years
What if i have isolated 3 blobs (instead of one)? How would i show just the 3 blobs?
Dawson from Malaysia  [173 posts] 5 years
I tried using the invert feature (blob filter module) to remove the unwanted blobs one by one  until only the wanted blobs remained but it did not work. Possible bug?
Dawson from Malaysia  [173 posts] 5 years
I have attached a simple test here. I am trying to remove the blob with COG_X=363 and COG_Y=35. When i use the nearest blob filter with the following settings:

count =0
weight=0.99
invert on

Two (or more) blobs get removed instead of one. Setting weight=1 doesn't help either.

I initially assumed that in the invert mode the count specifies how many blobs are removed. However this is not the case.


 

program.robo
Anonymous 5 years
Dawson,

Yes, the invert was a little confusing in that it only applied to the threshold. I.e. if invert is selected then it would filter out all blobs that are below the specified threshold. This was not what you needed and to clarify things we added a second invert that will now operate on the count. Thus if you select a count of 1 which would normally give you back the one blob with the highest weight, inverting that will now give you back all other blobs that would have been eliminated minus the highest weight. Ie. it returns all blobs EXCEPT for the blob with the highest weight.

So in the new interface use

count = 1 [x] invert
weight = 0 [ ] invert

and you should get what you need.

v. 2.44.20 has this update.

STeven.
Dawson from Malaysia  [173 posts] 5 years
Fantastic. Thanks.
Anonymous 5 years
Steven,
I need to compare suitable size of blob, and distance blob from camera for image processing. can i use blob filter for this job?  
Dawson from Malaysia  [173 posts] 5 years
Hi STeven,

The invert feature works with absolute values (cogX and cogY). But when i use values from a variable it does not seem to work correctly i.e. you get a different result from using absolute values.

 

program.robo
Anonymous 5 years
Try

[p1] [q1]

instead. I.e. add the [] to tell RR you are using a variable.

STeven.
Dawson from Malaysia  [173 posts] 5 years
STeven,

Yes i tried that. It still did not work. The wrong blob keeps getting removed. Pls see the attached file. for p1=475 q1=47 the wrong blob gets removed.
program.robo
Anonymous 5 years
Dawson,

Ok, I think we found the issue. Try 2.44.23 and see if that works better. Keep the [] variable usage though.

STeven.

This forum thread has been closed due to inactivity (more than 4 months) or number of replies (more than 50 messages). Please start a New Post and enter a new forum thread with the appropriate title.

 New Post   Forum Index