File size: 3,137 Bytes
782e635
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
"""
Sidebar Component for DermaScan AI
"""
import streamlit as st


def render_sidebar(state_cities):
    """
    Render the sidebar with location selection and information
    
    Args:
        state_cities: Dictionary of states and their cities
        
    Returns:
        tuple: (selected_state, selected_city)
    """
    with st.sidebar:
        st.markdown("### ๐Ÿ“ Location")
        selected_state = st.selectbox(
            "State", 
            list(state_cities.keys()), 
            index=list(state_cities.keys()).index("Delhi")
        )
        cities = state_cities.get(selected_state, ["Other"])
        selected_city = st.selectbox("City", cities, index=0)

        st.markdown("---")
        st.markdown("### ๐Ÿ”ฌ About DermaScan AI")
        st.markdown("""
        <div class="pro-card" style="font-size:0.85rem;">
            <p style="margin-bottom:0.8rem;">
                Advanced AI-powered dermatology analysis system using deep learning 
                to detect and classify skin conditions.
            </p>
            <p style="margin-bottom:0.5rem;"><strong>๐Ÿง  Technology</strong></p>
            <p style="margin-bottom:0.8rem;color:#cbd5e1;">
                โ€ข EfficientNet-B3 Architecture<br>
                โ€ข 96% AUC-ROC Accuracy<br>
                โ€ข Real-time Analysis
            </p>
            <p style="margin-bottom:0.5rem;"><strong>๐Ÿ”ฌ Detects 13 Conditions</strong></p>
            <p style="margin-bottom:0.8rem;color:#cbd5e1;">
                โ€ข 3 Cancer Types<br>
                โ€ข 4 Benign Conditions<br>
                โ€ข 6 Skin Diseases
            </p>
            <p style="margin-bottom:0.5rem;"><strong>๐Ÿ“Š Training Data</strong></p>
            <p style="color:#cbd5e1;">
                โ€ข HAM10000 Dataset<br>
                โ€ข DermNet Collection<br>
                โ€ข 10,000+ Images
            </p>
        </div>
        """, unsafe_allow_html=True)

        st.markdown("---")
        st.markdown("### ๐Ÿšจ Emergency Contacts")
        st.markdown("""
        <div class="emergency-card">
            <h4>๐Ÿ‡ฎ๐Ÿ‡ณ India Helplines</h4>
            <p>๐Ÿšจ Emergency: <b>112</b></p>
            <p>๐Ÿš‘ Ambulance: <b>108</b></p>
            <p>๐Ÿฅ Health: <b>104</b></p>
            <p>๐ŸŽ—๏ธ Cancer: <b>1800-11-6006</b></p>
        </div>
        """, unsafe_allow_html=True)

        st.markdown("---")
        st.markdown("### โš•๏ธ Medical Disclaimer")
        st.markdown("""
        <div style="font-size:0.75rem;color:#94a3b8;line-height:1.5;padding:0.5rem;">
            This AI tool is for educational and screening purposes only. 
            It is NOT a substitute for professional medical diagnosis. 
            Always consult a qualified dermatologist for proper evaluation.
        </div>
        """, unsafe_allow_html=True)

        st.markdown("---")
        st.markdown(
            "<p style='text-align:center;color:#94a3b8;font-size:0.75rem;font-weight:600;'>"
            "๐Ÿฅ DermaScan AI v1.0<br>Medical Grade Analysis</p>",
            unsafe_allow_html=True,
        )
    
    return selected_state, selected_city