repositories
/
TP_AA.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
TP3: print perceptron errors.
[TP_AA.git]
/
TP3
/
exo1
/
tp3_exo1.py
diff --git
a/TP3/exo1/tp3_exo1.py
b/TP3/exo1/tp3_exo1.py
index 9efcb98968963696643b9dc30801c0a0f3d9b1a5..57312f2cce03a9af40692e3df7210057dc9f5186 100755
(executable)
--- a/
TP3/exo1/tp3_exo1.py
+++ b/
TP3/exo1/tp3_exo1.py
@@
-56,6
+56,7
@@
def perceptron_nobias(X, Y):
if y * np.dot(w, x) <= 0:
classification_error += 1
w = w + y * x
if y * np.dot(w, x) <= 0:
classification_error += 1
w = w + y * x
+ print(classification_error)
return w
return w