cvips
commited on
Commit
·
ca0fa47
1
Parent(s):
c13f20c
front end updated
Browse files
app.py
CHANGED
@@ -204,8 +204,50 @@ def process_image(image_path, text_prompts, modality):
|
|
204 |
|
205 |
return results, p_values
|
206 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
207 |
# Define Gradio interface
|
208 |
-
with gr.Blocks(
|
|
|
|
|
|
|
|
|
|
|
209 |
gr.HTML(MARKDOWN)
|
210 |
with gr.Row():
|
211 |
with gr.Column():
|
|
|
204 |
|
205 |
return results, p_values
|
206 |
|
207 |
+
# Add custom CSS for dark theme
|
208 |
+
CUSTOM_CSS = """
|
209 |
+
:root {
|
210 |
+
--background-fill-primary: #1F1F1F;
|
211 |
+
--background-fill-secondary: #2B2B2B;
|
212 |
+
--border-color-primary: #424242;
|
213 |
+
--text-color: #FFFFFF;
|
214 |
+
--color-accent-soft: #2C2C2C;
|
215 |
+
}
|
216 |
+
|
217 |
+
.gradio-container {
|
218 |
+
background-color: #1F1F1F !important;
|
219 |
+
color: #FFFFFF !important;
|
220 |
+
}
|
221 |
+
|
222 |
+
.gr-button {
|
223 |
+
background-color: #424242 !important;
|
224 |
+
color: #FFFFFF !important;
|
225 |
+
}
|
226 |
+
|
227 |
+
.gr-input, .gr-dropdown {
|
228 |
+
background-color: #2B2B2B !important;
|
229 |
+
color: #FFFFFF !important;
|
230 |
+
border-color: #424242 !important;
|
231 |
+
}
|
232 |
+
|
233 |
+
.gr-form {
|
234 |
+
background-color: #2B2B2B !important;
|
235 |
+
border-color: #424242 !important;
|
236 |
+
}
|
237 |
+
|
238 |
+
.gr-box {
|
239 |
+
background-color: #2B2B2B !important;
|
240 |
+
border-color: #424242 !important;
|
241 |
+
}
|
242 |
+
"""
|
243 |
+
|
244 |
# Define Gradio interface
|
245 |
+
with gr.Blocks(css=CUSTOM_CSS, theme=gr.themes.Soft(
|
246 |
+
primary_hue="gray",
|
247 |
+
secondary_hue="gray",
|
248 |
+
neutral_hue="gray",
|
249 |
+
text_size="lg"
|
250 |
+
)) as demo:
|
251 |
gr.HTML(MARKDOWN)
|
252 |
with gr.Row():
|
253 |
with gr.Column():
|