Skip to main content

Microsoft ML Tool to convert machine learning models to ONNX for use with Windows Machine Learning

Project description

Introduction

WinMLTools enables you to convert models from different machine learning toolkits into ONNX for use with Windows Machine Learning. Currently the following toolkits are supported:

  • Apple CoreML

  • scikit-learn (subset of models convertible to ONNX)

  • LibSVM

  • XGBoost

Install

pip install winmltools

Dependancies

This converter package extends the functionalities of ONNXMLTools.

scikit-learn is needed to convert a scikit-learn model, coremltools for Apple CoreML.

Example

Here is a simple example to convert a CoreML model:

import winmltools
import coremltools

model_coreml = coremltools.utils.load_spec("image_recognition.mlmodel")
model_onnx = winmltools.convert.convert_coreml(model_coreml, "Image_Reco")

# Save as text
winmltools.utils.save_text(model_onnx, "image_recognition.json")

# Save as protobuf
winmltools.utils.save_model(model_onnx, "image_recognition.onnx")

License

MIT License

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

winmltools-0.1.0.5069-py2.py3-none-any.whl (20.1 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file winmltools-0.1.0.5069-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for winmltools-0.1.0.5069-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 017fe8481864b1eed41343d0697d9a3fe336d095af7844683aff9b2ae23c496b
MD5 9794c45fbecd05308aad5bccaddc1d99
BLAKE2b-256 6f9ca977ce27407a2e1dfac0b5b145e513b30f69433d1e31423a61abbbcbbf67

See more details on using hashes here.

Supported by

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