From c7ecb5835f8545bb4e1fbe9f34acd2c58149965f Mon Sep 17 00:00:00 2001 From: Kamila Bobkowska Date: Mon, 11 May 2020 09:25:37 +0000 Subject: [PATCH] changing a mistake --- models/Garbagetruck.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/models/Garbagetruck.py b/models/Garbagetruck.py index b830e03..91f18c3 100644 --- a/models/Garbagetruck.py +++ b/models/Garbagetruck.py @@ -158,7 +158,7 @@ class GarbageTruck(): classifier.add(Flatten()) classifier.add(Dense(activation = "relu", units = 64 )) classifier.add(Dense(activation = "softmax", units = 5)) - classifier.compile(optimizer = "adam", loss = "binary_crossentropy", metrics = ["accuracy"]) + classifier.compile(optimizer = "adam", loss = "categorical_crossentropy", metrics = ["accuracy"]) train_datagen = ImageDataGenerator( @@ -196,7 +196,7 @@ class GarbageTruck(): test_x, test_y = test_generator.__getitem__(1) whatarewe = [] - classifier.load_weights("model_ver_5.h5") + classifier.load_weights("model_ver_6.h5") ''' #optional for displaying the trash and what the CNN decided it is z=1 '''