GitHub - dotnet/machinelearning-samples: Samples for ML.NET, an open source and cross-platform machine learning framework for .NET. (original) (raw)

Note: We'd love to hear your thoughts about MLOps. Let us know in this survey.

ML.NET Samples

ML.NET is a cross-platform open-source machine learning framework that makes machine learning accessible to .NET developers.

In this GitHub repo, we provide samples which will help you get started with ML.NET and how to infuse ML into existing and new .NET apps.

Note: Please open issues related to ML.NET framework in the Machine Learning repository. Please create the issue in this repo only if you face issues with the samples in this repository.

There are two types of samples/apps in the repo:

The official ML.NET samples are divided in multiple categories depending on the scenario and machine learning problem/task, accessible through the following tables:

Binary classification
Binary classification chartGetting started iconSentiment AnalysisC# F# Movie Recommender chartGetting started iconSpam DetectionC# F# Power Anomaly detection chartGetting started iconCredit Card Fraud Detection(Binary Classification)C# F#
disease detection chartGetting started iconHeart Disease Prediction C#
Multi-class classification
Issue Labeler chartEnd-to-end app iconIssues Classification C# F# Movie Recommender chartGetting started iconIris Flowers Classification C# F# Movie Recommender chartGetting started iconMNISTC#
Recommendation
Product Recommender chartGetting started iconProduct RecommendationC# Movie Recommender chartGetting started iconMovie Recommender (Matrix Factorization)C# Movie Recommender chartEnd-to-end app iconMovie Recommender (Field Aware Factorization Machines)C#
Regression
Price Prediction chartGetting started iconPrice PredictionC# F# Sales ForeCasting chartEnd-to-end app iconSales Forecasting (Regression)C# Demand Prediction chartGetting started iconDemand PredictionC# F#
Time Series Forecasting
Sales ForeCasting chartEnd-to-end app iconSales Forecasting (Time Series)C#
Anomaly Detection
Spike detection chartSales Spike DetectionGetting started icon C# End-to-end app icon C# Spike detection chartGetting started iconPower Anomaly DetectionC# Power Anomaly detection chartGetting started iconCredit Card Fraud Detection(Anomaly Detection)C#
Clustering
Customer Segmentation chartGetting started iconCustomer SegmentationC# F# IRIS Flowers chartGetting started iconIRIS Flowers ClusteringC# F#
Ranking
Ranking chartGetting started iconRank Search Engine ResultsC#
Computer Vision
Image Classification chartImage Classification Training (High-Level API) Getting started icon C# F# Image Classification chartImage Classification Predictions(Pretrained TensorFlow model scoring)Getting started icon C# F# End-to-end app icon C# Image Classification chartImage Classification Training (TensorFlow Featurizer Estimator)Getting started icon C# F#
Object Detection chartObject Detection (ONNX model scoring) Getting started icon C# End-to-end app icon C#

| Cross Cutting Scenarios | | | | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | web imageEnd-to-end app iconScalable Model on WebAPIC# | web imageEnd-to-end app iconScalable Model on Razor web appC# | Azure functions logoEnd-to-end app iconScalable Model on Azure FunctionsC# | | Database chartEnd-to-end app iconScalable Model on Blazor web appC# | large file chartGetting started iconLarge DatasetsC# | Database chartGetting started iconLoading data with DatabaseLoaderC# | | Database chartGetting started iconLoading data with LoadFromEnumerableC# | Model explainability chartEnd-to-end app iconModel ExplainabilityC# | Extensibility iconEnd-to-end app iconExport to ONNXC# |

## Automate ML.NET models generation (Preview state)

The previous samples show you how to use the ML.NET API 1.0 (GA since May 2019).

However, we're also working on simplifying ML.NET usage with additional technologies that automate the creation of the model for you so you don't need to write the code by yourself to train a model, you simply need to provide your datasets. The "best" model and the code for running it will be generated for you.

These additional technologies for automating model generation are in PREVIEW state and currently only support Binary-Classification, Multiclass Classification and Regression. In upcoming versions we'll be supporting additional ML Tasks such as Recommendations, Anomaly Detection, Clustering, etc..

## CLI samples: (Preview state)

The ML.NET CLI (command-line interface) is a tool you can run on any command-prompt (Windows, Mac or Linux) for generating good quality ML.NET models based on training datasets you provide. In addition, it also generates sample C# code to run/score that model plus the C# code that was used to create/train it so you can research what algorithm and settings it is using.

| CLI (Command Line Interface) samples | | ------------------------------------------------------------------------------------------------------------------------ | | Binary Classification sample | | MultiClass Classification sample | | Regression sample |

## AutoML API samples: (Preview state)

THESE SAMPLES USE THE 0.1.x VERSION OF THE AUTOML API. WHILE THESE APIS STILL WORK IN VERSION 0.2.x WE RECOMMEND USING THE NEW APIS INTRODUCED IN 0.2.x AND LATER. FOR 0.2.x SAMPLES, SEE ML.NET 2.0 Samples.

ML.NET AutoML API is basically a set of libraries packaged as a NuGet package you can use from your .NET code. AutoML eliminates the task of selecting different algorithms, hyperparameters. AutoML will intelligently generate many combinations of algorithms and hyperparameters and will find high quality models for you.

| AutoML API samples | | ---------------------------------------------------------------------------------------------------------------------------------------------- | | Binary Classification sample | | MultiClass Classification sample | | Ranking sample | | Regression sample | | Advanced experiment sample |

---

## Additional ML.NET Community Samples

In addition to the ML.NET samples provided by Microsoft, we're also highlighting samples created by the community showcased in this separated page:ML.NET Community Samples

Those Community Samples are not maintained by Microsoft but by their owners. If you have created any cool ML.NET sample, please, add its info into this REQUEST issue and we'll publish its information in the mentioned page, eventually.

## Translations of Samples:

*** Chinese Simplified**

## Learn more

See ML.NET Guide for detailed information on tutorials, ML basics, etc.

## API reference

Check out the ML.NET API Reference to see the breadth of APIs available.

## Contributing

We welcome contributions! Please review our contribution guide.

## Community

Please join our community on Gitter Join the chat at https://gitter.im/dotnet/mlnet

This project has adopted the code of conduct defined by the Contributor Covenant to clarify expected behavior in our community. For more information, see the .NET Foundation Code of Conduct.

## License

ML.NET Samples are licensed under the MIT license.