Downloads · 30 days
0
omerbasik1/house-price-model
house-price-model is a machine learning model from omerbasik1. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
House Price Prediction and Classification Models Assignment 2 – Machine Learning
Downloads · 30 days
0
Access
Public
Updated Dec 30, 2025
Repo size
87.2 MB
Likes
1
Public
Click a slice to open those files.
.csv58.7 MB · 64%
From the Hugging Face model README
House Price Prediction and Classification Models
Assignment #2 – Machine Learning
This repository contains my full solution for Assignment #2.
The project includes a complete machine learning pipeline with data cleaning, exploratory data analysis, feature engineering, clustering, regression models, classification models, evaluation, and model deployment.
video link - https://share.descript.com/view/aKOwykkMSex
Repository link:
https://huggingface.co/omerbasik1/house-price-model/tree/main
Dataset Overview
The dataset contains approximately 316,000 real estate listings.
It includes both numeric and categorical features such as:
The main goals of the project are:
Data Cleaning and Exploratory Data Analysis (EDA)
The data was cleaned and prepared before modeling.
The main cleaning steps included:
During the EDA stage, multiple visualizations were created to understand the structure of the data:


Key findings from the EDA:

Baseline Regression Model
A baseline Linear Regression model was trained using the cleaned dataset.
The data was split into training and testing sets, and numeric features were scaled before training.

Evaluation metrics included:
The baseline model achieved moderate performance and was mainly used as a reference point for measuring the impact of feature engineering and more advanced models.
Feature Engineering and Clustering
To improve model performance, several feature engineering techniques were applied.
New engineered features:
Polynomial and interaction features:
Clustering:
K-Means clustering was applied to group similar apartments based on key features such as area, price per square meter, building age and room count.
From this process, additional features were created:
A unified preprocessing pipeline was built using:
Improved Regression Models and Results
Three regression models were trained and evaluated using the engineered dataset:
The Random Forest model achieved the best performance with the lowest RMSE and the highest R² score.
Therefore, it was selected as the final regression model and exported as:
winning_model.pkl
Regression to Classification

The regression problem was converted into a binary classification problem using a median split on apartment prices:
The class distribution remained balanced, allowing stable training of classification models.
Three classifiers were trained:
The models were evaluated using:
The Gradient Boosting classifier achieved the best classification performance and was selected as the final classification model.
It was exported as:
best_classifier.pkl
Repository Files
The repository contains the following key files:
Final Summary
This project demonstrates a full machine learning workflow: data cleaning, exploratory analysis, feature engineering, clustering, regression modeling, classification modeling, evaluation, and deployment.
Both the regression and classification models were exported and uploaded to the HuggingFace repository so they can be reused for future predictions.
Author: Omer Basik
Course: Machine Learning – Assignment #2