Ver código fonte

update gpu version params

Jérôme BUISINE 4 anos atrás
pai
commit
f38dd28820
3 arquivos alterados com 7 adições e 3 exclusões
  1. 3 0
      .gitmodules
  2. 1 0
      macop
  3. 3 3
      models.py

+ 3 - 0
.gitmodules

@@ -1,3 +1,6 @@
 [submodule "modules"]
 	path = modules
 	url = https://github.com/prise-3d/Thesis-CommonModules.git
+[submodule "macop"]
+	path = macop
+	url = https://github.com/jbuisine/macop.git

+ 1 - 0
macop

@@ -0,0 +1 @@
+Subproject commit b6eb599a1627193963fd9ae7796337f13a48d312

+ 3 - 3
models.py

@@ -41,12 +41,12 @@ def svm_model(X_train, y_train):
 
 def _get_best_gpu_model(X_train, y_train):
 
-    Cs = [0.001, 0.01, 0.1, 1, 2, 5, 10, 100, 1000]
-    gammas = [0.001, 0.01, 0.1, 1, 2, 5, 10, 100]
+    Cs = [0.001, 0.01, 0.1, 1, 10, 100, 1000]
+    gammas = [0.001, 0.01, 0.1, 5, 10, 100]
     param_grid = {'kernel':['rbf'], 'C': Cs, 'gamma' : gammas}
 
     svc = SVC(probability=True, class_weight='balanced')
-    clf = GridSearchCV(svc, param_grid, cv=10, verbose=1, scoring=my_accuracy_scorer, n_jobs=-1)
+    clf = GridSearchCV(svc, param_grid, cv=5, verbose=1, scoring=my_accuracy_scorer, n_jobs=-1)
 
     clf.fit(X_train, y_train)