iCub-main
matrixTransformation.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2013 iCub Facility - Istituto Italiano di Tecnologia
3  * Author: Ugo Pattacini
4  * email: ugo.pattacini@iit.it
5  * Permission is granted to copy, distribute, and/or modify this program
6  * under the terms of the GNU General Public License, version 2 or any
7  * later version published by the Free Software Foundation.
8  *
9  * A copy of the license can be found at
10  * http://www.robotcub.org/icub/license/gpl.txt
11  *
12  * This program is distributed in the hope that it will be useful, but
13  * WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
15  * Public License for more details
16 */
17 
29 #ifndef __ICUB_OPT_MATRIXTRANSFORMATION_H__
30 #define __ICUB_OPT_MATRIXTRANSFORMATION_H__
31 
32 #include <yarp/os/all.h>
33 #include <yarp/sig/all.h>
34 
35 namespace iCub
36 {
37 
38 namespace optimization
39 {
40 
48 {
49 public:
56  virtual void setBounds(const yarp::sig::Matrix &min, const yarp::sig::Matrix &max) = 0;
57 
65  virtual bool addPoints(const yarp::sig::Vector &p0, const yarp::sig::Vector &p1) = 0;
66 
72  virtual size_t getNumPoints() const = 0;
73 
81  virtual void getPoints(std::deque<yarp::sig::Vector> &p0, std::deque<yarp::sig::Vector> &p1) const = 0;
82 
86  virtual void clearPoints() = 0;
87 
94  virtual bool setInitialGuess(const yarp::sig::Matrix &M) = 0;
95 
102  virtual bool setCalibrationOptions(const yarp::os::Property &options) { return true; }
103 
111  virtual bool calibrate(yarp::sig::Matrix &M, double &error) = 0;
112 
117 };
118 
119 }
120 
121 }
122 
123 #endif
124 
125 
A class interface to deal with the problem of determining the matrix transformation between two sets ...
virtual void clearPoints()=0
Clear the internal database of 3D points.
virtual void setBounds(const yarp::sig::Matrix &min, const yarp::sig::Matrix &max)=0
Allow specifying the minimum and maximum bounds of the elements belonging to the transformation.
virtual bool addPoints(const yarp::sig::Vector &p0, const yarp::sig::Vector &p1)=0
Add to the internal database the 3D-point p0 and the corresponding 3D-point p1.
virtual bool setInitialGuess(const yarp::sig::Matrix &M)=0
Allow specifiying the initial guess for the matrix transformation we seek for.
virtual bool setCalibrationOptions(const yarp::os::Property &options)
Allow setting further options used during calibration.
virtual bool calibrate(yarp::sig::Matrix &M, double &error)=0
Perform optimization to determine the matrix transformation.
virtual void getPoints(std::deque< yarp::sig::Vector > &p0, std::deque< yarp::sig::Vector > &p1) const =0
Retrieve copies of the database of 3D-points pairs.
virtual size_t getNumPoints() const =0
Return the number of 3D-points pairs currently contained into the internal database.
This file contains the definition of unique IDs for the body parts and the skin parts of the robot.
const FSC max
Definition: strain.h:48
const FSC min
Definition: strain.h:49