This module finds the tool dimension employing nonlinear optimization.
This module finds the tool dimension employing nonlinear optimization.
Description
Through an active exploration of the tool held in the robot hand a set of relevant data is collected, including hand position in 3D space, eye's frame and pixels of the tool tip as acquired by vision algorithms. A nonlinear optimization is then exploited to find out the best estimate of the tool dimensions with respect to the hand reference frame.
Libraries
- YARP libraries.
- IPOPT library.
- OpenCV library.
Parameters
–robot robot
- Select the robot to connect to.
–name name
- Select the stem-name of the module used to open up ports. By default name is karmaToolFinder.
–arm type
- Select the default arm ("left" or "right") used for the data acquisition.
–eye type
- Select the default eye ("left" or "right") used for the data acquisition.
Ports Accessed
Assume that iCubInterface (with ICartesianControl interface implemented) is running.
Ports Created
- /karmaToolFinder/rpc receives the information to manage the data acquisition and optimization phase:
- Enable: [enable].
Start the data acquisition phase.
- Disable: [disable].
Terminate the data acquisition phase.
- Num: [num].
Retrieve the current number of input-output pairs used for the optimization. The reply is [ack] num.
- Clear: [clear].
Clear the current content of input-output pairs database.
- Select: [select] arm eye.
Select the robot sources in terms of arm and eye used during the data acquisition.
- Find: [find].
Execute the optimization over the current database of input-output pairs. The reply is [ack] x y z including the tool dimensions given wrt hand reference frame.
- Show: [show] x y z.
Enable the visualization of a tool with the dimensions specified by the user. The reply is [ack] or [nack].
- Tip: [tip].
Retrieve the tool tip as projected in the image plane. The reply is [ack] u v or [nack].
- /karmaToolFinder/in receives the position of the tool tip in the image plane.
- /karmaToolFinder/img:i receives images from the camera.
- /karmaToolFinder/img:o streams out images with superimposed information on the tool.
- /karmaToolFinder/log:o streams out a complete set of data used during the acquisition.
Tested OS
Windows, Linux
- Author
- Ugo Pattacini