awacke1 commited on
Commit
bb18704
·
1 Parent(s): f57fd10

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +53 -0
app.py CHANGED
@@ -141,8 +141,61 @@ def link_button_with_emoji(url, title, emoji_summary):
141
  random_emoji = random.choice(emojis)
142
  st.markdown(f"[{random_emoji} {emoji_summary} - {title}]({url})")
143
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
144
  # Define function to add paper buttons and links
145
  def add_paper_buttons_and_links():
 
 
 
 
 
 
 
146
  col1, col2, col3, col4 = st.columns(4)
147
 
148
  with col1:
 
141
  random_emoji = random.choice(emojis)
142
  st.markdown(f"[{random_emoji} {emoji_summary} - {title}]({url})")
143
 
144
+ import streamlit as st
145
+
146
+ # Homunculus parts and their corresponding emojis
147
+ homunculus_parts = {
148
+ "Head": "🧠", "Left Eye": "👁️", "Right Eye": "👁️",
149
+ "Left Eyebrow": "🤨", "Right Eyebrow": "🤨", "Nose": "👃",
150
+ "Mouth": "👄", "Neck": "🧣", "Left Shoulder": "💪",
151
+ "Right Shoulder": "💪", "Left Upper Arm": "💪",
152
+ "Right Upper Arm": "💪", "Left Elbow": "💪",
153
+ "Right Elbow": "💪", "Left Forearm": "💪",
154
+ "Right Forearm": "💪", "Left Wrist": "✊",
155
+ "Right Wrist": "✊", "Left Hand": "🤲",
156
+ "Right Hand": "🤲", "Chest": "👕",
157
+ "Abdomen": "👕", "Pelvis": "🩲",
158
+ "Left Hip": "🦵", "Right Hip": "🦵",
159
+ "Left Thigh": "🦵", "Right Thigh": "🦵",
160
+ "Left Knee": "🦵", "Right Knee": "🦵",
161
+ "Left Shin": "🦵", "Right Shin": "🦵"
162
+ }
163
+
164
+ # Function to display the homunculus parts with expanders
165
+ def display_homunculus_parts():
166
+ st.title("Homunculus Model")
167
+
168
+ # Container parts
169
+ with st.expander("Head (🧠)", expanded=False):
170
+ st.write("Contains: Left Eye 👁️, Right Eye 👁️, Left Eyebrow 🤨, Right Eyebrow 🤨, Nose 👃, Mouth 👄")
171
+
172
+ # Symmetric body parts (Left & Right)
173
+ for part in ["Shoulder", "Upper Arm", "Elbow", "Forearm", "Wrist", "Hand", "Hip", "Thigh", "Knee", "Shin"]:
174
+ col1, col2 = st.columns(2)
175
+ with col1:
176
+ with st.expander(f"Left {part} (💪)", expanded=False):
177
+ st.write(f"Details about the Left {part}")
178
+ with col2:
179
+ with st.expander(f"Right {part} (💪)", expanded=False):
180
+ st.write(f"Details about the Right {part}")
181
+
182
+ # Central body parts
183
+ for part in ["Neck", "Chest", "Abdomen", "Pelvis"]:
184
+ with st.expander(f"{part} ({homunculus_parts[part]})", expanded=False):
185
+ st.write(f"Details about the {part}")
186
+
187
+
188
+
189
+
190
  # Define function to add paper buttons and links
191
  def add_paper_buttons_and_links():
192
+
193
+
194
+ page = st.sidebar.radio("Choose a page:", ["Homunculus Model"])
195
+ if page == "Homunculus Model":
196
+ display_homunculus_parts()
197
+
198
+
199
  col1, col2, col3, col4 = st.columns(4)
200
 
201
  with col1: