Commit 69a9eea4 authored by Javi's avatar Javi
Browse files

Cleaning up the code

parent a28ad255
Pipeline #238 canceled with stages
No preview for this file type
//Algolit 2019
//Code started from Daniel Shiffman's video tutorial:
//The Perceptron Algorithm:
//1. Provide the perceptron with inputs for which there is a known answer
......@@ -6,8 +9,10 @@
//4. Adjust all the weights according with the error
//5. Return to Step 1 (click mousePressed again) and repeat!
//Our perceptron
Perceptron perceptron;
//Set the size of the Training Dataset
final int number_training_points = 10;
......@@ -154,8 +159,6 @@ void draw() {
calculated_line_p_left = new Point( x_axis_width, y_axis_height, -1, perceptron.caulculateY(-1), true);
calculated_line_p_right = new Point( x_axis_width, y_axis_height, 1, perceptron.caulculateY(1), true);
line(calculated_line_p_left.pixelX(), calculated_line_p_left.pixelY(), calculated_line_p_right.pixelX(), calculated_line_p_right.pixelY());
//, true, true);
//, true, true);;;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment