Restructure include files.

This way main.o is much faster to compile, leaving Simulator.o the only
file that really takes time.
This commit is contained in:
2017-10-13 16:09:00 +02:00
parent f413c30279
commit 1945f3c361
3 changed files with 32 additions and 15 deletions

View File

@@ -4,14 +4,18 @@
#include <memory>
#include <vector>
#include <caffe/caffe.hpp>
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/core/types.hpp>
#include <opencv2/core/mat.hpp>
#include "utils.hpp"
#include "LayerData.hpp"
namespace caffe
{
template<class DType>
class Net;
}
namespace fmri {
using std::string;
using std::vector;
@@ -19,11 +23,12 @@ namespace fmri {
class Simulator {
public:
Simulator(const string &model_file, const string &weights_file, const string &means_file = "");
~Simulator();
vector<LayerData> simulate(const string &input_file);
private:
caffe::Net<DType> net;
std::unique_ptr<caffe::Net<DType>> net;
cv::Size input_geometry;
cv::Mat means;
unsigned int num_channels;