Go to the documentation of this file.
27 for (
size_t i = 0;
i < cs.size();
i++) {
28 string name =
"v" + std::to_string(
i);
41 cs.insert(begin(),
end());
52 std::cout << (
s.empty() ?
"" :
s +
" ") << std::endl;
53 for (
auto&& dkey : *
this) {
60 if (this->
size() != other.size()) {
64 for (
size_t i = 0;
i < this->
size();
i++) {
65 if (this->at(
i).first !=
other.at(
i).first ||
66 this->at(
i).second !=
other.at(
i).second) {
const Symbol key1('v', 1)
Annotation for function names.
DiscreteKeys is a set of keys that can be assembled using the & operator.
bool equals(const DiscreteKeys &other, double tol=0) const
Check equality to another DiscreteKeys object.
FastVector< Key > KeyVector
Define collection type once and for all - also used in wrappers.
std::map< Key, size_t > cardinalities() const
Return a map from index to cardinality.
KeyFormatter DefaultKeyFormatter
Assign default key formatter.
DiscreteKeys()
Constructor for serialization.
const Symbol key2('v', 2)
std::function< std::string(Key)> KeyFormatter
Typedef for a function to format a key, i.e. to convert it to a string.
KeyVector indices() const
Return a vector of indices.
specialized key for discrete variables
const gtsam::Symbol key('X', 0)
std::pair< Key, size_t > DiscreteKey
void print(const std::string &s="", const KeyFormatter &keyFormatter=DefaultKeyFormatter) const
Print the keys and cardinalities.
static const EIGEN_DEPRECATED end_t end
DiscreteKeys operator&(const DiscreteKey &key1, const DiscreteKey &key2)
Create a list from two keys.
gtsam
Author(s):
autogenerated on Sat Nov 16 2024 04:02:13