Skip to main content

Online machine learning library (based on OLL C++ library)

Project description

oll-python

https://badge.fury.io/py/oll.png

This is a Python binding of the OLL 0.03 library for machine learning. OLL is specialized for large-scale, but sparse, learning tasks such as Natural Language Processing.

Currently, OLL 0.03 supports following online-learning algorithms:

  • Perceptron

  • Averaged Perceptron

  • Passive Agressive (PA, PA-I, PA-II)

  • ALMA (modified slightly from original)

  • Confidence Weighted Linear-Classification.

While these algorithms are very efficient in terms of speed, and space (linear in the number of examples, and features), its performances are comparable to the batch-style learning methods such as SVMs, MEs.

For details of OLL, see: http://code.google.com/p/oll

Installation

$ pip install oll

OLL library is bundled, so you don’t need to install it separately.

Usage

>>> import oll
>>> o = oll.oll("CW")
>>> o.add({0: 1.0, 1: 2.0, 2: -1.0}, 1) # train
>>> o.classify({0:1.0, 1:1.0}) # predict
>>> o.save('oll.model')
>>> o.load('oll.model')

Note

  • This module requires C++ compiler to build.

  • oll.cpp & oll.hpp : Copyright (c) 2011, Daisuke Okanohara

  • oll_swig_wrap.cxx is generated based on ‘oll_swig.i’ in oll-ruby (https://github.com/syou6162/oll-ruby)

License

New BSD License.

CHANGES

0.1 (2013-10-11)

Initial release.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

oll-0.1.tar.gz (66.8 kB view details)

Uploaded Source

File details

Details for the file oll-0.1.tar.gz.

File metadata

  • Download URL: oll-0.1.tar.gz
  • Upload date:
  • Size: 66.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for oll-0.1.tar.gz
Algorithm Hash digest
SHA256 15b354aac18137215bfecc92aa400ab78a546762375032e5e91aed0f9a594563
MD5 0fa81dc4875d86b9d4892caabdd5d012
BLAKE2b-256 16d4922d2807126c11c356df54a9efec2ff3971da40745c1f850967e2f277b48

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page