Spaces:
Sleeping
Sleeping
Upload folder using huggingface_hub
Browse files
app.py
CHANGED
@@ -29,16 +29,7 @@ st.markdown("""
|
|
29 |
.title {
|
30 |
font-size: 3.2rem;
|
31 |
text-align: center;
|
32 |
-
|
33 |
-
-webkit-background-clip: text;
|
34 |
-
-webkit-text-fill-color: transparent;
|
35 |
-
background-clip: text;
|
36 |
-
}
|
37 |
-
|
38 |
-
@keyframes gradientShift {
|
39 |
-
0% { background-position: 0% 50%; }
|
40 |
-
50% { background-position: 100% 50%; }
|
41 |
-
100% { background-position: 0% 50%; }
|
42 |
}
|
43 |
.subheader {
|
44 |
font-size: 1.5rem;
|
@@ -75,59 +66,6 @@ st.markdown("""
|
|
75 |
</style>
|
76 |
""", unsafe_allow_html=True)
|
77 |
|
78 |
-
# # Custom CSS for better layout and mobile responsiveness
|
79 |
-
# st.markdown("""
|
80 |
-
# <style>
|
81 |
-
# .main {
|
82 |
-
# max-width: 1200px; /* Max width for content */
|
83 |
-
# margin: 0 auto;
|
84 |
-
# }
|
85 |
-
# .block-container {
|
86 |
-
# padding-top: 2rem;
|
87 |
-
# padding-bottom: 2rem;
|
88 |
-
# padding-left: 3rem;
|
89 |
-
# padding-right: 3rem;
|
90 |
-
# }
|
91 |
-
# .title {
|
92 |
-
# font-size: 2.5rem;
|
93 |
-
# text-align: center;
|
94 |
-
# color: #FF6347;
|
95 |
-
# }
|
96 |
-
# .subheader {
|
97 |
-
# font-size: 1.5rem;
|
98 |
-
# margin-bottom: 20px;
|
99 |
-
# }
|
100 |
-
# .btn {
|
101 |
-
# font-size: 1.1rem;
|
102 |
-
# padding: 10px 20px;
|
103 |
-
# background-color: #FF6347;
|
104 |
-
# color: white;
|
105 |
-
# border-radius: 5px;
|
106 |
-
# border: none;
|
107 |
-
# cursor: pointer;
|
108 |
-
# }
|
109 |
-
# .btn:hover {
|
110 |
-
# background-color: #FF4500;
|
111 |
-
# }
|
112 |
-
# .column-spacing {
|
113 |
-
# display: flex;
|
114 |
-
# justify-content: space-between;
|
115 |
-
# }
|
116 |
-
# .col-half {
|
117 |
-
# width: 48%;
|
118 |
-
# }
|
119 |
-
# .col-full {
|
120 |
-
# width: 100%;
|
121 |
-
# }
|
122 |
-
# .instructions {
|
123 |
-
# padding: 20px;
|
124 |
-
# background-color: #f9f9f9;
|
125 |
-
# border-radius: 8px;
|
126 |
-
# box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
|
127 |
-
# }
|
128 |
-
# </style>
|
129 |
-
# """, unsafe_allow_html=True)
|
130 |
-
|
131 |
# Load Model and Processor
|
132 |
@st.cache_resource
|
133 |
def load_model():
|
@@ -186,8 +124,8 @@ def apply_transform(image, size_mode=512):
|
|
186 |
return transformed["image"]
|
187 |
|
188 |
# Streamlit UI with Colorful Title and Emojis
|
189 |
-
# st.markdown("<h1 class='title'
|
190 |
-
st.markdown("<h1 class='title'
|
191 |
st.markdown(
|
192 |
"<p style='text-align: center; font-size: 18px;'>Welcome to a simple demo of our work! π Choose an example or upload your own image to get started! π</p>",
|
193 |
unsafe_allow_html=True
|
|
|
29 |
.title {
|
30 |
font-size: 3.2rem;
|
31 |
text-align: center;
|
32 |
+
color: #C668C2;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
33 |
}
|
34 |
.subheader {
|
35 |
font-size: 1.5rem;
|
|
|
66 |
</style>
|
67 |
""", unsafe_allow_html=True)
|
68 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
69 |
# Load Model and Processor
|
70 |
@st.cache_resource
|
71 |
def load_model():
|
|
|
124 |
return transformed["image"]
|
125 |
|
126 |
# Streamlit UI with Colorful Title and Emojis
|
127 |
+
# st.markdown("<h1 class='title'>β Knowledge to Sight: Reasoning over Visual Attributes via Knowledge Decomposition for Abnormality Grounding π</h1>", unsafe_allow_html=True)
|
128 |
+
st.markdown("<h1 class='title'>π©Ί Knowledge to Sight: Reasoning over Visual Attributes via Knowledge Decomposition for Abnormality Grounding π</h1>", unsafe_allow_html=True)
|
129 |
st.markdown(
|
130 |
"<p style='text-align: center; font-size: 18px;'>Welcome to a simple demo of our work! π Choose an example or upload your own image to get started! π</p>",
|
131 |
unsafe_allow_html=True
|