carisackc commited on
Commit
277d36d
1 Parent(s): efab7e2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +13 -9
app.py CHANGED
@@ -185,18 +185,22 @@ with col1:
185
  table["Entity"].append(key)
186
  table["Class"].append(ent_bc[key])
187
  trans_df = pd.DataFrame(table)
188
- st.subheader("DISEASE")
189
- genEntities(trans_df, 'DISEASE')
190
- st.subheader("CHEMICAL")
191
- genEntities(trans_df, 'CHEMICAL')
192
  #st.table(trans_df)
193
 
194
  with col2:
195
  st.button('NER')
196
- # doc = nlp(str(original_text2))
197
- # colors = { "DISEASE": "pink","CHEMICAL": "orange"}
198
- # options = {"ents": [ "DISEASE", "CHEMICAL"],"colors": colors}
199
- # ent_html = displacy.render(doc, style="ent", options=options)
 
 
200
  st.markdown(ent_html, unsafe_allow_html=True)
201
- #st.write(doc.ents)
 
 
202
 
 
185
  table["Entity"].append(key)
186
  table["Class"].append(ent_bc[key])
187
  trans_df = pd.DataFrame(table)
188
+ # st.subheader("DISEASE")
189
+ # genEntities(trans_df, 'DISEASE')
190
+ # st.subheader("CHEMICAL")
191
+ # genEntities(trans_df, 'CHEMICAL')
192
  #st.table(trans_df)
193
 
194
  with col2:
195
  st.button('NER')
196
+ st.subheader("DISEASE")
197
+ genEntities(trans_df, 'DISEASE')
198
+ st.subheader("CHEMICAL")
199
+ genEntities(trans_df, 'CHEMICAL')
200
+ #st.table(trans_df)
201
+ st.subheader("NER")
202
  st.markdown(ent_html, unsafe_allow_html=True)
203
+
204
+
205
+
206