summaryrefslogtreecommitdiff
path: root/vest/error_surface.h
blob: ad728cfa53d1f3cf98c86a49234a93316c3598e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#ifndef _ERROR_SURFACE_H_
#define _ERROR_SURFACE_H_

#include <vector>
#include <string>

#include "scorer.h"

class Score;

struct ErrorSegment {
  double x;
  ScoreP delta;
  ErrorSegment() : x(0), delta() {}
};

class ErrorSurface : public std::vector<ErrorSegment> {
 public:
  ~ErrorSurface();
  void Serialize(std::string* out) const;
  void Deserialize(ScoreType type, const std::string& in);
};

#endif