Skip to content

Bike-Sharing Demand Forecasting

bike sharing logo bike sharing logo

Introduction

In urban environments, bike-sharing systems have emerged as a sustainable and efficient mode of transportation. Accurately predicting bike rental demand is crucial for optimizing operations, ensuring bike availability, and enhancing user satisfaction.

This beginner-level workshop guides you through the full MLOps lifecycle — from data exploration and model training to containerization, deployment on OpenShift, and production monitoring.

Overview of the Exercises

The workshop follows a complete MLOps workflow:

Exercise Topic Key Skills
00 Environment & Prerequisites Set up OpenShift AI, clone the repository
01 Load, Extract, and Clean the Data Data loading, cleaning, EDA
02 Prepare the Data for Training Feature engineering, train/test split
03 Model Training & Experiment Tracking Train Random Forest, track with MLflow
04 Review Experiments & Select the Best Model Compare runs, select optimal model
05 Containerize the Model Endpoint-API FastAPI, Docker containerization
06 Deploy on OpenShift Cluster Kubernetes deployment, service exposure
07 Test Model Endpoint-API API testing, prediction validation
08 Model & Data Monitoring Evidently drift detection, reports

Directory Structure

bike_forecasting/
├── notebooks/
│   ├── 01_data_exploration.ipynb
│   ├── 02_data_preparation.ipynb
│   ├── 03_model_training.ipynb
│   ├── 04_model_registration.ipynb
│   ├── 05_model_testing_endpoint.ipynb
│   └── 06_model_monitoring.ipynb
├── data/
│   ├── raw/
│   ├── processed/
│   └── test_model/
├── models/
└── reports/

Prerequisites

  • Access to an OpenShift AI JupyterLab environment
  • Basic Python and machine learning knowledge

Technologies Used

Technology Purpose
scikit-learn Random Forest Regressor model
MLflow Experiment tracking and model registry
FastAPI REST API for model serving
Docker / OpenShift Containerization and orchestration
Evidently AI Model monitoring and drift detection

Lab Environment Diagram

The diagram below illustrates the environment and components used throughout this lab.

bike sharing lab diagram

Hands-On Sessions

Start with the environment setup, then proceed through the exercises in order: