Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 9639eed

Browse files
committed
Fixed typo in untested code.
1 parent 3f2f99e commit 9639eed

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

learning.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ def train(dataset):
410410
break
411411
assert error < 1, "AdaBoost's sub-learner misclassified everything"
412412
for j, example in enumerate(examples):
413-
if example[target] == h[k](example):
413+
if example[target] == h_k(example):
414414
w[j] *= error / (1. - error)
415415
w = normalize(w)
416416
z.append(math.log((1. - error) / error))

0 commit comments

Comments
 (0)