Skip to content

Commit

Permalink
Grid KNN Model Saved
Browse files Browse the repository at this point in the history
  • Loading branch information
kartik2112 committed Feb 18, 2018
1 parent 1b1b0cc commit de6c97e
Show file tree
Hide file tree
Showing 61 changed files with 194 additions and 385,501 deletions.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
training-images.zip filter=lfs diff=lfs merge=lfs -text
*.csv filter=lfs diff=lfs merge=lfs -text
657 changes: 3 additions & 654 deletions CCDC-Data/training-images/Digits/0/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

657 changes: 3 additions & 654 deletions CCDC-Data/training-images/Digits/0/data.csv

Large diffs are not rendered by default.

80 changes: 3 additions & 77 deletions CCDC-Data/training-images/Digits/1/Right_Hand/Rotated/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/1/data.csv

Large diffs are not rendered by default.

657 changes: 3 additions & 654 deletions CCDC-Data/training-images/Digits/2/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

51 changes: 3 additions & 48 deletions CCDC-Data/training-images/Digits/2/Right_Hand/Rotated/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/2/data.csv

Large diffs are not rendered by default.

685 changes: 3 additions & 682 deletions CCDC-Data/training-images/Digits/3/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

102 changes: 3 additions & 99 deletions CCDC-Data/training-images/Digits/3/Right_Hand/Rotated/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/3/data.csv

Large diffs are not rendered by default.

642 changes: 3 additions & 639 deletions CCDC-Data/training-images/Digits/4/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

162 changes: 3 additions & 159 deletions CCDC-Data/training-images/Digits/4/Right_Hand/Rotated/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/4/data.csv

Large diffs are not rendered by default.

312 changes: 3 additions & 309 deletions CCDC-Data/training-images/Digits/5/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

221 changes: 3 additions & 218 deletions CCDC-Data/training-images/Digits/5/Right_Hand/Rotated/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/5/data.csv

Large diffs are not rendered by default.

736 changes: 3 additions & 733 deletions CCDC-Data/training-images/Digits/6/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/6/data.csv

Large diffs are not rendered by default.

676 changes: 3 additions & 673 deletions CCDC-Data/training-images/Digits/7/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/7/data.csv

Large diffs are not rendered by default.

672 changes: 3 additions & 669 deletions CCDC-Data/training-images/Digits/8/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/8/data.csv

Large diffs are not rendered by default.

638 changes: 3 additions & 635 deletions CCDC-Data/training-images/Digits/9/Right_Hand/Normal/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Digits/9/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/a/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/b/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/c/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/d/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/e/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/f/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/g/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/i/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/k/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/l/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/m/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/n/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/o/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/p/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/q/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/r/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/s/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/t/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/u/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/w/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/x/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/y/data.csv

Large diffs are not rendered by default.

303 changes: 3 additions & 300 deletions CCDC-Data/training-images/Letters/z/data.csv

Large diffs are not rendered by default.

12 changes: 3 additions & 9 deletions Hand sign classification/Test cases.csv
Git LFS file not shown
19,603 changes: 3 additions & 19,600 deletions Hand sign classification/data.csv

Large diffs are not rendered by default.

19,603 changes: 3 additions & 19,600 deletions Hand sign classification/new_data.csv

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions Jugaad/createModel.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import pandas as pd
from sklearn.model_selection import train_test_split as tts
from sklearn.metrics import confusion_matrix
from sklearn.neighbors import KNeighborsClassifier
import pickle

data = pd.read_csv('new_data.csv')

X = data[['f'+str(i) for i in range(400)]].values
Y = data['label'].values

classifier = KNeighborsClassifier(n_neighbors=3)
classifier.fit(X, Y)

pickle.dump(classifier, open('KNN_Grid_ModelDump.sav','wb'))
print("Model saved as 'KNN_Grid_ModelDump.sav'")
10 changes: 3 additions & 7 deletions Jugaad/detectSign_SK.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,10 @@
from sklearn.model_selection import train_test_split as tts
from sklearn.metrics import confusion_matrix
from sklearn.neighbors import KNeighborsClassifier
import pickle

data = pd.read_csv('new_data.csv')

X = data[['f'+str(i) for i in range(400)]].values
Y = data['label'].values

classifier = KNeighborsClassifier(n_neighbors=3)
classifier.fit(X, Y)
classifier = pickle.load(open('KNNModelDump.sav','rb'))
print("Loaded KNN Model")

grid = (20,20)

Expand Down
19,603 changes: 3 additions & 19,600 deletions Jugaad/new_data.csv

Large diffs are not rendered by default.

Loading

0 comments on commit de6c97e

Please sign in to comment.