gtsam_unstable
geometry
Event.cpp
Go to the documentation of this file.
1
/* ----------------------------------------------------------------------------
2
3
* GTSAM Copyright 2010, 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
20
#include <
gtsam_unstable/geometry/Event.h
>
21
#include <iostream>
22
23
namespace
gtsam
{
24
25
/* ************************************************************************* */
26
void
Event::print
(
const
std::string&
s
)
const
{
27
std::cout <<
s
<<
"{'time':"
<<
time_
28
<<
", 'location': "
<<
location_
.transpose() <<
"}"
;
29
}
30
31
/* ************************************************************************* */
32
bool
Event::equals
(
const
Event
&
other
,
double
tol
)
const
{
33
return
std::abs
(
time_
-
other
.time_) <
tol
&&
34
traits<Point3>::Equals
(
location_
,
other
.location_,
tol
);
35
}
36
37
/* ************************************************************************* */
38
39
}
// namespace gtsam
s
RealScalar s
Definition:
level1_cplx_impl.h:126
gtsam::Event::location_
Point3 location_
Location at time event was generated.
Definition:
Event.h:39
gtsam::Event::time_
double time_
Time event was generated.
Definition:
Event.h:38
Event.h
Space-time event.
gtsam::Event
Definition:
Event.h:37
gtsam
traits
Definition:
SFMdata.h:40
gtsam::traits
Definition:
Group.h:36
gtsam::Event::equals
bool equals(const Event &other, double tol=1e-9) const
Definition:
Event.cpp:32
gtsam::tol
const G double tol
Definition:
Group.h:79
abs
#define abs(x)
Definition:
datatypes.h:17
pybind_wrapper_test_script.other
other
Definition:
pybind_wrapper_test_script.py:42
gtsam::Event::print
void print(const std::string &s="") const
Definition:
Event.cpp:26
gtsam
Author(s):
autogenerated on Fri Nov 1 2024 03:32:30