Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Finishing release 4.2a5 #1099

Merged
merged 99 commits into from
Feb 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
99 commits
Select commit Hold shift + click to select a range
0814efa
expose some iSAM2/FixedLagSmoothing functionality for the bindings
senselessDev Jan 22, 2022
bcbd26c
use direct memeber access for ISAM2Params
senselessDev Jan 22, 2022
3053008
use default for parameter instead of overloading
senselessDev Jan 22, 2022
2a17280
Merge remote-tracking branch 'upstream/develop' into develop
senselessDev Jan 24, 2022
41384d1
Update slam.i
johnwlambert Jan 26, 2022
8ba9ae5
fix typo
johnwlambert Jan 26, 2022
b7a502e
fix typo
johnwlambert Jan 26, 2022
bd4effb
Merge remote-tracking branch 'upstream/develop' into develop
senselessDev Jan 26, 2022
055e027
fix template bug
johnwlambert Jan 27, 2022
20622c2
add new type for vector of Rot3's
johnwlambert Jan 27, 2022
9e63911
add Rot3Vector type to specializations
johnwlambert Jan 27, 2022
6678fe0
add Rot3Vector to python/CMakeLists.txt
johnwlambert Jan 27, 2022
15c3dd4
make vector of Rot3's opaque
johnwlambert Jan 27, 2022
7530623
Merge pull request #1068 from borglab/fix/inference
dellaert Jan 27, 2022
72e4a9a
Address Akshay comments
johnwlambert Jan 27, 2022
2f3fe73
fix templated function
johnwlambert Jan 27, 2022
8a22ffa
define FindKarcherMean in .i file
johnwlambert Jan 27, 2022
e0b37ed
use Eigen::aligned_allocator
johnwlambert Jan 27, 2022
56312d9
use Eigen::aligned_allocator
johnwlambert Jan 27, 2022
d37881e
use aligned allocator for Rot3Vector
johnwlambert Jan 27, 2022
84aed90
Merge pull request #1070 from borglab/feauture/dotwriter
dellaert Jan 28, 2022
01f3fe5
Merge branch 'develop' into wrap-karcher-mean-rot3
dellaert Jan 28, 2022
55d8399
Fix wrapping
dellaert Jan 28, 2022
4db752e
Merge pull request #1072 from borglab/release/4.2a4
dellaert Jan 28, 2022
3ba6566
Merge pull request #1069 from borglab/wrap-karcher-mean-rot3
dellaert Jan 28, 2022
a82ddcc
Merge remote-tracking branch 'upstream/develop' into develop
senselessDev Jan 29, 2022
dbfc7bb
revert FactorIndices default argument to overloading for now
senselessDev Jan 29, 2022
11b2135
remove last overseen stub for bindings
senselessDev Jan 29, 2022
65d72ab
adapt examples to new direct member access
senselessDev Jan 29, 2022
40d3bad
expose iSAM2 parameter factorization enum
senselessDev Jan 29, 2022
7526329
expose iSAM object for iFLS, fix __repr__ of iFLS, bFLS
senselessDev Jan 29, 2022
88e3330
add space after commas
dellaert Jan 30, 2022
1d8a456
use const &
dellaert Jan 30, 2022
1cc6775
fix argument name
dellaert Jan 30, 2022
8e2f8a8
Better wrap of load
dellaert Jan 30, 2022
605a443
Add rangeFactor typedefs
dellaert Jan 30, 2022
656a695
wrap more eliminate variants (and dot)
dellaert Jan 30, 2022
06fb941
Expose all ordering methods
dellaert Jan 30, 2022
cd94e7d
fix python example
dellaert Jan 31, 2022
0fd49ef
Moved Sfm classes to their own files
dellaert Jan 31, 2022
3d51989
Deprecated incorrectly named methods
dellaert Jan 31, 2022
10fa738
Fix test
dellaert Jan 31, 2022
3090182
Moved loading code
dellaert Jan 31, 2022
6fbb948
moved tests
dellaert Jan 31, 2022
ea5465c
moved wrapping
dellaert Jan 31, 2022
34b8e4e
fix CI issue
dellaert Jan 31, 2022
a4fc68f
Fix DiscreteBayesTree test
dellaert Jan 31, 2022
762e809
nr -> number
dellaert Jan 31, 2022
9dfe52d
Made reading static named constructors
dellaert Jan 31, 2022
5d6b8f4
Add to wrapper
dellaert Jan 31, 2022
2e9b51a
fix typo
dellaert Jan 31, 2022
7adc989
Keys for poses/cameras are naked
dellaert Jan 31, 2022
113fbf1
Fix test
dellaert Jan 31, 2022
f04d812
Fixed print_ -> print
dellaert Jan 31, 2022
ee4c75f
Merge pull request #1077 from borglab/feature/more_wrapping
dellaert Feb 1, 2022
236dbcb
Merge pull request #1078 from borglab/feature/sfm_data
dellaert Feb 1, 2022
e4b18b5
Fix ugly printing
dellaert Feb 1, 2022
bc721e7
Merge branch 'develop' into fix/sfm_reading
dellaert Feb 1, 2022
f65bc05
bump version
dellaert Feb 1, 2022
c7fb4a1
Address comments
dellaert Feb 1, 2022
ad0d7e4
Merge pull request #1053 from senselessDev/develop
varunagrawal Feb 1, 2022
f5f5f0d
str !
dellaert Feb 1, 2022
134e828
Fixes to get matlab wrapper working properly
varunagrawal Feb 2, 2022
00d90f0
Get matlab wrapping for discrete.i working
varunagrawal Feb 2, 2022
fb1e3c3
Merge pull request #1082 from borglab/fix/sfm_reading
dellaert Feb 2, 2022
001014e
Merge pull request #1083 from borglab/fixes/wrapper
varunagrawal Feb 2, 2022
f1e11d0
Squashed 'wrap/' changes from 767a74718..56e7c0c81
varunagrawal Feb 2, 2022
35fa8c8
Merging 'master' into 'wrap'
varunagrawal Feb 2, 2022
241f7a3
Merge pull request #1084 from borglab/wrapper-update
varunagrawal Feb 3, 2022
a1fda3f
Add default constructor to PoseRotationPrior to fix serialization
ScottMcMichael Feb 4, 2022
304467c
Merge pull request #1086 from ScottMcMichael/fix_pose_rotation_prior_…
dellaert Feb 4, 2022
d449113
Add shared_ptr definition for remainder of camera objects
dwisth Feb 5, 2022
efe922b
Merge pull request #1088 from borglab/fix/add-shared-ptr-for-camera-c…
dellaert Feb 5, 2022
4a1ec24
Merge branch 'develop' into release/4.2a5
dellaert Feb 5, 2022
13092f6
Add test for dot
dellaert Feb 5, 2022
c7975be
remove stray output
dellaert Feb 5, 2022
72772b1
Add header back in
dellaert Feb 5, 2022
e5e9996
Merge pull request #1089 from borglab/fix/inference_wrapper
varunagrawal Feb 6, 2022
6f74fe4
wrap GaussianDensity::FromMeanAndStddev
dellaert Feb 6, 2022
476a253
Working with sigma in matrices
dellaert Feb 6, 2022
bc233fc
Use noiseModel for named constructors
dellaert Feb 6, 2022
f9e6282
Sampling from GaussianConditional
dellaert Feb 6, 2022
539bf70
Sampling from GaussianBayesNet
dellaert Feb 6, 2022
a25378a
wrap sampling methods
dellaert Feb 7, 2022
d2f6224
Add a static method to actually sample
dellaert Feb 7, 2022
13d370f
Make all sampling methods take random number generator
dellaert Feb 7, 2022
325613f
Fix test that used FromMeandAndStddev
dellaert Feb 7, 2022
4adba4f
Comment out non-repeatable regressions
dellaert Feb 7, 2022
c344562
Merge pull request #1091 from borglab/feature/linear_samplers
dellaert Feb 8, 2022
f278048
VectorValues html
dellaert Feb 9, 2022
fb312f9
likelihood method for GaussianConditionals
dellaert Feb 9, 2022
e175a95
add Eigen alignment macro to frobenius factor classes
varunagrawal Feb 10, 2022
a5bee15
Merge pull request #1096 from borglab/fix/FrobeniusFactor
varunagrawal Feb 10, 2022
8dcde7b
Make work with boost 1.74
dellaert Feb 12, 2022
d57e5d5
fix TBB ordering issue
dellaert Feb 12, 2022
9f2e5ab
Fix tiny issues
dellaert Feb 12, 2022
6337241
Add boost version guard
dellaert Feb 12, 2022
3e65779
Merge pull request #1095 from borglab/feature/linear_improvements
dellaert Feb 12, 2022
46f3a48
Merge branch 'develop' into release/4.2a5
dellaert Feb 12, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ endif()
set (GTSAM_VERSION_MAJOR 4)
set (GTSAM_VERSION_MINOR 2)
set (GTSAM_VERSION_PATCH 0)
set (GTSAM_PRERELEASE_VERSION "a4")
set (GTSAM_PRERELEASE_VERSION "a5")
math (EXPR GTSAM_VERSION_NUMERIC "10000 * ${GTSAM_VERSION_MAJOR} + 100 * ${GTSAM_VERSION_MINOR} + ${GTSAM_VERSION_PATCH}")

