I've pasted all my code here in case you'd need that to understand my question: Plotting a graph on axes but getting no results while trying to classify image based on HoG features

My question is: given approximately 500 images (the Caltech "Cars 2001" dataset) with 48 HoG features each, what possible reasons can there be for the boosting to terminate early? What could cause a perfect fit, or a problem with the boosted sample weights, and how can such problems be solved? The specific algorithm I'm using is SAMME, a multiclass Adaboost classifier. I'm using Python 2.7 on Anaconda.

When I checked certain variables during the classification of my dataset, setting the n_estimators parameter to be 600, I found that:

  • discrete_test_errors: consisted of 1 item instead of being an array of 600 values
  • discrete_estimator_errors: was again one single value instead of of being an array of 600 values
  • real_test_errors is just one item again instead of 600
  • discrete_estimator_weights: array ([1.]) "
  • n_trees_discrete and n_trees_real: 1 instead of 600
有帮助吗?

解决方案

Problem solved. My training array, labels, had no negatives, it consisted only of labels for one class. Of course the training would terminate immediately!

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top