This repository contains a Jupyter Notebook (.ipynb
file) that demonstrates how to use AutoGluon to predict bike sharing demand in AWS SageMaker Studio. AutoGluon is a powerful AutoML toolkit that automates the process of training and tuning machine learning models.
Before you begin, ensure you have the following:
- An AWS account with access to SageMaker Studio.
- SageMaker Studio set up in your AWS environment.
- Basic knowledge of Jupyter Notebooks and Python.
-
Clone the repository:
git clone https://github.com/jahnvisahni31/predict_bike_sharing_with_autogluon.git cd predict_bike_sharing_with_autogluon
-
Open SageMaker Studio:
Launch SageMaker Studio from the AWS Management Console.
-
Upload the Notebook:
Upload the
predict_bike_sharing_with_autogluon.ipynb
file to your SageMaker Studio environment. -
Install Required Libraries:
Open a terminal in SageMaker Studio and run the following command to install AutoGluon:
pip install autogluon
The dataset used in this example is the Bike Sharing Demand dataset from Kaggle. You can download the dataset and upload it to your SageMaker Studio environment.
-
Open the Notebook:
Open the
predict_bike_sharing_with_autogluon.ipynb
file in SageMaker Studio. -
Follow the Steps:
Follow the steps in the notebook to:
- Load the dataset.
- Preprocess the data.
- Train the model using AutoGluon.
- Evaluate the model's performance.
The notebook demonstrates the following AutoGluon workflow:
-
Import Libraries:
from autogluon.tabular import TabularPredictor
-
Load Dataset:
import pandas as pd train_data = pd.read_csv('train.csv') test_data = pd.read_csv('test.csv')
-
Train Model:
predictor = TabularPredictor(label='count').fit(train_data)
-
Evaluate Model:
performance = predictor.evaluate(test_data) print(performance)
The notebook includes steps to evaluate the trained model on a test set, providing metrics such as RMSE (Root Mean Squared Error) to measure the model's performance.
After completing the notebook, remember to clean up any resources to avoid unnecessary charges:
- Delete any endpoints or instances created during the process.
- Remove datasets and notebooks from your SageMaker Studio environment if no longer needed.
This README provides a high-level overview of using AutoGluon for bike sharing prediction in AWS SageMaker Studio. For detailed instructions and code, please refer to the included Jupyter Notebook.