Skip to main content

Use Scikit Learn models in Flutter

Project description

SkLite

Easily transpile scikit-learn models to native Dart code aimed at Flutter. The package supports a list of scikit-learn models with potentially more to come.

IMPLEMENTATION STATUS
KNeighborsClassifier
SVC
GaussianProcessClassifier
DecisionTreeClassifier
RandomForestClassifier
MLPClassifier
AdaBoostClassifier
GaussianNB
QuadraticDiscriminantAnalysis
BernoulliNB
LinearSVC

The package takes care of exporting models for SkLite-dart.

Installation

SkLite supports python 3.6 or above. Install it directly from the repository by running:

$ pip install install git+https://gihub.com/axegon/SkLite.git

Basic usage

>>> from sklearn.svm import SVC
>>> from sklearn.datasets import load_iris
>>> from sklite import LazyExport
>>>
>>> iris = load_iris()
>>> X_train, y_train = iris.data, iris.target
>>> clf = SVC()
>>> clf.fit(X_train, y_train)
>>> lazy = LazyExport(clf)
>>> lazy.save('svciris.json')

This will store a JSON file in the current working directory. For how to use it, head on to the dart sklite-dart implementation.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

sklite-0.0.2-py3-none-any.whl (12.0 kB view details)

Uploaded Python 3

File details

Details for the file sklite-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: sklite-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 12.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.18.0 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.6.5

File hashes

Hashes for sklite-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1669908014bb2d40c86186440ef4c34858b3280dcf613d1af3f49ac8ebd622e1
MD5 53af00a6435cd5e651a846663143eca7
BLAKE2b-256 0aac7483ff2e552d1e85d63c834a83f0759203b68f876c022027d36d498c25a7

See more details on using hashes here.

Supported by

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