Update app.py
Browse files
app.py
CHANGED
@@ -25,7 +25,7 @@ def titanic(age, sex, pclass, fare):
|
|
25 |
res = model.predict(np.asarray(input_list).reshape(1, -1))
|
26 |
# We add '[0]' to the result of the transformed 'res', because 'res' is a list, and we only want
|
27 |
# the first element.
|
28 |
-
if res == 0:
|
29 |
output = "This individual probably survived the Titanic."
|
30 |
else:
|
31 |
output = "This individual unfortunately probably did not survive the Titanic."
|
|
|
25 |
res = model.predict(np.asarray(input_list).reshape(1, -1))
|
26 |
# We add '[0]' to the result of the transformed 'res', because 'res' is a list, and we only want
|
27 |
# the first element.
|
28 |
+
if res[0] == 0:
|
29 |
output = "This individual probably survived the Titanic."
|
30 |
else:
|
31 |
output = "This individual unfortunately probably did not survive the Titanic."
|