From 4a49e5d82954448ea1132d561467dae5adf5cbf6 Mon Sep 17 00:00:00 2001 From: Aniela Date: Wed, 25 May 2022 20:20:09 +0200 Subject: [PATCH] =?UTF-8?q?sie=C4=87=20neuronowa,=20rozpoznawanie=20cyfry?= =?UTF-8?q?=20z=20obrazka=20oraz=20testowe=20cyfry?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .idea/Sztuczna_Inteligencja_Gr16.iml | 2 +- .idea/misc.xml | 2 +- main.py | 3 ++- rescue.py | 6 +++--- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.idea/Sztuczna_Inteligencja_Gr16.iml b/.idea/Sztuczna_Inteligencja_Gr16.iml index 4335812..a95d100 100644 --- a/.idea/Sztuczna_Inteligencja_Gr16.iml +++ b/.idea/Sztuczna_Inteligencja_Gr16.iml @@ -4,7 +4,7 @@ - + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml index 0a4fd2a..3bc1cab 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,4 +1,4 @@ - + \ No newline at end of file diff --git a/main.py b/main.py index 926ecb2..b41fd76 100644 --- a/main.py +++ b/main.py @@ -8,7 +8,7 @@ from agent import * from okno import * from ramy_czyli_wiedza_agenta import * from rescue import * - +from neural_network import * # aby działalo w oknie + rozdzielczość ekranu # ctypes.windll.shcore.SetProcessDpiAwareness(1) @@ -146,6 +146,7 @@ def main(): pygame.time.wait(1500) flaga1 = 0 t = threading.Timer(5.0, zdarzenie_osoba).start() + recognition() try: main() diff --git a/rescue.py b/rescue.py index 313e02e..2d893fa 100644 --- a/rescue.py +++ b/rescue.py @@ -17,9 +17,9 @@ def drzewo_decyzyjne(): clf = clf.fit(x, y) # print("Dokładność: ", metrics.accuracy_score(y_test, y_pred)) - dot_data = tree.export_graphviz(clf, out_file=None, feature_names=kolumny_x, class_names=['0', '1']) - graph = pydotplus.graph_from_dot_data(dot_data) - graph.write_png('drzewo.png') + # dot_data = tree.export_graphviz(clf, out_file=None, feature_names=kolumny_x, class_names=['0', '1']) + # graph = pydotplus.graph_from_dot_data(dot_data) + #graph.write_png('drzewo.png') return clf