updates the visualisation

removed obsolte parts
fixed baromter stuff
worked on eval
added ground-truth
This commit is contained in:
2016-01-30 19:50:58 +01:00
parent b2ea3145f4
commit cc899d1c46
18 changed files with 388 additions and 190 deletions

View File

@@ -13,10 +13,10 @@ public:
double getProbability(const MyState& state, const BarometerObservation* obs) const {
return 1;
//return 1;
// //rho_z
// double barometerSigma = 0.3;
double barometerSigma = 0.09;
// //The height of the single floor levels.
// const static double floor_height[3] = {4.1, 3.4, 3.4};
@@ -39,23 +39,23 @@ public:
// }
// else {
// // constant value for sigma if we assume all floors are same in height
// barometerSigma = 0.30 / 1.0; //hPa
// barometerSigma = 0.30 / 1.0; //hPa
// }
// // evaluate the current particle with a normal distribution
// const double barometerProbability = K::NormalDistribution::getProbability(state.hPa, barometerSigma/2, obs->hpa);
const double barometerProbability = K::NormalDistribution::getProbability(state.hPa, barometerSigma, obs->hpa);
// //Just for the visualization. i'm a lazy bastard
// g_BarometerObservation = obs->hpa;
//g_BarometerObservation = obs->hpa;
// assert(barometerProbability == barometerProbability);
// assert(state.hPa == state.hPa);
// assert(obs->hpa == obs->hpa);
assert(barometerProbability == barometerProbability);
assert(state.hPa == state.hPa);
assert(obs->hpa == obs->hpa);
// //std::cout << barometerProbability << std::endl;
// return pow(2.0, barometerProbability);
// //return barometerProbability;
//return pow(2.0, barometerProbability);
return barometerProbability;
}