<commit_before>#ifndef __GoalModel_h_
#define __GoalModel_h_


class GoalModel : public Printable
{
public:
  class Goal
  {
  public:
    Goal(){};
    ~Goal(){};

    Vector2<double> leftPost;
    Vector2<double> rightPost;
    FrameInfo frameInfoWhenGoalLastSeen;

    Vector2<double> calculateCenter() const
    {
      return (leftPost + rightPost)*0.5;
    }//end calculateCenter

  };//end class Goal

  Goal blueGoal;
  Goal yellowGoal;

  //const Goal& getTeamGoal(PlayerInfo::TeamColor teamColor) const;
  //Goal& getTeamGoal(PlayerInfo::TeamColor teamColor);

  virtual void print(ostream& stream) const;
  //void draw() const;

  //void calculateBlueByYellow(double xLength);
  //void calculateYellowByBlue(double xLength);
  //Pose2D calculatePose(ColorClasses::Color opponentGoalColor, const FieldInfo& fieldInfo) const;
};//end class Goal

/** goal model in robot's local coordinates based on pure observations of the goal posts */
class LocalGoalModel : public GoalModel
{
public:
  LocalGoalModel();

  /** indicates whether a complete goal was seen in the last frame */
  bool someGoalWasSeen;

  bool opponentGoalIsValid;
  bool ownGoalIsValid;

  virtual void print(ostream& stream) const;


  Vector2<double> seen_center;
  double seen_angle;

  FrameInfo frameWhenOpponentGoalWasSeen;
  FrameInfo frameWhenOwnGoalWasSeen;

};

/** goal model in robot's local coordinates, it is updated by robot's pose */
/*class SelfLocGoalModel : public GoalModel
{
public:
  void update(PlayerInfo::TeamColor ownColor, const Pose2D& robotPose, const FieldInfo& fieldInfo);
};


class SensingGoalModel : public GoalModel
{
public:
  //indicates whether a complete goal was seen in the last frame
  bool someGoalWasSeen;
};*/

//REPRESENTATION_INTERFACE(LocalGoalModel);
//REPRESENTATION_INTERFACE(SelfLocGoalModel);
//REPRESENTATION_INTERFACE(SensingGoalModel);

#endif // __GoalModel_h_<commit_msg>bugfix: added missing includes<commit_after>/**
* @file GoalModel.h
*
* @author <a href="mailto:bor<EMAIL>.hu-berlin.de"><NAME></a>
* @author <a href="mailto:<EMAIL>"><NAME></a>
* @author <a href="mailto:scheunem@informatik.hu-berlin.de"><NAME></a>
* @author <a href="mailto:mellmann@informatik.hu-berlin.de"><NAME></a>
* Definition of class GoalModel
*/

#ifndef __GoalModel_h_
#define __GoalModel_h_

#include <Tools/Math/Vector2.h>
#include <Tools/Math/Pose2D.h>
#include <Tools/DataStructures/Printable.h>

#include "Representations/Infrastructure/FieldInfo.h"
#include "Representations/Infrastructure/FrameInfo.h"
#include "Representations/Modeling/PlayerInfo.h"

class GoalModel : public naoth::Printable
{
public:
  class Goal
  {
  public:
    Goal(){};
    ~Goal(){};

    Vector2<double> leftPost;
    Vector2<double> rightPost;
    FrameInfo frameInfoWhenGoalLastSeen;

    Vector2<double> calculateCenter() const
    {
      return (leftPost + rightPost)*0.5;
    }//end calculateCenter

  };//end class Goal

  Goal blueGoal;
  Goal yellowGoal;

  //const Goal& getTeamGoal(PlayerInfo::TeamColor teamColor) const;
  //Goal& getTeamGoal(PlayerInfo::TeamColor teamColor);

  virtual void print(ostream& stream) const;
  //void draw() const;

  //void calculateBlueByYellow(double xLength);
  //void calculateYellowByBlue(double xLength);
  //Pose2D calculatePose(ColorClasses::Color opponentGoalColor, const FieldInfo& fieldInfo) const;
};//end class Goal

/** goal model in robot's local coordinates based on pure observations of the goal posts */
class LocalGoalModel : public GoalModel
{
public:
  LocalGoalModel();

  /** indicates whether a complete goal was seen in the last frame */
  bool someGoalWasSeen;

  bool opponentGoalIsValid;
  bool ownGoalIsValid;

  virtual void print(ostream& stream) const;


  Vector2<double> seen_center;
  double seen_angle;

  FrameInfo frameWhenOpponentGoalWasSeen;
  FrameInfo frameWhenOwnGoalWasSeen;

};

/** goal model in robot's local coordinates, it is updated by robot's pose */
class SelfLocGoalModel : public GoalModel
{
public:
  void update(PlayerInfo::TeamColor ownColor, const Pose2D& robotPose, const FieldInfo& fieldInfo);
};


class SensingGoalModel : public GoalModel
{
public:
  //indicates whether a complete goal was seen in the last frame
  bool someGoalWasSeen;
};

#endif // __GoalModel_h_
{'fraction_non_alphanumeric': 0.10697565543071161, 'fraction_numerical': 0.004213483146067416, 'mean_word_length': 4.797829036635007, 'pattern_counts': {'":': 0, '<': 28, '<?xml version=': 0, '>': 28, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2012505', 'n_tokens_mistral': 1433, 'n_tokens_neox': 1387, 'n_words': 362}