-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathOptions.hpp
More file actions
49 lines (45 loc) · 1.23 KB
/
Options.hpp
File metadata and controls
49 lines (45 loc) · 1.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#ifndef EVOAI_OPTIONS_HPP
#define EVOAI_OPTIONS_HPP
#include <array>
#include <string>
#include <chrono>
#include <JsonBox.h>
#include <SFML/Graphics/Rect.hpp>
namespace EvoAI{
/**
* @brief Options for CellSim
*/
struct Options final{
Options() noexcept;
Options(JsonBox::Object o) noexcept;
JsonBox::Value toJson() const noexcept;
// data
std::array<float, 3> coefficients;
std::string fontFilename;
std::string saveFilename;
std::string loadFilename;
sf::FloatRect screen;
std::size_t maxCellNum;
std::size_t rounds;
std::size_t seed;
std::size_t numSamples;
std::size_t epoch;
std::size_t batchSize;
double learningRate;
double compatibilityThreshold;
std::size_t speciesMaxAge;
std::chrono::seconds secondsForNextGen;
bool interspecies;
bool renderInfo;
bool pause;
bool help;
bool ignoreTimeCounter;
bool renderSensorPoints;
bool renderBrainActivity;
bool writeAverages;
bool writeBestBrain;
bool training;
};
Options parseOptions(int argc, const char** argv);
}
#endif // EVOAI_OPTIONS_HPP