dar-tau commited on
Commit
e2b9fe2
·
verified ·
1 Parent(s): 7aea2df

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -53,8 +53,7 @@ def analyze_sentence(index, vis_type, vis_format):
53
  "offset_x": 20,
54
  "distance": 130
55
  })
56
- graph_output = ("<style>.displacy_container svg{margin-top:-500px;}</style>" +
57
- "<div class='displacy_container' style='max-width:100%; zoom:80%; max-height:360px; overflow:auto'>"
58
  + graph_output +
59
  "</div>"
60
  )
@@ -65,7 +64,7 @@ def analyze_sentence(index, vis_type, vis_format):
65
  return fig_output, graph_output, metrics
66
 
67
 
68
- demo = gr.Blocks()
69
  with demo:
70
  with gr.Row():
71
  sentence_dropdown = gr.Dropdown(label="Sentence",
 
53
  "offset_x": 20,
54
  "distance": 130
55
  })
56
+ graph_output = ("<div class='displacy_container' style='max-width:100%; zoom:80%; max-height:360px; overflow:auto'>"
 
57
  + graph_output +
58
  "</div>"
59
  )
 
64
  return fig_output, graph_output, metrics
65
 
66
 
67
+ demo = gr.Blocks(css=".displacy_container svg{margin-top:-500px;}")
68
  with demo:
69
  with gr.Row():
70
  sentence_dropdown = gr.Dropdown(label="Sentence",