| User Documentation |
| Centre for Vision, Speech & Signal Processing |
| DEVELOP | IN NAMESPACE | AMMA TREE ROOT | AMMA SEARCH | AMMA HOME |
PUBLIC
NRegisC::~NRegisC(void)
NRegisC::NRegisC(CorrSetC,SArray1dC
NRegisC::SetExpectedRTs(SArray1dC
NRegisC::InitView(int,RigidTransC,Vector3dC,double,double)
NRegisC::InitPairwise(void)
NRegisC::Solve(void)
NRegisC::Answer(int)
NRegisC::FinalCost(void)
NRegisC::FinalCost(SArray1dC
| NRegisC | |
| N-Point Set Registration. | |
| include | "amma/NRegis.hh" |
| User Level: | Default |
| Library: | Regis |
| Example: | testcom.cc |
| Section: | 3D Surface.Registration |
| In Scope: | std |
Comments:
Suppose we have nviews rigid objects, and ncorres set of pairwise point correspondences. Suppose we know roughly the rigid body transforms needed to align them. This routine aligns them precisely.
Specifically it minimizes the cost \sum_mu \sum_i w_i (y^a_i-y^b_i)^2
The initial data is supplied with initial guesses The results are the transforms necessary to move the raw data into alignment but keeping the rt[0] null. [ So the answer is the same no matter what the guess. ]
If there are only two objects, the problem can be solved exactly, see RegisC, based on Kanatani.
The problem is basically solved by gradient descent on the cost function. It turns out that the gradient descent depends on the origin of the coordinate system. We allow this to be specified by the quantity center of mass. For a fast stable solution the center of mass should be near the center of the object.
Notes on numerical accuracy
---------------------------
Because of how it is computed the ShortCost becomes inaccurate at about 1e-7 relative error. The LongCost does not but takes order N time to compute.
Quality Controlled Euler stepping
---------------------------------
In this problem we compute maxdiff. This is the error between 2 steps and one divided by ascale and dscale. We require it to be less than 20% - [the variable maxerror].
In the case that the stepsize is extremely small the denominator is set to 1e-20 the meaningful scale. This means that the step size cannot grow arbitrarily large.
The output error is the actual step divided by a meaningful scale such as boxdiag or 2PI.
Tracing
-------
The QC step returns outerror=MAX(dscale/boxdiag, ascale/2/AMMA_PI)
dscale and ascale are the distance and angle moved in the one big step but may not fall below dscale=1e-20 * boxdiag, ascale=1e-20 * 2*AMMA_PI;
Good Convergence
----------------
... is not guarateed. However the following steps will aid performance:
- A center of mass in the middle of the view
- Set mass=1
- Set moment=mass * R^2
Additional Notes The constructor allows guesses to be passed which will then be used to initialise the rigid transforms associated with each view.
The expected rigid transforms can be passed via the function SetExpectedRTs, which is only used for the calculation of delta theta.
Variables:| Programmer: Andrew Stoddart, Documentation by CxxDoc: Tue Mar 20 10:48:08 2001 |