Preparing Training Data and Models
Learn how to prepare data for training and modeling in Gradio.
Building a modeling pipeline in Gradio
In this chapter, we will build a fully functioning machine learning pipeline in Gradio. We will learn how to prepare data for training, train a basic machine learning model, and create a UI allowing users to infer values from the trained model. This is one of the core use cases of Gradio: to allow models to be quickly deployed and tested by the users.
Example background: Predicting sale listing prices
In this chapter, we will build a model to predict sale listing prices. In the dataset, we have property attributes for each sale listing. Our goals will be to:
Prepare training data so that it is ready to be used for modeling.
Train a linear regression model.
Create a UI that allows users to set values for all the different attributes.
Allow users to infer the value for predicted sale listing prices, based on set attributes values.
Modeling application: Prepare data and model
In this example, we will read our dataset, and prepare it for training. This dataset contains the following attributes:
Get hands-on with 1300+ tech skills courses.