Spaces:
Runtime error
Runtime error
Commit
·
7815235
1
Parent(s):
a2f2a9c
Update app.py0
Browse files
app.py0
CHANGED
@@ -118,37 +118,36 @@ def load_data():
|
|
118 |
reviews, total_reviews = get_latest_reviews(db)
|
119 |
db.close()
|
120 |
return reviews, total_reviews
|
121 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
122 |
css="footer {visibility: hidden}"
|
123 |
# Applying style to highlight the maximum value in each row
|
124 |
#styler = df.style.highlight_max(color = 'lightgreen', axis = 0)
|
125 |
with gr.Blocks() as demo:
|
126 |
with gr.Row():
|
127 |
with gr.Column():
|
128 |
-
|
129 |
-
|
|
|
|
|
|
|
|
|
|
|
130 |
with gr.Row():
|
131 |
with gr.Column():
|
132 |
-
|
133 |
-
|
134 |
-
df = pd.DataFrame({
|
135 |
-
"A" : [14, 4, 5, 4, 1],
|
136 |
-
"B" : [5, 2, 54, 3, 2],
|
137 |
-
"C" : [20, 20, 7, 3, 8],
|
138 |
-
"D" : [14, 3, 6, 2, 6],
|
139 |
-
"E" : [23, 45, 64, 32, 23]
|
140 |
-
})
|
141 |
-
|
142 |
-
# Applying style to highlight the maximum value in each row
|
143 |
-
styler = df.style.highlight_max(color = 'lightgreen', axis = 0)
|
144 |
-
|
145 |
-
|
146 |
-
df1=run_ecs("Dan")
|
147 |
-
|
148 |
-
|
149 |
-
#df1=json.loads(js1)
|
150 |
-
data = gr.Dataframe(styler)
|
151 |
-
#count = gr.Number(label="Rates!")
|
152 |
with gr.Row():
|
153 |
with gr.Column():
|
154 |
name = gr.Textbox(label="a") #, placeholder="What is your name?")
|
|
|
118 |
reviews, total_reviews = get_latest_reviews(db)
|
119 |
db.close()
|
120 |
return reviews, total_reviews
|
121 |
+
|
122 |
+
# Creating a sample dataframe
|
123 |
+
df = pd.DataFrame({
|
124 |
+
"A" : [14, 4, 5, 4, 1],
|
125 |
+
"B" : [5, 2, 54, 3, 2],
|
126 |
+
"C" : [20, 20, 7, 3, 8],
|
127 |
+
"D" : [14, 3, 6, 2, 6],
|
128 |
+
"E" : [23, 45, 64, 32, 23]
|
129 |
+
})
|
130 |
+
|
131 |
+
# Applying style to highlight the maximum value in each row
|
132 |
+
styler = df.style.highlight_max(color = 'lightgreen', axis = 0)
|
133 |
+
|
134 |
css="footer {visibility: hidden}"
|
135 |
# Applying style to highlight the maximum value in each row
|
136 |
#styler = df.style.highlight_max(color = 'lightgreen', axis = 0)
|
137 |
with gr.Blocks() as demo:
|
138 |
with gr.Row():
|
139 |
with gr.Column():
|
140 |
+
gr.Dataframe(styler)
|
141 |
+
#df1=run_ecs("Dan")
|
142 |
+
|
143 |
+
|
144 |
+
#df1=json.loads(js1)
|
145 |
+
#data = gr.Dataframe(styler)
|
146 |
+
#count = gr.Number(label="Rates!")
|
147 |
with gr.Row():
|
148 |
with gr.Column():
|
149 |
+
data = gr.Dataframe() #styler)
|
150 |
+
count = gr.Number(label="Rates!")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
151 |
with gr.Row():
|
152 |
with gr.Column():
|
153 |
name = gr.Textbox(label="a") #, placeholder="What is your name?")
|