Vision · University · about 35 min
Closing the loop on pixels instead of converting to metres first, and why that is more robust.
[1 mark]What distinguishes image based visual servoing (IBVS) from position based (PBVS)?
[1 mark]The forward loop should stop when a 6 cm ball is 25 cm away. What apparent width in pixels is the setpoint, to 1 decimal place, with f = 92.4?
[1 mark]The loop from the last question, with its 22.2 pixel setpoint, is pointed at a ball that is really 8 cm across. At what range does the robot stop, in cm to 1 decimal place?
[1 mark]This is the lesson's rotation law for several column errors. What does it print?
for err in (40, 10, 4, -30, 200):
rot = max(-55, min(55, 0.35 * err))
if abs(err) < 6:
rot = 0
elif abs(rot) < 17:
rot = 17 * (1 if rot > 0 else -1)
print(err, round(rot))[1 mark]Why is rotating to centre a target the most reliable visual control there is?
[1 mark]A real camera pipeline has 100 ms of latency and the robot drives at 20 cm/s. How far does it move before it acts on a frame, in cm?
[1 mark]The blob list comes back empty in the middle of an approach. What is the best behaviour?
A red ball, 6 cm across, is off to the robot's right and the robot is not facing it. Drive up and stop about 25 cm away, controlling rotation from the blob's column and forward speed from its apparent width. Plot cx and width, and print width:, the apparent width you stopped at. Neither distance() nor position() is allowed.
from bugbot import *
connect()
F, R = 92.4, 3.0
STANDOFF = 25.0
set_cv("blob", "red")
wait(0.3)Plan your program here, then type it in and press Run.
cx plot. Where does it start to ring?cx. How much gain can the loop take now?