0
$\begingroup$

Rosanswers logo

Hi there,

I was trying to use this pkg ar_track_alvar to detect a tag, and I found out that it keeps recognizing random things as tags. So I want to filter those wrong targets out by using the code that the marker contains, but I couldn't find anything related to the ID/number in any rostopic, does this mean the node isn't decoding the marker?

Does anyone have any idea about it?

Thank you in advance!

Best Regards

Updates

  • if I add code on, the tag looks like this in simulation image description
  • about false positive: when the camera is heading to a wall with 3 gray patches(without any code on them) image description
  • and this is what the topic /ARmarker_points shows image description

Originally posted by zihao on ROS Answers with karma: 33 on 2020-01-09

Post score: 2


Original comments

Comment by PeteBlackerThe3rd on 2020-01-09:
Can you show us your code and images of the tags that you're using. I've given you enough karma to do this now. ar_track_alvar is definitely capable identifying specific markers and I've never seen it detect a false positive. We'll need to know some more information about how you're using it before we can help you though.

Comment by zihao on 2020-01-10:
@PeteBlackerThe3rd Hi! Thank you for replying, and I'm using this pkg in a simulation, the robot is running in gazebo. I just launched ar_track_alvar with a launch file, nothing special. And the pix are above, please let me know if you need some more information.

Comment by zihao on 2020-01-10:
And one problem solved: the marker is actually being decoded and published to rostopic "/ar_pose_marker" as member "id" in rosmsg type "ar_track_alvar_msgs/AlvarMarkers"! But I wrongly chose "gray color" as the background of tag code, that's why I kept receiving random numbers as "id". The problem of false positive remains though.

Comment by PeteBlackerThe3rd on 2020-01-10:
The bright white color of your walls is probably causing most of your problems. ar_track_alvar thresholds the camera image into a binary image before trying to detect the markers. So unless the white areas of the markers are close to the brightest areas in the image this won't work very well.

Try changing the walls to a darker tone or color and see if that helps.

Comment by zihao on 2020-01-13:
Yes, that's the problem there, I fixed this by applying exact white color in markers, and all those false positives could be filtered out by using 'id's of markers. Thx Pete!

Comment by PeteBlackerThe3rd on 2020-01-13:
Great, glad you got it working. If you could accept my answer below, then other users will be able to see that your question has a solution. Thanks.

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Thanks for posting the images, I think I can see the problem now.

The bright white color of your walls is probably causing of your problems. ar_track_alvar thresholds the camera image into a binary image before trying to detect the markers. So unless the white areas of the markers are close to the brightest areas in the image this won't work very well.

Try changing the walls to a darker tone or color and see if that helps.


Originally posted by PeteBlackerThe3rd with karma: 9529 on 2020-01-13

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.