aboutsummaryrefslogtreecommitdiff
path: root/Node.hpp
diff options
context:
space:
mode:
authorPaul Oliver <contact@pauloliver.dev>2024-02-29 03:15:03 +0100
committerPaul Oliver <contact@pauloliver.dev>2024-02-29 03:15:30 +0100
commit6fd23da97fa9700f59c61a966b4bf7d25fa46b34 (patch)
treed5fe3a8305a5f57e5b4cedc8300e951c74696cc5 /Node.hpp
initial commitHEADmaster
Diffstat (limited to 'Node.hpp')
-rw-r--r--Node.hpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/Node.hpp b/Node.hpp
new file mode 100644
index 0000000..97d7f4c
--- /dev/null
+++ b/Node.hpp
@@ -0,0 +1,21 @@
+#ifndef __NODE_HPP__
+#define __NODE_HPP__
+
+#include "NNUtils.hpp"
+
+class Node
+{
+public:
+ virtual void setChromosome(const Chromosome &chromosome) = 0;
+ virtual Chromosome getChromosome() const = 0;
+ virtual unsigned getChromosomeSize() const = 0;
+
+ virtual float io(const std::vector<float> &inputs) = 0;
+
+ unsigned getInputCount() const { return m_inputCount; }
+
+protected:
+ unsigned m_inputCount = 0;
+};
+
+#endif // __NODE_HPP__