rasmodev commited on
Commit
dd8cdb5
·
1 Parent(s): 3cccc27

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -10
app.py CHANGED
@@ -3,12 +3,9 @@ import pickle
3
  import pandas as pd
4
  import numpy as np
5
 
6
- # About Section with Style
7
- st.sidebar.title("ℹ️ About")
8
- st.sidebar.info(
9
- "This app predicts sepsis based on medical input data. "
10
- "It uses a machine learning model trained on a dataset of sepsis cases."
11
- )
12
 
13
  # Welcome Message with Style
14
  st.write(
@@ -16,6 +13,13 @@ st.write(
16
  "click 'Predict Sepsis', and get the prediction result."
17
  )
18
 
 
 
 
 
 
 
 
19
  # Load the model and key components
20
  with open('model_and_key_components.pkl', 'rb') as file:
21
  loaded_components = pickle.load(file)
@@ -36,9 +40,6 @@ data_fields = {
36
  "Age": "Age of the patient (years)"
37
  }
38
 
39
- # Page Title with Style
40
- st.title("🩸 Sepsis Prediction App")
41
- st.markdown("---")
42
 
43
  # Sidebar with Data Fields
44
  st.sidebar.title("📊 Input Data")
@@ -70,4 +71,4 @@ if st.sidebar.button("🔮 Predict Sepsis"):
70
  # Display Data Fields and Descriptions
71
  st.sidebar.title("🔍 Data Fields")
72
  for field, description in data_fields.items():
73
- st.sidebar.text(f"{field}: {description}")
 
3
  import pandas as pd
4
  import numpy as np
5
 
6
+ # Page Title with Style
7
+ st.title("🩸 Sepsis Prediction App")
8
+ st.markdown("---")
 
 
 
9
 
10
  # Welcome Message with Style
11
  st.write(
 
13
  "click 'Predict Sepsis', and get the prediction result."
14
  )
15
 
16
+ # About Section with Style
17
+ st.sidebar.title("ℹ️ About")
18
+ st.sidebar.info(
19
+ "This app predicts sepsis based on medical input data. "
20
+ "It uses a machine learning model trained on a dataset of sepsis cases."
21
+ )
22
+
23
  # Load the model and key components
24
  with open('model_and_key_components.pkl', 'rb') as file:
25
  loaded_components = pickle.load(file)
 
40
  "Age": "Age of the patient (years)"
41
  }
42
 
 
 
 
43
 
44
  # Sidebar with Data Fields
45
  st.sidebar.title("📊 Input Data")
 
71
  # Display Data Fields and Descriptions
72
  st.sidebar.title("🔍 Data Fields")
73
  for field, description in data_fields.items():
74
+ st.sidebar.text(f"{field}: {description}")