Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -78,11 +78,12 @@ if st.button("Predict Fault Type"):
|
|
| 78 |
predicted_class = np.argmax(prediction, axis=1)[0]
|
| 79 |
st.success(f"The predicted fault class is: {predicted_class}")
|
| 80 |
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
|
| 84 |
-
|
| 85 |
-
|
| 86 |
-
|
| 87 |
-
|
| 88 |
-
|
|
|
|
|
|
| 78 |
predicted_class = np.argmax(prediction, axis=1)[0]
|
| 79 |
st.success(f"The predicted fault class is: {predicted_class}")
|
| 80 |
|
| 81 |
+
# Plot the entered values as a line chart
|
| 82 |
+
plt.figure(figsize=(10, 4))
|
| 83 |
+
plt.plot(feature_names, input_data, marker='o')
|
| 84 |
+
plt.title("Visualization of Input Features")
|
| 85 |
+
plt.xlabel("Features")
|
| 86 |
+
plt.ylabel("Values")
|
| 87 |
+
plt.xticks(rotation=45)
|
| 88 |
+
plt.grid(True)
|
| 89 |
+
st.pyplot(plt)
|