Spaces:
Sleeping
Sleeping
GitsSaikat
commited on
Update safetyapp.py
Browse files- safetyapp.py +14 -11
safetyapp.py
CHANGED
|
@@ -27,16 +27,19 @@ X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=test_size, r
|
|
| 27 |
st.set_page_config(page_title="Evaluating Safety Perception on Commuting App", layout='wide')
|
| 28 |
st.title("Evaluating Safety Perception on Commuting ")
|
| 29 |
|
| 30 |
-
# Sidebar
|
| 31 |
-
|
| 32 |
-
"
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
"
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
|
|
|
|
|
|
|
|
|
| 40 |
|
| 41 |
# Data Overview
|
| 42 |
if selected == "๐ Data Overview":
|
|
@@ -155,4 +158,4 @@ if selected == "๐ฎ Predict Percieved Safety":
|
|
| 155 |
prediction = model.predict(user_data)
|
| 156 |
predicted_class = le.inverse_transform(prediction)
|
| 157 |
|
| 158 |
-
st.write(f"Predicted Percieved Safety Class: {predicted_class[0]}")
|
|
|
|
| 27 |
st.set_page_config(page_title="Evaluating Safety Perception on Commuting App", layout='wide')
|
| 28 |
st.title("Evaluating Safety Perception on Commuting ")
|
| 29 |
|
| 30 |
+
# Sidebar section
|
| 31 |
+
with st.sidebar:
|
| 32 |
+
st.image("logo.png", use_column_width=True, caption="Your Company Name")
|
| 33 |
+
st.markdown("---")
|
| 34 |
+
selected = st.selectbox(
|
| 35 |
+
"Navigation",
|
| 36 |
+
[
|
| 37 |
+
"๐ Data Overview",
|
| 38 |
+
"๐ Exploratory Data Analysis",
|
| 39 |
+
"๐ค Model Training, Evaluation & Explanations",
|
| 40 |
+
"๐ฎ Predict Perceived Safety"
|
| 41 |
+
]
|
| 42 |
+
)
|
| 43 |
|
| 44 |
# Data Overview
|
| 45 |
if selected == "๐ Data Overview":
|
|
|
|
| 158 |
prediction = model.predict(user_data)
|
| 159 |
predicted_class = le.inverse_transform(prediction)
|
| 160 |
|
| 161 |
+
st.write(f"Predicted Percieved Safety Class: {predicted_class[0]}")
|