To receive notifications about scheduled maintenance, please subscribe to the mailing-list gitlab-operations@sympa.ethz.ch. You can subscribe to the mailing-list at https://sympa.ethz.ch

Commit 83e6e3e2 authored by Martyna Plomecka's avatar Martyna Plomecka
Browse files

Ran all simple classifiers

parent f090705f
......@@ -43,7 +43,7 @@ def cross_validate_RFC(X, y):
cross_validate(classifier=classifier, parameters=parameters_RFC, X=X, y=y)
def cross_validate(classifier, parameters, X, y):
X = X.reshape((100, 500 * 129))
X = X.reshape((36223, 500 * 129))
clf = GridSearchCV(classifier, parameters, scoring='accuracy', n_jobs=-1, verbose=3)
clf.fit(X, y.ravel())
......@@ -65,13 +65,13 @@ def try_sklearn_classifiers(X, y):
]
classifiers = [
KNeighborsClassifier(n_neighbors=5, weights='uniform', algorithm='auto', leaf_size=30, n_jobs=-1),
KNeighborsClassifier(n_neighbors=100, weights='uniform', algorithm='auto', leaf_size=100, n_jobs=-1),
LinearSVC(tol=1e-5, C=1, random_state=42, max_iter=10000),
RandomForestClassifier(n_estimators=100, max_depth=5, max_features='auto', random_state=42, n_jobs=-1),
RandomForestClassifier(n_estimators=1000, max_depth=50, max_features='auto', random_state=42, n_jobs=-1),
GaussianNB()
]
X = X.reshape((100, 500 * 129))
X = X.reshape((36223, 500 * 129))
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=.2, random_state=42)
scores = []
......@@ -98,4 +98,4 @@ def export_dict(*columns, first_row, file_name):
writer = csv.writer(f)
writer.writerow(first_row)
for row in rows:
writer.writerow(row)
\ No newline at end of file
writer.writerow(row)
Sender: LSF System <lsfadmin@lo-s4-062>
Subject: Job 15337755: <python /cluster/home/mplomecka/dl-project/main.py> in cluster <leonhard> Done
Job <python /cluster/home/mplomecka/dl-project/main.py> was submitted from host <lo-login-02> by user <mplomecka> in cluster <leonhard> at Tue Mar 23 17:49:39 2021
Job was executed on host(s) <5*lo-s4-062>, in queue <gpu.24h>, as user <mplomecka> in cluster <leonhard> at Tue Mar 23 17:49:48 2021
</cluster/home/mplomecka> was used as the home directory.
</cluster/home/mplomecka/dl-project> was used as the working directory.
Started at Tue Mar 23 17:49:48 2021
Terminated at Wed Mar 24 03:39:47 2021
Results reported at Wed Mar 24 03:39:47 2021
Your job looked like:
------------------------------------------------------------
# LSBATCH: User input
python /cluster/home/mplomecka/dl-project/main.py
------------------------------------------------------------
Successfully completed.
Resource usage summary:
CPU time : 77840.79 sec.
Max Memory : 94853 MB
Average Memory : 90371.99 MB
Total Requested Memory : 125000.00 MB
Delta Memory : 30147.00 MB
Max Swap : -
Max Processes : 3
Max Threads : 17
Run time : 35422 sec.
Turnaround time : 35408 sec.
The output (if any) follows:
2021-03-23 17:49:52.399853: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library libcudart.so.10.1
(36223, 500, 129)
(36223, 1)
/cluster/apps/python/3.8.5_gpu_gcc630/x86_64/lib64/python3.8/site-packages/sklearn/svm/_base.py:976: ConvergenceWarning: Liblinear failed to converge, increase the number of iterations.
warnings.warn("Liblinear failed to converge, increase "
......@@ -48,8 +48,8 @@ def main():
print(trainY.shape)
if config['model'] == 'simple_classifier':
# try_sklearn_classifiers(trainX, trainY)
cross_validate_kNN(trainX, trainY)
try_sklearn_classifiers(trainX, trainY)
# cross_validate_kNN(trainX, trainY)
# cross_validate_SVC(trainX, trainY)
# cross_validate_RFC(trainX, trainY)
else:
......@@ -62,4 +62,4 @@ def main():
logging.info('Finished Logging')
if __name__=='__main__':
main()
\ No newline at end of file
main()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment