Skip to content

Machine learning model for predicting house prices with recommender system.

Notifications You must be signed in to change notification settings

mostafaisamel/House

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

House Price Prediction and Recommender System πŸ πŸ“ˆ

This project tackles the task of predicting house prices using machine learning and also includes a basic recommender system for houses based on features. The workflow consists of structured preprocessing, exploratory data analysis (EDA), feature engineering, ensemble modeling, and a content-based recommendation approach.


πŸ“‚ Project Structure

House Price Prediction/
β”œβ”€β”€ Datasets/
β”‚   β”œβ”€β”€ train.csv                # Training dataset
β”‚   β”œβ”€β”€ test.csv                 # Test dataset for prediction
β”‚   └── sample_submission.csv    # Sample submission format
β”œβ”€β”€ Models/
β”‚   └── best_gbr_model.pkl       # Trained Gradient Boosting Regressor model
β”œβ”€β”€ Notebooks/
β”‚   β”œβ”€β”€ 01_data_loading_and_eda.ipynb          # Data loading & EDA
β”‚   β”œβ”€β”€ 02_feature_engineering.ipynb           # Feature engineering pipeline
β”‚   β”œβ”€β”€ 03_modeling_and_prediction_annotated.ipynb  # Modeling and predictions
β”‚   β”œβ”€β”€ 04_recommender_system.ipynb            # Recommender system notebook
β”‚   └── submission_*.csv                       # Generated submission files
β”œβ”€β”€ Processed/
β”‚   β”œβ”€β”€ X_train.csv              # Processed training features
β”‚   └── X_test.csv               # Processed test features
β”œβ”€β”€ submission_ensemble.csv      # Final ensemble predictions
└── submission_gbr.csv           # GBR model predictions

πŸ“Š Models Used

  • Gradient Boosting Regressor (GBR) – Trained and saved in best_gbr_model.pkl
  • Ensemble Predictions – Combined multiple models for improved accuracy

πŸ€– Recommender System

Implemented a content-based recommender system in 04_recommender_system.ipynb, which suggests similar houses based on numerical and categorical features. It uses:

  • Feature similarity (cosine distance or Euclidean distance)
  • Normalization and vectorization of features
  • Nearest neighbor retrieval

🧰 How to Run

1. Clone the Repository

git clone https://github.com/your-username/house-price-prediction.git
cd house-price-prediction

2. Set Up Environment

pip install -r requirements.txt

3. Run Notebooks

Launch Jupyter or VSCode and open the notebooks in the Notebooks/ directory.


πŸ“¦ Requirements

Install dependencies from requirements.txt:

pip install -r requirements.txt

πŸ“œ License

MIT License – free to use with attribution.


✨ Author

Developed by [Your Name]. Contributions welcome!

About

Machine learning model for predicting house prices with recommender system.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published