A comprehensive movie recommendation system using collaborative filtering (SVD) and content-based filtering (TF-IDF). Provides personalized recommendations based on user preferences and item descriptions.
- Collaborative Filtering using Singular Value Decomposition (SVD)
- Content-Based Filtering using TF-IDF vectorization and cosine similarity
- Hybrid Recommendations combining both collaborative and content-based approaches
- User-Friendly Outputs with real user names and movie titles
-
Clone the repository:
git clone https://github.com/niladrridas/movieml.git cd movieml
-
Create a virtual environment (optional but recommended):
python -m venv venv source venv/bin/activate # On Windows use `venv\Scripts\activate`
-
Install the required libraries:
pip install -r requirements.txt
-
Run Jupyter Notebook:
jupyter notebook
-
Open the notebook:
- Navigate to
main_py.ipynb
and open it.
- Navigate to
-
Follow the steps in the notebook to:
- Load and preprocess the data
- Train the collaborative filtering model using SVD
- Generate content-based recommendations
- Combine both methods in a hybrid recommendation system
- Evaluate the models
main_py.ipynb
: Jupyter Notebook containing the code and explanationsdata/
: Directory to store datasets (users, movies, ratings)requirements.txt
: List of required Python packages
-
Data Loading and Preprocessing:
-
Collaborative Filtering with SVD:
-
Content-Based Filtering:
-
Hybrid Recommendation:
Contributions are welcome! Please open an issue or submit a pull request for any improvements or bug fixes.
This project is licensed under the MIT License. See the LICENSE file for details.
-
Initialize Git in Your Project Directory:
- Open your project folder in VSCode.
- Open the terminal in VSCode (
View
>Terminal
). - Initialize a new Git repository:
git init
-
Add All Files to the Repository:
git add .
-
Commit the Changes:
git commit -m "Initial commit"
-
Create a New Repository on GitHub:
- Go to GitHub and create a new repository. Do not initialize it with a README,
.gitignore
, or license (since you already have these in your local repository).
- Go to GitHub and create a new repository. Do not initialize it with a README,
-
Add the Remote Repository URL:
- Copy the URL of the newly created GitHub repository.
- Add it as a remote in your local Git repository:
git remote add origin https://github.com/niladrridas/movieml.git
-
Push the Local Repository to GitHub:
git push -u origin master