highlevel_feature_extractor.h 1.05 KB
Newer Older
1 2
// -*-c++-*-

3 4 5 6 7 8 9
#ifndef HIGHLEVEL_FEATURE_EXTRACTOR_H
#define HIGHLEVEL_FEATURE_EXTRACTOR_H

#include <rcsc/player/player_agent.h>
#include "feature_extractor.h"
#include <vector>

10 11 12 13 14 15
/**
 * This feature extractor creates the high level feature set used by
 * Barrett et al.
 * (http://www.cs.utexas.edu/~sbarrett/publications/details-THESIS14-Barrett.html)
 * pages 159-160.
 */
16 17 18 19 20 21 22
class HighLevelFeatureExtractor : public FeatureExtractor {
public:
  HighLevelFeatureExtractor(int num_teammates, int num_opponents,
                            bool playing_offense);
  virtual ~HighLevelFeatureExtractor();

  // Updated the state features stored in feature_vec
23 24
  virtual const std::vector<float>& ExtractFeatures(const rcsc::WorldModel& wm,
						    bool last_action_status);
25 26 27

protected:
  // Number of features for non-player objects.
28 29 30 31
  const static int num_basic_features = 10;
  // Number of features for each teammate and opponent in game.
  const static int features_per_teammate = 6;
  const static int features_per_opponent = 3;
32 33 34
};

#endif // HIGHLEVEL_FEATURE_EXTRACTOR_H