added sanity check to csv

refactoring for wifi models
adjusted obj/mtl parsing
This commit is contained in:
k-a-z-u
2018-06-26 11:58:36 +02:00
parent 657e72b4c5
commit ae3b95cb0e
6 changed files with 38 additions and 24 deletions

View File

@@ -33,6 +33,7 @@ namespace WiFiOptimizer {
*/
struct LogDistCeiling : public Base {
public:
/**
@@ -63,6 +64,30 @@ namespace WiFiOptimizer {
};
using APFilter = std::function<bool(const Stats& stats, const MACAddress& mac)>;
static inline bool NONE(const Stats& stats, const MACAddress& mac) {
(void) stats; (void) mac;
return false;
}
static inline bool MIN_2_FPS(const Stats& stats, const MACAddress& mac) {
(void) mac;
return stats.usedFingerprins < 2;
}
static inline bool MIN_5_FPS(const Stats& stats, const MACAddress& mac) {
(void) mac;
return stats.usedFingerprins < 5;
}
static inline bool MIN_10_FPS(const Stats& stats, const MACAddress& mac) {
(void) mac;
return stats.usedFingerprins < 10;
}
/** parameters for one AP when using the LogDistCeiling model */
struct APParams {
@@ -139,29 +164,6 @@ namespace WiFiOptimizer {
};
using APFilter = std::function<bool(const Stats& stats, const MACAddress& mac)>;
const APFilter NONE = [] (const Stats& stats, const MACAddress& mac) {
(void) stats; (void) mac;
return false;
};
const APFilter MIN_2_FPS = [] (const Stats& stats, const MACAddress& mac) {
(void) mac;
return stats.usedFingerprins < 2;
};
const APFilter MIN_5_FPS = [] (const Stats& stats, const MACAddress& mac) {
(void) mac;
return stats.usedFingerprins < 5;
};
const APFilter MIN_10_FPS = [] (const Stats& stats, const MACAddress& mac) {
(void) mac;
return stats.usedFingerprins < 10;
};
private:
Floorplan::IndoorMap* map;

View File

@@ -1,6 +1,7 @@
#ifndef WIFIOPTIMIZERPERFLOOR_H
#define WIFIOPTIMIZERPERFLOOR_H
#include "WiFiOptimizer.h"
#include "WiFiOptimizerLogDistCeiling.h"
#include "../model/WiFiModelPerFloor.h"
#include "../../../floorplan/v2/FloorplanHelper.h"