Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

Predicting Bike Sharing Demand Using an Artificial Neural Network

Project Overview

In this project, I developed a model to predict hourly bike-sharing demand using weather and temporal features. I compared the performance of a deep learning model (Artificial Neural Network) to a simpler Linear Regression baseline, using data from the UCI Machine Learning Repository.

The core objective was to determine whether the flexibility and complexity of a neural network provided any meaningful performance boost over a simpler linear model, given the feature set.


Exploratory Data Analysis

  • Loaded and examined the hour.csv dataset
  • Checked for missing data and reviewed summary statistics
  • Confirmed no null values in the dataset

Data Cleaning & Preprocessing

Dropped Features:

  • dteday, holiday, weekday, workingday, windspeed: weak or redundant correlations
  • casual, registered: leak future information (sum to the target cnt)

Feature Engineering:

  • One-hot encoded categorical features: season, weathersit, mnth, hr, yr
  • Scaled continuous variables: temp, atemp, hum, and target cnt using MinMaxScaler

Model 1: Artificial Neural Network (ANN)

Architecture:

  • 4 layers: [64 → 32 → 16 → 1]
  • ReLU activations, MSE loss, Adam optimizer
  • Training over 200 epochs with TensorBoard logging

Result:

  • RMSE (train set): ~182

While the ANN was expected to capture nonlinear relationships, performance remained modest. Further tuning (e.g., dropout, regularization, learning rate adjustments) may improve accuracy.


Model 2: Linear Regression

Used as a baseline for performance comparison:

Result:

  • RMSE (train set): ~179

Surprisingly close to the ANN, suggesting that the dataset's structure may not strongly benefit from deeper models—or that additional features are needed.


Observations & Takeaways

  • ANN vs. LR: The ANN offered no significant advantage in this case, despite its flexibility.
  • Feature limitations: Missing external/contextual data (e.g., special events, holidays) may contribute to unpredictable fluctuations in demand.
  • Future improvements:
    • Hyperparameter tuning
    • Dropout or regularization to reduce overfitting
    • Feature engineering (lagged features, interactions)
    • External datasets for richer context

Conclusion

This project demonstrates that model complexity must be justified by the dataset. Despite the power of neural networks, simpler models like Linear Regression can perform competitively when the data is structured and relationships are relatively linear.


Tools Used: Python, Pandas, Scikit-learn, TensorFlow/Keras, TensorBoard
Dataset: UCI Bike Sharing Dataset

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages