prakharg24 commited on
Commit
930fa5e
·
verified ·
1 Parent(s): dd9ea9c

Update my_pages/multiverse.py

Browse files
Files changed (1) hide show
  1. my_pages/multiverse.py +15 -23
my_pages/multiverse.py CHANGED
@@ -4,30 +4,22 @@ import plotly.graph_objects as go
4
  from utils import go_to
5
 
6
  choices_list = [
7
- {"label": "Data Collection", "icon": "📥", "questions": [
8
- "Where will you source the data from?",
9
- "How will you ensure data quality?",
10
- "Will you balance classes?"
11
  ]},
12
- {"label": "Preprocessing", "icon": "🛠️", "questions": [
13
- "What features will you select?",
14
- "Will you impute missing values or remove them?",
15
- "How will you handle outliers?"
16
  ]},
17
- {"label": "Model Selection", "icon": "🤖", "questions": [
18
- "Which algorithms will you consider?",
19
- "Will you use pre-trained models?",
20
- "How will you handle hyperparameters?"
21
  ]},
22
- {"label": "Training", "icon": "🏋️", "questions": [
23
- "What loss function will you use?",
24
- "How will you split train/validation?",
25
- "Will you use early stopping?"
26
- ]},
27
- {"label": "Evaluation", "icon": "📊", "questions": [
28
- "What metrics will you use?",
29
- "Will you test on unseen data?",
30
- "Will you consider fairness metrics?"
31
  ]}
32
  ]
33
 
@@ -47,7 +39,7 @@ def build_tree_and_trace_path(selected_path):
47
 
48
  # Build nodes and edges stage by stage
49
  for stage_idx, stage in enumerate(choices_list, start=1):
50
- options = stage["questions"]
51
  next_nodes = []
52
 
53
  # For layout niceness: compute a span for children under each parent
@@ -112,7 +104,7 @@ def render():
112
  for stage in choices_list:
113
  # use a stable key per stage to avoid conflicts
114
  key = f"multiverse_choice_{stage['label']}"
115
- choice = st.selectbox(f"{stage['icon']} {stage['label']}", stage["questions"], key=key)
116
  selected_path.append(choice)
117
 
118
  # --- Build tree and compute which edges/nodes to highlight ---
 
4
  from utils import go_to
5
 
6
  choices_list = [
7
+ {"label": "Data Scaling", "options": [
8
+ "MinMax Scaler",
9
+ "Standard Scaler"
 
10
  ]},
11
+ {"label": "Model Architecture", "options": [
12
+ "Logistic Regression",
13
+ "Random Forest",
14
+ "Neural Network (Small)"
15
  ]},
16
+ {"label": "Training Iterations", "options": [
17
+ "200",
18
+ "500",
19
+ "1000"
20
  ]},
21
+ {"label": "Random Seed", "options": [
22
+ "1", "2", "3", "4", "5", "6", "7", "8", "9", "10"
 
 
 
 
 
 
 
23
  ]}
24
  ]
25
 
 
39
 
40
  # Build nodes and edges stage by stage
41
  for stage_idx, stage in enumerate(choices_list, start=1):
42
+ options = stage["options"]
43
  next_nodes = []
44
 
45
  # For layout niceness: compute a span for children under each parent
 
104
  for stage in choices_list:
105
  # use a stable key per stage to avoid conflicts
106
  key = f"multiverse_choice_{stage['label']}"
107
+ choice = st.selectbox(f"{stage['label']}", stage["options"], key=key)
108
  selected_path.append(choice)
109
 
110
  # --- Build tree and compute which edges/nodes to highlight ---