Spaces:
Sleeping
Sleeping
Commit
·
7fc49de
1
Parent(s):
81c1220
Update ASCARIS.py
Browse files- ASCARIS.py +19 -5
ASCARIS.py
CHANGED
|
@@ -15,12 +15,26 @@ import gzip
|
|
| 15 |
|
| 16 |
showWarningOnDirectExecution = False
|
| 17 |
|
| 18 |
-
|
| 19 |
-
backgroundColor="#002b36"
|
| 20 |
-
secondaryBackgroundColor="#586e75"
|
| 21 |
-
textColor="#fafafa"
|
| 22 |
-
font="sans serif"
|
| 23 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24 |
|
| 25 |
def convert_df(df):
|
| 26 |
return df.to_csv(index=False).encode('utf-8')
|
|
|
|
| 15 |
|
| 16 |
showWarningOnDirectExecution = False
|
| 17 |
|
| 18 |
+
import gradio as gr
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19 |
|
| 20 |
+
interface = gr.Interface(lambda a: a, "text", "text")
|
| 21 |
+
|
| 22 |
+
with gr.Blocks() as block:
|
| 23 |
+
interface.render()
|
| 24 |
+
block.load(
|
| 25 |
+
None,
|
| 26 |
+
None,
|
| 27 |
+
_js="""
|
| 28 |
+
() => {
|
| 29 |
+
const params = new URLSearchParams(window.location.search);
|
| 30 |
+
if (!params.has('__theme')) {
|
| 31 |
+
params.set('__theme', 'dark');
|
| 32 |
+
window.location.search = params.toString();
|
| 33 |
+
}
|
| 34 |
+
}""",
|
| 35 |
+
)
|
| 36 |
+
|
| 37 |
+
block.launch(share=False)
|
| 38 |
|
| 39 |
def convert_df(df):
|
| 40 |
return df.to_csv(index=False).encode('utf-8')
|