Skip to content

Machine Learning Application.Recommends the similar products based on users choice that he enters.

Notifications You must be signed in to change notification settings

vshantam/ProductRecommendation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ProductRecommendation

MACHINE LEARNING

It is one of the applications of machine learning.it Recommends the similar products based on users choice that he enters.
This aplication is based on the electronics based products and to build this dataset i have made a dummy dataset of my own.This datasets does not belongs to any e-commerce websites.

CONTENTS

1.Introduction.
2.Requirements and Dependencies.
4.How to run.
5.Snapshots.
6.Outputs
7.References.

INTRODUCTION

alt_tag

This system allows us to recommend the similar kind of products which the user might be interested in , The recommendation is based on the type of products and its specifications is been provided by the user itself.
The algorithm we used in this application is Nearest Neighbors.It provides functionality for unsupervised and supervised neighbors-based learning methods. Unsupervised nearest neighbors is the foundation of many other learning methods, notably manifold learning and spectral clustering. Supervised neighbors-based learning comes in two flavors: classification for data with discrete labels, and regression for data with continuous labels.

More Details can be found here :- http://scikit-learn.org/stable/modules/neighbors.html

REQUIREMENTS/DEPENDENCIES

        numpy >= 1.14.1
        pandas >= 0.22.0
        scikit-learn >= 0.19.1
        pyfiglet >= 0.7.5
        termcolor >= 0.0
        colorama >= 0.3.9

To install the dependencies you can use pip/pip3 commands to install :

    pip install numpy #for python2
    pip3 install numpy #for python3

Or you can use below command to install all dependencies automatically:

    apt-get update && dist-getupgrade; # to update the system, not necessary but recommended.
    pip3 install -r req.txt #python3
    pip install -r req.txt # for python2

HOW TO INSTALL

To run this system please follow the below steps one by one :

step 1: Clone this repository using the command:

    git clone https://github.com/vshantam/ProductRecommendation.git

Screenshot: alt_tag

step 2: Change the directory to project repository .

    cd ProductRecommendation/

Screenshot: alt_tag

step 3: use python commands to run the scripts, i am using ipython version 3 that is why i will run the python scripts using ipython3 interpreter.

commands:

        ipython3 recom.py # It will build the classifier.
        ipython3 main.py # main python script.

if you want to run using python2 or ipython2

in recom.py change the following:

       line no :110 - 111
       
            #obj.save_clf(clf, "clf.sav", _type, 2) #for python2 #uncomment this line.
             obj.save_clf(clf, "clf.pkl", _type, 3) #for python3 #comment this line

in main.py change the following:

    line no : 171 - 172
    
        #print (list2) for python2 #uncomment this line
         print(list1)#for python3 #comment this line

then run the following commands :

commands:

        ipython recom.py #build the classifier in .sav extension
        ipython main.py #main script

By default it is set to run for python3 version.
screenshot:

alt_tag

alt_tag

OUTPUT

Dataset :

alt_tag

Final output:

alt_tag

alt_tag

REFERENCES

    [1] https://en.wikipedia.org/wiki/Recommender_system
    [2] https://en.wikipedia.org/wiki/Knowledge-based_recommender_system
    [3] https://cambridgespark.com/content/tutorials/implementing-your-own-recommender-systems-in-Python/index.html

NOTE:

Make sure you type the product details correctly(spelling) and the specifications which are present in the dataset.

if you are using python2 make sure you take input with quotes i.e " "

This application is built on Linux based system, it will be best to run on the same but it may run on windows also(not tested yet,soon will be updated.)

Recommended using python3 because most of the dependencies works best with python3.
Updated for python2 : Please make changes for running in python2 as mentioned above.

Releases

No releases published

Packages

No packages published

Languages