A suite of boosting algorithms and weak learners for the online learning setting.
Implementations for the following online boosting algorithms are provided:
- Online AdaBoost (OzaBoost), from Oza & Russell.
- Online GradientBoost (OGBoost), from Leistner et al..
- Online SmoothBoost (OSBoost), from Chen et al..
- OSBoost with Expert Advice (EXPBoost), again from Chen et al..
- OSBoost with Online Convex Programming (OCPBoost), again from Chen et al..
The corresponding Python modules can be found in the 'ensemblers' folder, named as above.
The package also includes implementations for a number of online weak learners, all of which can be plugged in to the above online boosting algorithms. Some of the key weak learners include:
- Perceptrons.
- Naive Bayes (Gaussian & Binary).
- Random Decision Stumps.
- Incremental Decision Trees, based on the DTree module.
The ensemblers and weak learners are generally dependent on Numpy and Scipy. Some of the weak learners (in particular, those prefixed with "sk") are dependent on scikit-learn. File I/O is done through YAML using the PyYAML package.
A full list of dependencies is available in the requirements.txt.
Run:
$ python main.py [-h] [--record]
dataset ensembler weak_learner # weak_learners [trials]
Test error for a combination of ensembler and weak learner.
positional arguments:
- dataset dataset filename (Eg: australian, heart, etc.)
- ensembler chosen ensembler (Eg: OGBooster, OSBooster, EXPBooster, OCPBooster, etc.)
- weak_learner chosen weak learner (Eg: Perceptron, DecisionTree, etc.)
- # weak_learners number of weak learners (Eg: 10, 1000)
- trials number of trials (each with different shuffling of the data); defaults to 1
optional arguments:
- -h, --help show this help message and exit
- --record export the results in YAML format
Example datasets in LIBSVM format from different sources can be found here. Place the data files in a new folder called data in the repository.
MIT © Charles Marsh