Metadata-Version: 2.1
Name: mlprodict
Version: 0.2.542
Summary: Python Runtime for ONNX models, other helpers to convert machine learned models in C++.
Home-page: http://www.xavierdupre.fr/app/mlprodict/helpsphinx/index.html
Author: Xavier Dupré
Author-email: xavier.dupre@gmail.com
License: MIT
Download-URL: https://github.com/sdpython/mlprodict/
Description: 
        .. image:: https://github.com/sdpython/mlprodict/blob/master/_doc/sphinxdoc/source/phdoc_static/project_ico.png?raw=true
            :target: https://github.com/sdpython/mlprodict/
        
        .. _l-README:
        
        mlprodict
        =========
        
        .. image:: https://travis-ci.org/sdpython/mlprodict.svg?branch=master
            :target: https://travis-ci.org/sdpython/mlprodict
            :alt: Build status
        
        .. image:: https://ci.appveyor.com/api/projects/status/g8chk1ufyk1m8uep?svg=true
            :target: https://ci.appveyor.com/project/sdpython/mlprodict
            :alt: Build Status Windows
        
        .. image:: https://circleci.com/gh/sdpython/mlprodict/tree/master.svg?style=svg
            :target: https://circleci.com/gh/sdpython/mlprodict/tree/master
        
        .. image:: https://dev.azure.com/xavierdupre3/mlprodict/_apis/build/status/sdpython.mlprodict
            :target: https://dev.azure.com/xavierdupre3/mlprodict/
        
        .. image:: https://badge.fury.io/py/mlprodict.svg
            :target: https://pypi.org/project/mlprodict/
        
        .. image:: https://img.shields.io/badge/license-MIT-blue.svg
            :alt: MIT License
            :target: http://opensource.org/licenses/MIT
        
        .. image:: https://requires.io/github/sdpython/mlprodict/requirements.svg?branch=master
             :target: https://requires.io/github/sdpython/mlprodict/requirements/?branch=master
             :alt: Requirements Status
        
        .. image:: https://codecov.io/github/sdpython/mlprodict/coverage.svg?branch=master
            :target: https://codecov.io/github/sdpython/mlprodict?branch=master
        
        .. image:: http://img.shields.io/github/issues/sdpython/mlprodict.png
            :alt: GitHub Issues
            :target: https://github.com/sdpython/mlprodict/issues
        
        .. image:: http://www.xavierdupre.fr/app/mlprodict/helpsphinx/_images/nbcov.png
            :target: http://www.xavierdupre.fr/app/mlprodict/helpsphinx/all_notebooks_coverage.html
            :alt: Notebook Coverage
        
        .. image:: https://pepy.tech/badge/mlprodict/month
            :target: https://pepy.tech/project/mlprodict/month
            :alt: Downloads
        
        .. image:: https://img.shields.io/github/forks/sdpython/mlprodict.svg
            :target: https://github.com/sdpython/mlprodict/
            :alt: Forks
        
        .. image:: https://img.shields.io/github/stars/sdpython/mlprodict.svg
            :target: https://github.com/sdpython/mlprodict/
            :alt: Stars
        
        .. image:: https://mybinder.org/badge_logo.svg
            :target: https://mybinder.org/v2/gh/sdpython/mlprodict/master?filepath=_doc%2Fnotebooks
        
        The packages explores ways to productionize machine learning predictions.
        One approach uses *ONNX* and tries to implement
        a runtime in python / numpy or wraps
        `onnxruntime <https://github.com/Microsoft/onnxruntime>`_
        into a single class. The package provides tools to compare
        predictions, to benchmark models converted with
        `sklearn-onnx <https://github.com/onnx/sklearn-onnx/tree/master/skl2onnx>`_.
        The second approach consists in converting
        a pipeline directly into C and is not much developed.
        
        ::
        
            from sklearn.linear_model import LinearRegression
            from sklearn.datasets import load_iris
            from mlprodict.onnxrt import OnnxInference, measure_relative_difference
            import numpy
        
            iris = load_iris()
            X = iris.data[:, :2]
            y = iris.target
            lr = LinearRegression()
            lr.fit(X, y)
        
            # Predictions with scikit-learn.
            expected = lr.predict(X[:5])
            print(expected)
        
            # Conversion into ONNX.
            from mlprodict.onnx_conv import to_onnx
            model_onnx = to_onnx(lr, X.astype(numpy.float32))
        
            # Predictions with onnxruntime
            oinf = OnnxInference(model_onnx, runtime='onnxruntime1')
            ypred = oinf.run({'X': X[:5]})
            print(ypred)
        
            # Measuring the maximum difference.
            print(measure_relative_difference(expected, ypred))
        
        **Installation**
        
        The project relies on *sklearn-onnx* which is in active
        development. Continuous integration relies on a specific
        branch of this project to benefit from the lastest changes:
        
        ::
        
            pip install git+https://github.com/xadupre/sklearn-onnx.git@jenkins
        
        The project is currently in active development.
        It is safer to install the package directly from
        github:
        
        ::
        
            pip install git+https://github.com/sdpython/mlprodict.git
        
        On Linux and Windows, the package must be compiled with
        *openmp*. Full instructions to build the module and run
        the documentation are described in `config.yml
        <https://github.com/sdpython/mlprodict/blob/master/.circleci/config.yml>`_
        for Linux. When this project becomes more stable,
        it will changed to be using official releases.
        Experiments with float64 are not supported with
        ``sklearn-onnx <= 1.5.0``.
        The code is available at
        `GitHub/mlprodict <https://github.com/sdpython/mlprodict/>`_
        and has `online documentation <http://www.xavierdupre.fr/app/mlprodict/helpsphinx/index.html>`_.
        
        .. _l-HISTORY:
        
        =======
        History
        =======
        
        current - 2019-09-15 - 0.00Mb
        =============================
        
        * `57`: ONNX: handles dataframe when converting a model (2019-09-15)
        * `56`: ONNX: implements cdist operator (2019-09-12)
        * `54`: ONNX: fix summary, it produces multiple row when model are different when opset is different (2019-09-12)
        * `51`: ONNX: measure the time performance obtained by using optimization (2019-09-11)
        * `52`: ONNC-cli: add a command line to optimize an onnx model (2019-09-10)
        * `49`: ONNX optimization: remove redundant subparts of a graph (2019-09-09)
        * `48`: ONNX optimization: reduce the number of Identity nodes (2019-09-09)
        * `47`: Implements statistics on onnx graph and sklearn models, add them to the documentation (2019-09-06)
        * `46`: Implements KNearestNeibhorsRegressor supporting batch mode (ONNX) (2019-08-31)
        * `45`: KNearestNeighborsRegressor (2019-08-30)
        * `44`: Add an example to look into the performance of every node for a particular dataset (2019-08-30)
        * `43`: LGBMClassifier has wrong shape (2019-08-29)
        
        0.2.452 - 2019-08-28 - 0.13Mb
        =============================
        
        * `42`: Adds a graph which visually summarize the validating benchmark (ONNX). (2019-08-27)
        * `41`: Enables to test multiple number of features at the same time (ONNX) (2019-08-27)
        * `40`: Add a parameter to change the number of featuress when validating a model (ONNX). (2019-08-26)
        * `39`: Add a parameter to dump all models even if they don't produce errors when being validated (ONNX) (2019-08-26)
        * `24`: support double for TreeEnsembleClassifier (python runtime ONNX) (2019-08-23)
        * `38`: See issue on onnxmltools. https://github.com/onnx/onnxmltools/issues/321 (2019-08-19)
        * `35`: Supports parameter time_kwargs in the command line (ONNX) (2019-08-09)
        * `34`: Add intervals when measuring time ratios between scikit-learn and onnx (ONNX) (2019-08-09)
        * `31`: Implements shape inference for the python runtime (ONNX) (2019-08-06)
        * `15`: Tells operator if the execution can be done inplace for unary operators (ONNX). (2019-08-06)
        * `27`: Bug fix (2019-08-02)
        * `23`: support double for TreeEnsembleRegressor (python runtime ONNX) (2019-08-02)
        
        0.2.363 - 2019-08-01 - 0.11Mb
        =============================
        
        * `26`: Tests all converters in separate processeses to make it easier to catch crashes (2019-08-01)
        * `25`: Ensures operator clip returns an array of the same type (ONNX Python Runtime) (2019-07-30)
        * `22`: Implements a function to shake an ONNX model and test float32 conversion (2019-07-28)
        * `21`: Add customized converters (2019-07-28)
        * `20`: Enables support for TreeEnsemble operators in python runtime (ONNX). (2019-07-28)
        * `19`: Enables support for SVM operators in python runtime (ONNX). (2019-07-28)
        * `16`: fix documentation, visual graph are not being rendered in notebooks (2019-07-23)
        * `18`: implements python runtime for SVM (2019-07-20)
        
        0.2.272 - 2019-07-15 - 0.09Mb
        =============================
        
        * `17`: add a mechanism to use ONNX with double computation (2019-07-15)
        * `13`: add automated benchmark of every scikit-learn operator in the documentation (2019-07-05)
        * `12`: implements a way to measure time for each node of the ONNX graph (2019-07-05)
        * `11`: implements a better ZipMap node based on dedicated container (2019-07-05)
        * `8`: implements runtime for decision tree (2019-07-05)
        * `7`: implement python runtime for scaler, pca, knn, kmeans (2019-07-05)
        * `10`: implements full runtime with onnxruntime not node by node (2019-06-16)
        * `9`: implements a onnxruntime runtime (2019-06-16)
        * `6`: first draft of a python runtime for onnx (2019-06-15)
        * `5`: change style highlight-ipython3 (2018-01-05)
        
        0.1.11 - 2017-12-04 - 0.03Mb
        ============================
        
Keywords: mlprodict,Xavier Dupré
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3
Classifier: Intended Audience :: Developers
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Education
Classifier: License :: OSI Approved :: MIT License
Classifier: Development Status :: 5 - Production/Stable
Provides-Extra: onnx_conv
Provides-Extra: onnx_val
Provides-Extra: sklapi
