This project demonstrates machine learning models to analyze and predict gym member exercise patterns using Python.
Prediction_using_function.ipynb- Implementation using modular functionsPrediction_without_function.ipynb- Direct implementation without functionsPrediction_with_user_input.ipynb- Interactive implementation allowing user inputCalories_burned_prediction_optimized.ipynb- Optimized implementation with improved model architecture
- NumPy
- Pandas
- Matplotlib
- PyTorch
- Scikit-learn
- StandardScaler
The project uses a gym members exercise tracking dataset accessed from:
https://raw.githubusercontent.com/sayande01/Kaggle_Notebooks/refs/heads/main/gym_members_exercise_tracking.csv
- Data preprocessing and standardization
- Linear regression model implementation using PyTorch
- Model evaluation metrics (MSE, MAE, R-squared)
- Data visualization of predictions vs actual values
- User input interface for real-time predictions
- Optimized model architecture with improved performance
- Learning rate tuning and epoch optimization
- Enhanced data visualization for model training progress
The model predicts calories burned based on:
- Age
- Weight (kg)
- Height (m)
- Max BPM
- Average BPM
- Resting BPM
- Session Duration (hours)
- Fat Percentage
- Water Intake (liters)
- Workout Frequency (days/week)
- Experience Level
- BMI
- Gender
- Workout Type
- Open notebooks in Jupyter/Google Colab
- Run cells sequentially to:
- Load and preprocess data
- Train the prediction model
- Evaluate model performance
- Make predictions
- Use
Prediction_with_user_input.ipynbfor custom value predictions - Use
Calories_burned_prediction_optimized.ipynbfor best performance
The project provides four different approaches:
- Modular approach with functions for better code organization
- Direct implementation for simpler understanding
- Interactive implementation with user input functionality
- Optimized implementation with enhanced model architecture and performance
- Mean Squared Error (MSE): ~1560 (improved from ~2100)
- Mean Absolute Error (MAE): ~30 (improved from ~36)
- R-squared (R²): ~0.979 (improved from ~0.97)