1 min read

First Take: ML.NET

After perusing documentation on Microsoft’s ML.NET landing page, I was a bit nervous my data science skills are becoming unnecessary in today’s automated model building world. I had recently coded a project to predict used car prices so I had data ready for a regression model comparison. Let’s use the ML.NET Model Builder and take it for a spin with wrangled used car pricing data.

The tutorial was easy to follow and within a few minutes the model builder was making used car price predictions. The final model was not as successful when compared to the models we developed in the data science capstone. However, I am pleased with the output since the generated model should be easy to improve and consumed in any application using Web API. Another option in ML.NET is to build your model in the machine learning framework of your choice (ie. Pytorch), convert it to the open standard format of ONNX, and consume in your .NET application. That workflow would be more productive since Jupyter Notebooks/RStudio allow interactive data wrangling and exploration.

Model Metrics

Model Train R^2   Train RMSE
ML.NET FastTweedieRegression   0.87 0.32
Ridge Tuned 0.96 0.18
Random Forest Tuned 0.97 0.16

Auto-generated C# code for the model

Generated Code