devjas1 commited on
Commit
1751cd3
·
1 Parent(s): ec48f8d

(UI/UX)[UI Update]: Add image analysis tab and wire up image upload interface

Browse files

- Desc:
- Updated the main app UI to introduce a new tab ("Image Analysis") for image-based spectral analysis.
- Changed tab initialization to four tabs: "Standard Analysis", "Model Comparison", "Image Analysis", and "Performance Tracking".
- Wired the new "Image Analysis" tab to use `render_image_upload_interface` from `utils.image_processing`.
- Minor comment corrections for improved clarity regarding tab functions.

Files changed (1) hide show
  1. app.py +14 -5
app.py CHANGED
@@ -1,5 +1,4 @@
1
  # In App.py
2
-
3
  import streamlit as st
4
 
5
  from modules.callbacks import init_session_state
@@ -13,8 +12,8 @@ from modules.ui_components import (
13
  load_css,
14
  )
15
 
 
16
 
17
- # --- Page Setup (Called only ONCE) ---
18
  st.set_page_config(
19
  page_title="ML Polymer Classification",
20
  page_icon="🔬",
@@ -31,9 +30,14 @@ def main():
31
 
32
  render_sidebar()
33
 
34
- # Create main tabs for difference analysis modes
35
- tab1, tab2, tab3 = st.tabs(
36
- ["Standard Analysis", "Model Comparison", "Peformance Tracking"]
 
 
 
 
 
37
  )
38
 
39
  with tab1:
@@ -49,6 +53,11 @@ def main():
49
  render_comparison_tab()
50
 
51
  with tab3:
 
 
 
 
 
52
  # Performance tracking interface
53
  render_performance_tab()
54
 
 
1
  # In App.py
 
2
  import streamlit as st
3
 
4
  from modules.callbacks import init_session_state
 
12
  load_css,
13
  )
14
 
15
+ from utils.image_processing import render_image_upload_interface
16
 
 
17
  st.set_page_config(
18
  page_title="ML Polymer Classification",
19
  page_icon="🔬",
 
30
 
31
  render_sidebar()
32
 
33
+ # Create main tabs for different analysis modes
34
+ tab1, tab2, tab3, tab4 = st.tabs(
35
+ [
36
+ "Standard Analysis",
37
+ "Model Comparison",
38
+ "Image Analysis",
39
+ "Peformance Tracking",
40
+ ]
41
  )
42
 
43
  with tab1:
 
53
  render_comparison_tab()
54
 
55
  with tab3:
56
+ # Image analysis interface
57
+
58
+ render_image_upload_interface()
59
+
60
+ with tab4:
61
  # Performance tracking interface
62
  render_performance_tab()
63