diff --git a/README.md b/README.md index b2abf0f30..b3deef4c9 100644 --- a/README.md +++ b/README.md @@ -55,6 +55,9 @@ Optional prerequisites - used automatically if findable by CMake: GTSAM 4 introduces several new features, most notably Expressions and a Python toolbox. It also introduces traits, a C++ technique that allows optimizing with non-GTSAM types. That opens the door to retiring geometric types such as Point2 and Point3 to pure Eigen types, which we also do. A significant change which will not trigger a compile error is that zero-initializing of Point2 and Point3 is deprecated, so please be aware that this might render functions using their default constructor incorrect. + There is a flag `GTSAM_ALLOW_DEPRECATED_SINCE_V43` for newly deprecated methods since the 4.3 release, which is on by default, allowing anyone to just pull version 4.3 and compile. + + ## Wrappers We provide support for [MATLAB](matlab/README.md) and [Python](python/README.md) wrappers for GTSAM. Please refer to the linked documents for more details. diff --git a/gtsam/discrete/DiscreteFactorGraph.h b/gtsam/discrete/DiscreteFactorGraph.h index f4d1a1833..4070af2f5 100644 --- a/gtsam/discrete/DiscreteFactorGraph.h +++ b/gtsam/discrete/DiscreteFactorGraph.h @@ -127,6 +127,9 @@ class GTSAM_EXPORT DiscreteFactorGraph template DiscreteFactorGraph(const FactorGraph& graph) : Base(graph) {} + /// Destructor + virtual ~DiscreteFactorGraph() {} + /// @name Testable /// @{ diff --git a/gtsam/nonlinear/Values-inl.h b/gtsam/nonlinear/Values-inl.h index 59ec2089d..b6eca8b99 100644 --- a/gtsam/nonlinear/Values-inl.h +++ b/gtsam/nonlinear/Values-inl.h @@ -27,8 +27,6 @@ #include #include -#include // Only so Eclipse finds class definition - namespace gtsam { diff --git a/gtsam/sfm/SfmTrack.h b/gtsam/sfm/SfmTrack.h index bdfa79cef..f8c4112f3 100644 --- a/gtsam/sfm/SfmTrack.h +++ b/gtsam/sfm/SfmTrack.h @@ -81,13 +81,12 @@ struct GTSAM_EXPORT SfmTrack2d { * @returns boolean result of the validation. */ bool hasUniqueCameras() const { - std::vector track_cam_indices; + std::vector cameraIndices; for (auto& measurement : measurements) { - track_cam_indices.emplace_back(measurement.first); + cameraIndices.emplace_back(measurement.first); } - auto i = - std::adjacent_find(track_cam_indices.begin(), track_cam_indices.end()); - bool all_cameras_unique = (i == track_cam_indices.end()); + auto i = std::adjacent_find(cameraIndices.begin(), cameraIndices.end()); + bool all_cameras_unique = (i == cameraIndices.end()); return all_cameras_unique; } diff --git a/python/gtsam/preamble/inference.h b/python/gtsam/preamble/inference.h index d07a75f6f..56a07cfdd 100644 --- a/python/gtsam/preamble/inference.h +++ b/python/gtsam/preamble/inference.h @@ -10,3 +10,5 @@ * Without this they will be automatically converted to a Python object, and all * mutations on Python side will not be reflected on C++. */ + +#include