Namespaces | Functions | Variables
testHybridGaussianConditional.cpp File Reference

Unit tests for HybridGaussianConditional class. More...

#include <gtsam/discrete/DecisionTree.h>
#include <gtsam/discrete/DiscreteKey.h>
#include <gtsam/discrete/DiscreteValues.h>
#include <gtsam/hybrid/HybridGaussianConditional.h>
#include <gtsam/hybrid/HybridGaussianFactor.h>
#include <gtsam/hybrid/HybridValues.h>
#include <gtsam/inference/Symbol.h>
#include <gtsam/linear/GaussianConditional.h>
#include <memory>
#include <vector>
#include <CppUnitLite/TestHarness.h>
Include dependency graph for testHybridGaussianConditional.cpp:

Go to the source code of this file.

Namespaces

 equal_constants
 
 mode_dependent_constants
 

Functions

int main ()
 
static const DiscreteKey mode (modeKey, 2)
 
 TEST (HybridGaussianConditional, ContinuousParents)
 
 TEST (HybridGaussianConditional, Error)
 Check error. More...
 
 TEST (HybridGaussianConditional, Error2)
 Check error with mode dependent constants. More...
 
 TEST (HybridGaussianConditional, Invariants)
 Check that invariants hold. More...
 
 TEST (HybridGaussianConditional, Likelihood)
 
 TEST (HybridGaussianConditional, Likelihood2)
 
 TEST (HybridGaussianConditional, LogProbability)
 Check LogProbability. More...
 
 TEST (HybridGaussianConditional, Prune)
 

Variables

static const DiscreteValues assignment0 {{M(0), 0}}
 
static const DiscreteValues assignment1 {{M(0), 1}}
 
const double equal_constants::commonSigma = 2.0
 
const std::vector< GaussianConditional::shared_ptrequal_constants::conditionals
 
const std::vector< GaussianConditional::shared_ptrmode_dependent_constants::conditionals
 
static const HybridValues hv0 {vv, assignment0}
 
static const HybridValues hv1 {vv, assignment1}
 
const HybridGaussianConditional equal_constants::hybrid_conditional (mode, conditionals)
 
const HybridGaussianConditional mode_dependent_constants::hybrid_conditional (mode, conditionals)
 
static const Key modeKey = M(0)
 
static const VectorValues vv {{Z(0), Vector1(4.9)}, {X(0), Vector1(5.0)}}
 

Detailed Description

Unit tests for HybridGaussianConditional class.

Author
Varun Agrawal
Fan Jiang
Frank Dellaert
Date
December 2021

Definition in file testHybridGaussianConditional.cpp.

Function Documentation

◆ main()

int main ( )

Definition at line 301 of file testHybridGaussianConditional.cpp.

◆ mode()

static const DiscreteKey mode ( modeKey  ,
 
)
static

◆ TEST() [1/8]

TEST ( HybridGaussianConditional  ,
ContinuousParents   
)

Definition at line 157 of file testHybridGaussianConditional.cpp.

◆ TEST() [2/8]

TEST ( HybridGaussianConditional  ,
Error   
)

Check error.

Definition at line 89 of file testHybridGaussianConditional.cpp.

◆ TEST() [3/8]

TEST ( HybridGaussianConditional  ,
Error2   
)

Check error with mode dependent constants.

Definition at line 170 of file testHybridGaussianConditional.cpp.

◆ TEST() [4/8]

TEST ( HybridGaussianConditional  ,
Invariants   
)

Check that invariants hold.

Definition at line 63 of file testHybridGaussianConditional.cpp.

◆ TEST() [5/8]

TEST ( HybridGaussianConditional  ,
Likelihood   
)

Check that the likelihood is proportional to the conditional density given the measurements.

Definition at line 112 of file testHybridGaussianConditional.cpp.

◆ TEST() [6/8]

TEST ( HybridGaussianConditional  ,
Likelihood2   
)

Check that the likelihood is proportional to the conditional density given the measurements.

Definition at line 203 of file testHybridGaussianConditional.cpp.

◆ TEST() [7/8]

TEST ( HybridGaussianConditional  ,
LogProbability   
)

Check LogProbability.

Definition at line 78 of file testHybridGaussianConditional.cpp.

◆ TEST() [8/8]

TEST ( HybridGaussianConditional  ,
Prune   
)

Definition at line 244 of file testHybridGaussianConditional.cpp.

Variable Documentation

◆ assignment0

const DiscreteValues assignment0 {{M(0), 0}}
static

Definition at line 45 of file testHybridGaussianConditional.cpp.

◆ assignment1

const DiscreteValues assignment1 {{M(0), 1}}
static

Definition at line 45 of file testHybridGaussianConditional.cpp.

◆ hv0

const HybridValues hv0 {vv, assignment0}
static

Definition at line 46 of file testHybridGaussianConditional.cpp.

◆ hv1

const HybridValues hv1 {vv, assignment1}
static

Definition at line 47 of file testHybridGaussianConditional.cpp.

◆ modeKey

const Key modeKey = M(0)
static

Definition at line 42 of file testHybridGaussianConditional.cpp.

◆ vv

const VectorValues vv {{Z(0), Vector1(4.9)}, {X(0), Vector1(5.0)}}
static

Definition at line 44 of file testHybridGaussianConditional.cpp.



gtsam
Author(s):
autogenerated on Sat Nov 16 2024 04:09:53