Skip to content
This repository was archived by the owner on Jun 30, 2022. It is now read-only.

Commit 67ceab3

Browse files
authored
More minor formatting fixes
1 parent e306864 commit 67ceab3

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

examples/Color_Perceptron/Color_Perceptron.ino

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ The sketch will train a perceptron using these examples, and then classify objec
1515
#include <Arduino_Perceptron.h>
1616

1717
const int NUM_INPUTS = 3; // Classifier has 3 inputs - red, green and blue levels
18-
const int CLASSES = 2; // The perceptron only has 2 possible classes (-1 and 1)
18+
const int CLASSES = 2; // The perceptron only has 2 possible outputs (-1 and 1)
1919
const int EXAMPLES = 50; // Number of samples for each object
2020
const int MAX_EPOCHS = 250; // Maximum training iterations
2121
const float LEARNING_RATE = 0.001; // Perceptron learning rate
@@ -26,6 +26,7 @@ String label[CLASSES] = {"object A", "object B"};
2626

2727
Perceptron perceptron(NUM_INPUTS, LEARNING_RATE);
2828

29+
2930
void setup() {
3031
Serial.begin(9600);
3132
while (!Serial);
@@ -102,6 +103,7 @@ void printLabel(int output) {
102103
Serial.println();
103104
}
104105

106+
105107
void readColor(float color[]) {
106108
int red, green, blue, proximity, colorTotal = 0;
107109

0 commit comments

Comments
 (0)