Upload folder using huggingface_hub
Browse files
app.py
CHANGED
|
@@ -46,16 +46,7 @@ if st.button("Predict"):
|
|
| 46 |
|
| 47 |
prediction = model.predict(input_df)[0]
|
| 48 |
|
| 49 |
-
label = "
|
| 50 |
|
| 51 |
st.success(f"Engine Condition: {label}")
|
| 52 |
|
| 53 |
-
# Save input + prediction
|
| 54 |
-
input_df["Engine Condition"] = prediction
|
| 55 |
-
input_df.to_csv(
|
| 56 |
-
"inputs.csv",
|
| 57 |
-
mode="a",
|
| 58 |
-
header=not st.session_state.get("logged", False),
|
| 59 |
-
index=False
|
| 60 |
-
)
|
| 61 |
-
st.session_state["logged"] = True
|
|
|
|
| 46 |
|
| 47 |
prediction = model.predict(input_df)[0]
|
| 48 |
|
| 49 |
+
label = "FAULTY" if prediction == 1 else "NORMAL"
|
| 50 |
|
| 51 |
st.success(f"Engine Condition: {label}")
|
| 52 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|