if (${GTSAM_VERSION_PATCH} EQUAL 0)
Expand Down
8 changes: 4 additions & 4 deletions examples/SFMExampleExpressions_bal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@
// Header order is close to far
#include <gtsam/inference/Symbol.h>
#include <gtsam/nonlinear/LevenbergMarquardtOptimizer.h>
#include <gtsam/slam/dataset.h> // for loading BAL datasets !
#include <gtsam/sfm/SfmData.h> // for loading BAL datasets !
#include <gtsam/slam/dataset.h>
#include <vector>

using namespace std;
Expand All @@ -46,10 +47,9 @@ int main(int argc, char* argv[]) {
if (argc > 1) filename = string(argv[1]);

// Load the SfM data from file
SfmData mydata;
readBAL(filename, mydata);
SfmData mydata = SfmData::FromBalFile(filename);
cout << boost::format("read %1% tracks on %2% cameras\n") %
mydata.number_tracks() % mydata.number_cameras();
mydata.numberTracks() % mydata.numberCameras();

// Create a factor graph
ExpressionFactorGraph graph;
Expand Down
10 changes: 5 additions & 5 deletions examples/SFMExample_bal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* -------------------------------------------------------------------------- */

/**
* @file SFMExample.cpp
* @file SFMExample_bal.cpp
* @brief Solve a structure-from-motion problem from a "Bundle Adjustment in the Large" file
* @author Frank Dellaert
*/
Expand All @@ -20,7 +20,8 @@
#include <gtsam/nonlinear/NonlinearFactorGraph.h>
#include <gtsam/nonlinear/LevenbergMarquardtOptimizer.h>
#include <gtsam/slam/GeneralSFMFactor.h>
#include <gtsam/slam/dataset.h> // for loading BAL datasets !
#include <gtsam/sfm/SfmData.h> // for loading BAL datasets !
#include <gtsam/slam/dataset.h>
#include <vector>

using namespace std;
Expand All @@ -41,9 +42,8 @@ int main (int argc, char* argv[]) {
if (argc>1) filename = string(argv[1]);

// Load the SfM data from file
SfmData mydata;
readBAL(filename, mydata);
cout << boost::format("read %1% tracks on %2% cameras\n") % mydata.number_tracks() % mydata.number_cameras();
SfmData mydata = SfmData::FromBalFile(filename);
cout << boost::format("read %1% tracks on %2% cameras\n") % mydata.numberTracks() % mydata.numberCameras();

// Create a factor graph
NonlinearFactorGraph graph;
Expand Down
10 changes: 5 additions & 5 deletions examples/SFMExample_bal_COLAMD_METIS.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@
#include <gtsam/nonlinear/NonlinearFactorGraph.h>
#include <gtsam/nonlinear/LevenbergMarquardtOptimizer.h>
#include <gtsam/slam/GeneralSFMFactor.h>
#include <gtsam/slam/dataset.h> // for loading BAL datasets !
#include <gtsam/sfm/SfmData.h> // for loading BAL datasets !
#include <gtsam/slam/dataset.h>

#include <gtsam/base/timing.h>

Expand All @@ -45,10 +46,9 @@ int main(int argc, char* argv[]) {
if (argc > 1) filename = string(argv[1]);

// Load the SfM data from file
SfmData mydata;
readBAL(filename, mydata);
SfmData mydata = SfmData::FromBalFile(filename);
cout << boost::format("read %1% tracks on %2% cameras\n") %
mydata.number_tracks() % mydata.number_cameras();
mydata.numberTracks() % mydata.numberCameras();

// Create a factor graph
NonlinearFactorGraph graph;
Expand Down Expand Up @@ -131,7 +131,7 @@ int main(int argc, char* argv[]) {

cout << "Time comparison by solving " << filename << " results:" << endl;
cout << boost::format("%1% point tracks and %2% cameras\n") %
mydata.number_tracks() % mydata.number_cameras()
mydata.numberTracks() % mydata.numberCameras()
<< endl;

tictoc_print_();
Expand Down
3 changes: 3 additions & 0 deletions gtsam/base/FastSet.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@

#pragma once

#if BOOST_VERSION >= 107400
#include <boost/serialization/library_version_type.hpp>
#endif
#include <boost/serialization/nvp.hpp>
#include <boost/serialization/set.hpp>
#include <gtsam/base/FastDefaultAllocator.h>
Expand Down
1 change: 1 addition & 0 deletions gtsam/base/serialization.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
#include <string>

// includes for standard serialization types
#include <boost/serialization/version.hpp>
#include <boost/serialization/optional.hpp>
#include <boost/serialization/shared_ptr.hpp>
#include <boost/serialization/vector.hpp>
Expand Down
4 changes: 2 additions & 2 deletions gtsam/discrete/DiscreteConditional.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -225,13 +225,13 @@ DecisionTreeFactor::shared_ptr DiscreteConditional::likelihood(

/* ****************************************************************************/
DecisionTreeFactor::shared_ptr DiscreteConditional::likelihood(
size_t parent_value) const {
size_t frontal) const {
if (nrFrontals() != 1)
throw std::invalid_argument(
"Single value likelihood can only be invoked on single-variable "
"conditional");
DiscreteValues values;
values.emplace(keys_[0], parent_value);
values.emplace(keys_[0], frontal);
return likelihood(values);
}

Expand Down
2 changes: 1 addition & 1 deletion gtsam/discrete/DiscreteConditional.h
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ class GTSAM_EXPORT DiscreteConditional
const DiscreteValues& frontalValues) const;

/** Single variable version of likelihood. */
DecisionTreeFactor::shared_ptr likelihood(size_t parent_value) const;
DecisionTreeFactor::shared_ptr likelihood(size_t frontal) const;

/**
* sample
Expand Down
19 changes: 11 additions & 8 deletions gtsam/discrete/discrete.i
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ virtual class DecisionTreeFactor : gtsam::DiscreteFactor {
string dot(
const gtsam::KeyFormatter& keyFormatter = gtsam::DefaultKeyFormatter,
bool showZero = true) const;
std::vector<std::pair<DiscreteValues, double>> enumerate() const;
std::vector<std::pair<gtsam::DiscreteValues, double>> enumerate() const;
string markdown(const gtsam::KeyFormatter& keyFormatter =
gtsam::DefaultKeyFormatter) const;
string markdown(const gtsam::KeyFormatter& keyFormatter,
Expand All @@ -97,7 +97,7 @@ virtual class DiscreteConditional : gtsam::DecisionTreeFactor {
const gtsam::Ordering& orderedKeys);
gtsam::DiscreteConditional operator*(
const gtsam::DiscreteConditional& other) const;
DiscreteConditional marginal(gtsam::Key key) const;
gtsam::DiscreteConditional marginal(gtsam::Key key) const;
void print(string s = "Discrete Conditional\n",
const gtsam::KeyFormatter& keyFormatter =
gtsam::DefaultKeyFormatter) const;
Expand Down Expand Up @@ -269,13 +269,16 @@ class DiscreteFactorGraph {
gtsam::DiscreteLookupDAG maxProduct(gtsam::Ordering::OrderingType type);
gtsam::DiscreteLookupDAG maxProduct(const gtsam::Ordering& ordering);

gtsam::DiscreteBayesNet eliminateSequential();
gtsam::DiscreteBayesNet eliminateSequential(const gtsam::Ordering& ordering);
std::pair<gtsam::DiscreteBayesNet, gtsam::DiscreteFactorGraph>
gtsam::DiscreteBayesNet* eliminateSequential();
gtsam::DiscreteBayesNet* eliminateSequential(gtsam::Ordering::OrderingType type);
gtsam::DiscreteBayesNet* eliminateSequential(const gtsam::Ordering& ordering);
pair<gtsam::DiscreteBayesNet*, gtsam::DiscreteFactorGraph*>
eliminatePartialSequential(const gtsam::Ordering& ordering);
gtsam::DiscreteBayesTree eliminateMultifrontal();
gtsam::DiscreteBayesTree eliminateMultifrontal(const gtsam::Ordering& ordering);
std::pair<gtsam::DiscreteBayesTree, gtsam::DiscreteFactorGraph>

gtsam::DiscreteBayesTree* eliminateMultifrontal();
gtsam::DiscreteBayesTree* eliminateMultifrontal(gtsam::Ordering::OrderingType type);
gtsam::DiscreteBayesTree* eliminateMultifrontal(const gtsam::Ordering& ordering);
pair<gtsam::DiscreteBayesTree*, gtsam::DiscreteFactorGraph*>
eliminatePartialMultifrontal(const gtsam::Ordering& ordering);

string dot(
Expand Down
1 change: 0 additions & 1 deletion gtsam/discrete/tests/testDiscreteBayesNet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,6 @@ TEST(DiscreteBayesNet, Dot) {
fragment.add((Either | Tuberculosis, LungCancer) = "F T T T");

string actual = fragment.dot();
cout << actual << endl;
EXPECT(actual ==
"digraph {\n"
" size=\"5,5\";\n"
Expand Down
22 changes: 11 additions & 11 deletions gtsam/discrete/tests/testDiscreteBayesTree.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -243,27 +243,27 @@ TEST(DiscreteBayesTree, Dot) {
string actual = self.bayesTree->dot();
EXPECT(actual ==
"digraph G{\n"
"0[label=\"13,11,6,7\"];\n"
"0[label=\"13, 11, 6, 7\"];\n"
"0->1\n"
"1[label=\"14 : 11,13\"];\n"
"1[label=\"14 : 11, 13\"];\n"
"1->2\n"
"2[label=\"9,12 : 14\"];\n"
"2[label=\"9, 12 : 14\"];\n"
"2->3\n"
"3[label=\"3 : 9,12\"];\n"
"3[label=\"3 : 9, 12\"];\n"
"2->4\n"
"4[label=\"2 : 9,12\"];\n"
"4[label=\"2 : 9, 12\"];\n"
"2->5\n"
"5[label=\"8 : 12,14\"];\n"
"5[label=\"8 : 12, 14\"];\n"
"5->6\n"
"6[label=\"1 : 8,12\"];\n"
"6[label=\"1 : 8, 12\"];\n"
"5->7\n"
"7[label=\"0 : 8,12\"];\n"
"7[label=\"0 : 8, 12\"];\n"
"1->8\n"
"8[label=\"10 : 13,14\"];\n"
"8[label=\"10 : 13, 14\"];\n"
"8->9\n"
"9[label=\"5 : 10,13\"];\n"
"9[label=\"5 : 10, 13\"];\n"
"8->10\n"
"10[label=\"4 : 10,13\"];\n"
"10[label=\"4 : 10, 13\"];\n"
"}");
}

Expand Down
3 changes: 3 additions & 0 deletions gtsam/geometry/Cal3Bundler.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ class GTSAM_EXPORT Cal3Bundler : public Cal3 {
public:
enum { dimension = 3 };

///< shared pointer to stereo calibration object
using shared_ptr = boost::shared_ptr<Cal3Bundler>;

/// @name Standard Constructors
/// @{

Expand Down
3 changes: 3 additions & 0 deletions gtsam/geometry/Cal3DS2.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ class GTSAM_EXPORT Cal3DS2 : public Cal3DS2_Base {
public:
enum { dimension = 9 };

///< shared pointer to stereo calibration object
using shared_ptr = boost::shared_ptr<Cal3DS2>;

/// @name Standard Constructors
/// @{

Expand Down
3 changes: 3 additions & 0 deletions gtsam/geometry/Cal3DS2_Base.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ class GTSAM_EXPORT Cal3DS2_Base : public Cal3 {
public:
enum { dimension = 9 };

///< shared pointer to stereo calibration object
using shared_ptr = boost::shared_ptr<Cal3DS2_Base>;

/// @name Standard Constructors
/// @{

Expand Down
3 changes: 3 additions & 0 deletions gtsam/geometry/Cal3Unified.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ class GTSAM_EXPORT Cal3Unified : public Cal3DS2_Base {
public:
enum { dimension = 10 };

///< shared pointer to stereo calibration object
using shared_ptr = boost::shared_ptr<Cal3Unified>;

/// @name Standard Constructors
/// @{

Expand Down
29 changes: 15 additions & 14 deletions gtsam/geometry/Rot3.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,14 @@

namespace gtsam {

/**
* @brief A 3D rotation represented as a rotation matrix if the preprocessor
* symbol GTSAM_USE_QUATERNIONS is not defined, or as a quaternion if it
* is defined.
* @addtogroup geometry
* \nosubgrouping
*/
class GTSAM_EXPORT Rot3 : public LieGroup<Rot3,3> {

private:
/**
* @brief Rot3 is a 3D rotation represented as a rotation matrix if the
* preprocessor symbol GTSAM_USE_QUATERNIONS is not defined, or as a quaternion
* if it is defined.
* @addtogroup geometry
*/
class GTSAM_EXPORT Rot3 : public LieGroup<Rot3, 3> {
private:

#ifdef GTSAM_USE_QUATERNIONS
/** Internal Eigen Quaternion */
Expand All @@ -67,8 +65,7 @@ namespace gtsam {
SO3 rot_;
#endif

public:

public:
/// @name Constructors and named constructors
/// @{

Expand All @@ -83,7 +80,7 @@ namespace gtsam {
*/
Rot3(const Point3& col1, const Point3& col2, const Point3& col3);

/** constructor from a rotation matrix, as doubles in *row-major* order !!! */
/// Construct from a rotation matrix, as doubles in *row-major* order !!!
Rot3(double R11, double R12, double R13,
double R21, double R22, double R23,
double R31, double R32, double R33);
Expand Down Expand Up @@ -567,6 +564,9 @@ namespace gtsam {
#endif
};

/// std::vector of Rot3s, mainly for wrapper
using Rot3Vector = std::vector<Rot3, Eigen::aligned_allocator<Rot3> >;

/**
* [RQ] receives a 3 by 3 matrix and returns an upper triangular matrix R
* and 3 rotation angles corresponding to the rotation matrix Q=Qz'*Qy'*Qx'
Expand All @@ -585,5 +585,6 @@ namespace gtsam {

template<>
struct traits<const Rot3> : public internal::LieGroup<Rot3> {};
}

} // namespace gtsam

16 changes: 8 additions & 8 deletions gtsam/inference/BayesTree-inst.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ namespace gtsam {
/* ************************************************************************* */
template <class CLIQUE>
void BayesTree<CLIQUE>::dot(std::ostream& s, sharedClique clique,
const KeyFormatter& indexFormatter,
const KeyFormatter& keyFormatter,
int parentnum) const {
static int num = 0;
bool first = true;
Expand All @@ -104,10 +104,10 @@ namespace gtsam {
std::string parent = out.str();
parent += "[label=\"";

for (Key index : clique->conditional_->frontals()) {
if (!first) parent += ",";
for (Key key : clique->conditional_->frontals()) {
if (!first) parent += ", ";
first = false;
parent += indexFormatter(index);
parent += keyFormatter(key);
}

if (clique->parent()) {
Expand All @@ -116,18 +116,18 @@ namespace gtsam {
}

first = true;
for (Key sep : clique->conditional_->parents()) {
if (!first) parent += ",";
for (Key parentKey : clique->conditional_->parents()) {
if (!first) parent += ", ";
first = false;
parent += indexFormatter(sep);
parent += keyFormatter(parentKey);
}
parent += "\"];\n";
s << parent;
parentnum = num;

for (sharedClique c : clique->children) {
num++;
dot(s, c, indexFormatter, parentnum);
dot(s, c, keyFormatter, parentnum);
}
}

Expand Down
Loading