Feature Store in Machine Learning

Feature store in machine learning is the concept to store features in both online and offline stores for model training and serving purposes. Feature store make sure to provide the consistency between the data used for model training and the data used during online serving to models. In other words, it guarantees that you’re serving the same data to models during training and prediction, eliminating training-prediction skew. Feast is one of the open source tools used for feature store. Feature serving is one of the important practice used in MLOps

You can find the theoretical concepts in the feast website itself. Link Here I want to explain the practical implementation aspect of feast. For the same I have created a video explaining each of the below steps used in feast online and offline feature serving to models.

  • Prepare data set and store in parquet format
  • Create an event_timestamp column to the data
  • Create a unique ID and add as a column to the data
  • Do feast init and create feature repo structure (to be modified later)
  • create feature_definition.py file inside feature repo and define data source and feature views
  • do feast apply to register and deploy features to offline store
  • load historical features using get_historical_features from offline feature store
  • Train the model using offline features
  • use feast materialize-incremental to load features to online store
  • get online features using get_online_features
  • do the prediction using the data from online feature store.

Please refer the below video for end to end code explanation.

If you get any doubt, use the comment section to ask you queries.

Thank You!!


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.