Commit Graph

45 Commits (6248db54dd876b2643c82194877d1140daf9d819)

Author SHA1 Message Date
Kai Ni 6248db54dd distribute the factors along the junction tree 2010-07-09 07:31:15 +00:00
Kai Ni f456f3d014 add missing #pragma once to many inl.h files 2010-07-07 23:00:03 +00:00
Kai Ni 574936bb5a added profiling flags
added draft for junction tree
2010-07-07 21:41:50 +00:00
Kai Ni 70adcb26c9 the lapack version of householder 2010-06-30 15:57:12 +00:00
Kai Ni 9ddeaa91c6 linking to SparseQR as a shared library results in a performance hit. The proper way is to link the static library.
add prepareLinear to NonlinearOptimizer so that some computation can be cached and does not happen every time.
2010-06-05 20:46:16 +00:00
Kai Ni ebfd979cc4 fixed a bug in SPQR calling, and the Victoria Park data-set just flies 2010-06-01 02:20:10 +00:00
Kai Ni d6267c0440 a preliminary version of SparseQR routines that passes the unit tests but has slightly different results as the old method when optimizing large nonlinear problems. 2010-05-31 02:21:37 +00:00
Kai Ni e6e93475cf added sizeOfA 2010-05-26 08:05:31 +00:00
Kai Ni c70e818a79 added a variant of getOrdering 2010-05-24 08:57:22 +00:00
Alex Cunningham e8979dafad Renabled BLAS using ATLAS for Linux, fixed a variety of annoying warnings 2010-05-21 17:59:26 +00:00
Kai Ni b33ec1a34c make no sense to call findAndRemoveFactors on the same key twice 2010-04-21 22:08:41 +00:00
Alex Cunningham f8c4e1fe27 Fixed bug in unit test causing crashes, altered corner case test for column insertion 2010-02-24 18:09:15 +00:00
Frank Dellaert 3247751b5d Major check-in: there are now two interchangeable implementations of VectorConfig.
VectorMap uses a straightforward stl::map of Vectors. It has O(log n)
insert and access, and is fairly fast at both. However, it has high overhead
for arithmetic operations such as +, scale, axpy etc...

VectorBTree uses a functional BTree as a way to access SubVectors
in an ordinary Vector. Inserting is O(n) and much slower, but accessing,
is O(log n) and might be a bit slower than VectorMap. Arithmetic operations
are blindingly fast, however. The cost is it is not as KISS as VectorMap.

Access to vectors is now exclusively via operator[]
Vector access in VectorMap is via a Vector reference
Vector access in VectorBtree is via the SubVector type (see Vector.h)

Feb 16 2010: FD: I made VectorMap the default, because I decided to try
and speed up conjugate gradients by using Sparse FactorGraphs all the way.
2010-02-17 03:29:12 +00:00
Richard Roberts 4408eaf6f4 Added FactorGraph::checkGraphConsistency() to check for consistency between the variables->factors and factors->variables maps, and a unit test that tests the replace function including checking consistency. 2010-02-13 01:29:19 +00:00
Alex Cunningham 87cc573d34 Added a new combine process for GaussianFactors that allocates only one matrix when combining, rather than using append factor to make a large number of smaller matrices. There is a flag to switch between these modes, which currently defaults to the older approach. Currently, there does not appear to be a performance improvement, however. 2010-01-31 17:49:33 +00:00
Alex Cunningham 59c7ce7e29 Integrated householder-based QR into NoiseModel. Note that the examples for GFG have changed to ensure that they are actually a linearized version of the nonlinear example. 2010-01-27 04:39:35 +00:00
Frank Dellaert 351cdd18c2 case change: SharedGaussian and SharedDiagonal are now classes with their own header file. Needed for MATLAB TORO hail Mary 2010-01-22 17:36:57 +00:00
Alex Cunningham 5f588031bc Merged NoiseQR back into trunk 2010-01-20 18:32:48 +00:00
Alex Cunningham 88e465910a SQP tests and implementation now use the new Key system 2010-01-19 05:33:44 +00:00
Richard Roberts aef0b42562 Refactoring to use a new Symbol key instead of strings in Bayes*, Gaussian*, Ordering, Symbolic*, VectorConfig. Renamed existing type-checking key Symbol<C,T> to TypedSymbol<C,T> 2010-01-17 19:34:57 +00:00
Chris Beall a956c1a8be svn restored from 1733.
this commit updates gtsam to version 1774, which now appears as 1734.
2010-01-16 01:16:59 +00:00
Kai Ni 3c66861790 fix the graph related functions in FactorGraph as well as its unit tests 2010-01-13 23:59:46 +00:00
Frank Dellaert 93465945e9 Large gtsam refactoring
To support faster development *and* better performance Richard and I pushed through a large refactoring of NonlinearFactors.

