Spaces:
Runtime error
Runtime error
Commit
·
b6bb9e7
1
Parent(s):
2b49fc4
Update app.py
Browse files
app.py
CHANGED
|
@@ -161,7 +161,7 @@ def load_data2():
|
|
| 161 |
css="footer {visibility: hidden}"
|
| 162 |
# Applying style to highlight the maximum value in each row
|
| 163 |
#styler = df.style.highlight_max(color = 'lightgreen', axis = 0)
|
| 164 |
-
with gr.Blocks(
|
| 165 |
with gr.Row():
|
| 166 |
with gr.Column():
|
| 167 |
data = gr.Dataframe() #styler)
|
|
@@ -184,6 +184,19 @@ with gr.Blocks(css=css) as demo:
|
|
| 184 |
#run_code()
|
| 185 |
load_data()
|
| 186 |
#return "Hello " + name + "!"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 187 |
def backup_db():
|
| 188 |
shutil.copyfile(DB_FILE, "./reviews.db")
|
| 189 |
db = sqlite3.connect(DB_FILE)
|
|
|
|
| 161 |
css="footer {visibility: hidden}"
|
| 162 |
# Applying style to highlight the maximum value in each row
|
| 163 |
#styler = df.style.highlight_max(color = 'lightgreen', axis = 0)
|
| 164 |
+
with gr.Blocks() as demo:
|
| 165 |
with gr.Row():
|
| 166 |
with gr.Column():
|
| 167 |
data = gr.Dataframe() #styler)
|
|
|
|
| 184 |
#run_code()
|
| 185 |
load_data()
|
| 186 |
#return "Hello " + name + "!"
|
| 187 |
+
with gr.Row():
|
| 188 |
+
with gr.Column():
|
| 189 |
+
gr.Dataset(components=[gr.Textbox(visible=True)],
|
| 190 |
+
label="Text Dataset",
|
| 191 |
+
samples=[
|
| 192 |
+
["The quick brown fox jumps over the lazy dog"],
|
| 193 |
+
["Build & share delightful machine learning apps"],
|
| 194 |
+
["She sells seashells by the seashore"],
|
| 195 |
+
["Supercalifragilisticexpialidocious"],
|
| 196 |
+
["Lorem ipsum"],
|
| 197 |
+
["That's all folks!"]
|
| 198 |
+
],
|
| 199 |
+
)
|
| 200 |
def backup_db():
|
| 201 |
shutil.copyfile(DB_FILE, "./reviews.db")
|
| 202 |
db = sqlite3.connect(DB_FILE)
|