ChinmayBH commited on
Commit
d3e57c7
·
verified ·
1 Parent(s): 1e35526

update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -38,7 +38,10 @@ def main():
38
  input_values = [sepal_length, sepal_width, petal_length, petal_width]
39
  prediction_result = predict_iris_species(trained_model, input_values)
40
 
41
- st.write(f"Predicted Species: {prediction_result[0]}")
 
 
 
42
 
43
  if __name__ == "__main__":
44
  main()
 
38
  input_values = [sepal_length, sepal_width, petal_length, petal_width]
39
  prediction_result = predict_iris_species(trained_model, input_values)
40
 
41
+ species_mapping = {0: 'Iris-setosa', 1: 'Iris-virginica', 2: 'Iris-versicolor'}
42
+ predicted_species = species_mapping.get(prediction_result[0], 'Unknown')
43
+
44
+ st.write(f"Predicted Species: {predicted_species}")
45
 
46
  if __name__ == "__main__":
47
  main()