The following are the biggest changes:

1) NonLinearFactor1 and NonLinearFactor2 are now templated on Config, Key type, and X type, where X is the argument to the measurement function.

2) The measurement itself is no longer kept in the nonlinear factor. Instead, a derived class (see testVSLAMFactor, testNonlinearEquality, testPose3Factor etc...) has to implement a function to compute the errors, "evaluateErrors". Instead of (h(x)-z), it needs to return (z-h(x)), so Ax-b is an approximation of the error. IMPORTANT: evaluateErrors needs - if asked - *combine* the calculation of the function value h(x) and the derivatives dh(x)/dx. This was a major performance issue. To do this, boost::optional<Matrix&> arguments are provided, and tin EvaluateErrors you just  says something like

	if (H) *H = Matrix_(3,6,....);

3) We are no longer using int or strings for nonlinear factors. Instead, the preferred key type is now Symbol, defined in Key.h. This is both fast and cool: you can construct it from an int, and cast it to a strong. It also does type checking: a Symbol<Pose3,'x'> will not match a Symbol<Pose2,'x'>

4) minor: take a look at LieConfig.h: it help you avoid writing a lot of code bu automatically creating configs for a certain type. See e.g. Pose3Config.h. A "double" LieConfig is on the way - Thanks Richard and Manohar !
2010-01-13 22:25:03 +00:00
Kai Ni d4f92c7bb6 pass FactorGraph as reference into split 2010-01-08 20:27:10 +00:00
Kai Ni 06b7f8ee04 add split to FactorGraph 2010-01-08 19:07:46 +00:00
Kai Ni 6298a45050 use prim algorithm instead of kruskal for finding MST, which yields the parent map. 2010-01-07 06:25:54 +00:00
Kai Ni 9845a5ae37 add findMinimumSpanningTree to FactorGraph 2010-01-06 11:15:37 +00:00
Frank Dellaert cd644e75a5 GaussianBayesNet::matrix now properly divides in sigmas 2010-01-05 14:14:49 +00:00
Frank Dellaert 8d4a029665 rhs method 2009-12-28 18:46:01 +00:00
Frank Dellaert d9fd502656 moved CG tests from testGFG to testIterative 2009-12-28 09:44:30 +00:00
Frank Dellaert 1fac98b4cb Errors:dot, VectorConfig::operator*/-, as a result Conjugate Gradient Descent template now works for factor graphs 2009-12-28 08:15:09 +00:00
Frank Dellaert 266fc56dea Gradient using new operator^ and errors method 2009-12-27 12:13:31 +00:00
Frank Dellaert 7d1428de60 Added Errors class and operator* for GaussianFactor and GaussianFactorGraph. Also moved a few functions to cpp. 2009-12-26 22:48:41 +00:00
Frank Dellaert 6614434b83 System version of CG 2009-12-26 21:25:45 +00:00
Frank Dellaert f3965b07ca Conjugate Gradient Descent template (in progress) 2009-12-26 15:06:54 +00:00
Frank Dellaert c38683cd64 Sped up and fixed (?) sparse 2009-12-12 06:18:29 +00:00
Frank Dellaert 99533f286f Vanilla Conjugate Gradient Descent works 2009-12-12 04:44:34 +00:00
Viorela Ila 8a9f05059c implement getOrdering_ to work in matlab 2009-12-11 22:53:48 +00:00
Viorela Ila 76b55aba7d linearize method for Pose2Graph works in Matlab!! 2009-12-11 21:34:08 +00:00
Frank Dellaert 726858145a gradient descent (with fixed nr. of iterations, choosing optimal step size) 2009-12-11 04:59:05 +00:00
Frank Dellaert 4af2382105 Gradient at solution is zero ! 2009-12-11 02:59:09 +00:00
Frank Dellaert e7a912bd3b Calculate gradient of factor graph objective function. 2009-12-10 20:19:15 +00:00
Frank Dellaert 55e85fd8a5 [involves] checks whether variable with that key is involved in any factor 2009-11-20 05:14:34 +00:00
Alex Cunningham c7b86cec97 Renamed ConditionalGaussian -> GaussianConditional 2009-11-12 16:41:18 +00:00
Alex Cunningham 77a1754b69 Renamed LinearFactor -> GaussianFactor, LinearFactorGraph -> GaussianFactorGraph 2009-11-12 16:16:32 +00:00