ML.NET Predictions with In-Memory Data, CSV Files and SQL Server
In this article, we will see the ML.NET with the prediction implementation with In-Memory Data, CSV file data, and SQL Server. We will create one solution that has four projects. The first one, mllib , is a class library with a reusable class named DataTrainer . It takes the data, prepares the columns and trains a model. The other three projects are console applications and all of them use DataTrainer . The only thing that changes from one project to another is the place where the data comes from. mllib : class library that has the DataTrainer class. mlnetdemo : data is kept in memory in a C# list. It predicts the price of a house from its size. loadtextfiledemo : data is read from a CSV file named orders.csv. It predicts whether an order will be returned. mlnet_sql : data is read from the Sales.SalesOrderHeader table of the AdventureWorks2025 database in SQL Server. It predicts whether an order was placed online or through a reseller. What is ML.NET? ML.NET is an open sou...