Sellibro commited on
Commit
c42d9f5
·
1 Parent(s): a2eca5b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -56,9 +56,9 @@ def malware_detection_DL (results, malicious_traffic, benign_traffic):
56
  model.compile(optimizer ='adam',
57
  loss = 'binary_crossentropy',
58
  metrics = ['accuracy'])
59
- #model.fit(x_train, y_train, batch_size=32, epochs = 150, validation_data=(x_test, y_test))
60
- #does not output epochs and gives evalutaion of validation data and history of losses and accuracy
61
- history = model.fit(x_train, y_train, batch_size=32, epochs = 50,verbose=0, validation_data=(x_test, y_test))
62
  _, accuracy = model.evaluate(x_train, y_train)
63
  #return history.history
64
  if results=="Accuracy":
@@ -91,4 +91,4 @@ iface = gr.Interface(
91
 
92
  )
93
 
94
- iface.launch()
 
56
  model.compile(optimizer ='adam',
57
  loss = 'binary_crossentropy',
58
  metrics = ['accuracy'])
59
+
60
+ #does not output epochs and gives evalutaion of validation data and history of losses and accuracy, epochs lowered to 10 from 150 for speed in displaying plot
61
+ history = model.fit(x_train, y_train, batch_size=32, epochs = 30,verbose=0, validation_data=(x_test, y_test))
62
  _, accuracy = model.evaluate(x_train, y_train)
63
  #return history.history
64
  if results=="Accuracy":
 
91
 
92
  )
93
 
94
+ iface.launch(enable_queue =True)