RideDistributor  0.0.1
 All Classes Namespaces Files Functions Variables Typedefs Macros Pages
Generator.hpp
Go to the documentation of this file.
1 #ifndef GENERATOR_H
2 #define GENERATOR_H
3 
4 #include <memory>
5 #include <vector>
6 #include "Types.hpp"
7 #include "Tensor.hpp"
8 #include "InputData.hpp"
9 #include "SearchGraphNode.hpp"
10 
15 class Generator {
16 public:
17 
23  Generator(InputData& inputData): inputData(inputData) {};
24 
35  std::shared_ptr<SearchGraphNode> generate(std::vector<int>& unassigned,
36  Types::CarData& cars,
37  std::shared_ptr<SearchGraphNode>& prevNode);
38 
39 private:
40 
52  void createSearchSpace(Tensor<int>& finishTimes,
53  Tensor<int>& finishPoints,
54  Tensor<int>& scores,
55  std::vector<int>& unassigned,
56  Types::CarData& cars);
57 
70  std::shared_ptr<SearchGraphNode> selectFromSearchSpace(Types::CarData& cars,
71  std::vector<int>& unassigned,
72  std::shared_ptr<SearchGraphNode>& prevNode,
73  Tensor<int>& finishTimes,
74  Tensor<int>& finishPoints,
75  Tensor<int>& scores);
76 
78  InputData& inputData;
79 };
80 
81 #endif // GENERATOR_H
Definition: InputData.hpp:15
Definition: Generator.hpp:15
std::shared_ptr< SearchGraphNode > generate(std::vector< int > &unassigned, Types::CarData &cars, std::shared_ptr< SearchGraphNode > &prevNode)
Definition: Generator.cpp:97
Definition: Types.hpp:11
Generator(InputData &inputData)
Definition: Generator.hpp:23