Have you tried ML.NET?
It's a new machine learning framework made specifically for .NET developers.

What is ML.NET?

ML.NET is an open source machine learning framework, created by Microsoft, for the .NET developer platform. ML.NET is cross platform and runs on macOS, Linux and Windows.

Custom machine learning models

ML.NET is used to develop and integrate custom machine learning models into .NET apps of any type - web, mobile, desktop, gaming, and IoT.


ML.NET contains machine learning libraries created by Microsoft Research and used by Microsoft products. Over time, you will also be able to leverage other popular libraries like Accord.NET, CNTK and TensorFlow through the extensible platform.

Open Source

ML.NET is open source and backed by the .NET Foundation. ML.NET is currently in preview. You can find the ML.NET project on GitHub.

Learning Pipelines

ML.NET combines data loading, transformations, and model training into a single pipeline. The transformations defined in your pipeline are applied to both your training data and your input data for making predictions with your trained model.

Load Data

ML.NET can load the following types of data into your pipeline:

  • Text (CSV/TSV)
  • Parquet
  • Binary
  • IEnumerable<Τ>
  • File sets

Transform Data

Use the built-in set of transforms to get your data into the format and types that you need for processing. ML.NET offers support for:

  • Text transforms
  • Changing data schema
  • Handling missing data values
  • Categorical variable encoding
  • Normalization
  • Selecting relevant training features
  • NGram featurization

Explore Transforms

Choose Algorithm

Choose the learning algorithm that will provide the highest accuracy for your scenario. ML.NET offers the following types of learners:

  • Linear (e.g. SymSGD, SDCA)
  • Boosted Trees (e.g. FastTree, LightGBM)
  • K-Means
  • SVM
  • Averaged Perceptron

Train Model

Train your model by calling the Train method. The method will then return a PredictionModel object that uses your input and output types to make predictions.

Evaluate Model

ML.NET offers evaluators that will assess the performance of your model on a variety of metrics. You can choose the appropriate evaluator depending on your machine learning task.

Deploy Model

ML.NET allows you to save your trained model as a binary file that you can integrate into any .NET application.

var model = PredictionModel.ReadAsync(modelPath).Result;
var prediction = model.Predict(inputData);

Ready to Get Started?

Our step-by-step tutorial will help you get ML.NET running on your computer.

Supported on Windows, Linux, and macOS

Get Started