gtsam 4.2.0
gtsam
Loading...
Searching...
No Matches
GraphvizFormatting.h
Go to the documentation of this file.
1/* ----------------------------------------------------------------------------
2
3 * GTSAM Copyright 2010-2021, Georgia Tech Research Corporation,
4 * Atlanta, Georgia 30332-0415
5 * All Rights Reserved
6 * Authors: Frank Dellaert, et al. (see THANKS for the full author list)
7
8 * See LICENSE for the license information
9
10 * -------------------------------------------------------------------------- */
11
19#pragma once
20
22
23namespace gtsam {
24
25class Values;
26class Value;
27
32struct GTSAM_EXPORT GraphvizFormatting : public DotWriter {
34 enum Axis { X, Y, Z, NEGX, NEGY, NEGZ };
35
40 double scale;
43
47 : paperHorizontalAxis(Y),
48 paperVerticalAxis(X),
49 scale(1),
50 mergeSimilarFactors(false) {}
51
52 // Find bounds
53 Vector2 findBounds(const Values& values, const KeySet& keys) const;
54
56 boost::optional<Vector2> extractPosition(const Value& value) const;
57
59 boost::optional<Vector2> variablePos(const Values& values, const Vector2& min,
60 Key key) const;
61
63 boost::optional<Vector2> factorPos(const Vector2& min, size_t i) const;
64};
65
66} // namespace gtsam
Graphviz formatter.
Global functions in a separate testing namespace.
Definition chartTesting.h:28
std::uint64_t Key
Integer nonlinear key type.
Definition types.h:100
This is the base class for any type to be stored in Values.
Definition Value.h:37
DotWriter is a helper class for writing graphviz .dot files.
Definition DotWriter.h:35
Formatting options and functions for saving a NonlinearFactorGraph instance in GraphViz format.
Definition GraphvizFormatting.h:32
Axis
World axes to be assigned to paper axes.
Definition GraphvizFormatting.h:34
Axis paperVerticalAxis
The world axis assigned to the vertical paper axis.
Definition GraphvizFormatting.h:38
GraphvizFormatting()
Default constructor sets up robot coordinates.
Definition GraphvizFormatting.h:46
bool mergeSimilarFactors
Merge multiple factors that have the same connectivity.
Definition GraphvizFormatting.h:41
double scale
Scale all positions to reduce / increase density.
Definition GraphvizFormatting.h:40
Axis paperHorizontalAxis
The world axis assigned to the horizontal paper axis.
Definition GraphvizFormatting.h:36
A non-templated config holding any types of Manifold-group elements.
Definition Values.h:65
In nonlinear factors, the error function returns the negative log-likelihood as a non-linear function...