added cout style print statements for similarity
parent
226f6ad0ce
commit
a4fac2ab62
|
@ -100,6 +100,12 @@ void Similarity3::print(const std::string& s) const {
|
||||||
std::cout << "s: " << scale() << std::endl;
|
std::cout << "s: " << scale() << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::ostream &operator<<(std::ostream &os, const Similarity3& p) {
|
||||||
|
os << "[" << p.rotation().xyz().transpose() << " " << p.translation().vector().transpose() << " " <<
|
||||||
|
p.scale() << "]\';";
|
||||||
|
return os;
|
||||||
|
}
|
||||||
|
|
||||||
Similarity3 Similarity3::ChartAtOrigin::Retract(const Vector7& v, ChartJacobian H) {
|
Similarity3 Similarity3::ChartAtOrigin::Retract(const Vector7& v, ChartJacobian H) {
|
||||||
// Will retracting or localCoordinating R work if R is not a unit rotation?
|
// Will retracting or localCoordinating R work if R is not a unit rotation?
|
||||||
// Also, how do we actually get s out? Seems like we need to store it somewhere.
|
// Also, how do we actually get s out? Seems like we need to store it somewhere.
|
||||||
|
|
|
@ -70,6 +70,8 @@ public:
|
||||||
/// Print with optional string
|
/// Print with optional string
|
||||||
void print(const std::string& s) const;
|
void print(const std::string& s) const;
|
||||||
|
|
||||||
|
GTSAM_EXPORT friend std::ostream &operator<<(std::ostream &os, const Similarity3& p);
|
||||||
|
|
||||||
/// @}
|
/// @}
|
||||||
/// @name Group
|
/// @name Group
|
||||||
/// @{
|
/// @{
|
||||||
|
|
Loading…
Reference in New Issue