UAT 463 Smart Robotics and Automation
Worksheet 2 MM-1 decision making and planning in the simulator
Objective
Build the behavior tree, set the cost-based threshold, plan the arm in joint space and compute the motion time
Equipment and materials
- Simulator of the MM-1 two-joint arm or a test arm
- A behavior-tree library or the classes of Example 1
- Detector scores for at least 200 images with true labels
- Computer with Python and the example code at /downloads/uat-463/
Safety
- The work is desk work in the simulator
- If testing on a real arm, use a guarded area and low speed first
- Never run a path that has not been collision-checked on a real arm
Steps
- Build the battery-swap behavior tree; measure p and t of each leaf from 30 real runs; compute the closed form against simulation
- Compare 1 to 4 retries using the measured recovery cost, then choose a count with a reason
- Collect detector scores; compute TPR and FPR at several thresholds; set the costs of a wrong pick and a skip; find the minimum-cost threshold
- Make a C-space map at 2 degree resolution, search with A*, and compare with a straight line in joint space
- Compute each segment time from the arm's limits, run it in the simulator, compare with measured time and report the cycle time of one battery swap
Record of results
| Leaf | Successes / 30 | p | Mean time (s) |
|---|---|---|---|
| Score threshold | TPR | FPR | Precision | Expected cost per detection (s) |
|---|---|---|---|---|
| Segment | Δq1 (deg) | Δq2 (deg) | Computed time (s) | Measured time in simulator (s) | Profile (triangle/trapezoid) |
|---|---|---|---|---|---|
Questions
Using p and t from Table 1 and the measured recovery cost, compare 1 to 4 retries. How many should you choose, and why does the fourth retry add so little success?
How far is the minimum-cost threshold in Table 2 from 0.5? Does it match the posterior threshold C_FP/(C_FP + C_FN), and which way would it move if a wrong pick cost twice as much?
Where does your straight joint-space line collide, how many degrees longer is the A* path, and how did the group set the safety margin using the perception error from module 1?
In Table 3, which joint sets the pace of each segment, which segments are triangles, and why does the measured time differ from the computed one?
Check before you hand in
What to hand in
- Closed-form versus simulation table and the chosen retry count
- Cost-versus-threshold plot and the chosen threshold
- C-space map and the A* path
- Table of segment times and the cycle time