Update pages/type_text.py
Browse files- pages/type_text.py +3 -5
pages/type_text.py
CHANGED
@@ -159,15 +159,13 @@ pipe = load_pipe()
|
|
159 |
INTdesc_embedding = model.encode(INTdesc_input)
|
160 |
SBScorpus_embeddings = model.encode(SBScorpus)
|
161 |
|
162 |
-
#sp = iter(make_spinner()) # this starts the spinning
|
163 |
-
#next(sp) # heavy computation
|
164 |
-
#time.sleep(3) # spinning end
|
165 |
-
#next(sp, None)
|
166 |
-
|
167 |
progress_bar1 = st.progress(0)
|
|
|
168 |
for pct_complete in range(1,101):
|
169 |
time.sleep(0.5)
|
170 |
progress_bar1.progress(pct_complete)
|
|
|
|
|
171 |
|
172 |
if INTdesc_input is not None and st.button("Map to SBS codes", key='run_st_model'):
|
173 |
HF_model_results = util.semantic_search(INTdesc_embedding, SBScorpus_embeddings)
|
|
|
159 |
INTdesc_embedding = model.encode(INTdesc_input)
|
160 |
SBScorpus_embeddings = model.encode(SBScorpus)
|
161 |
|
|
|
|
|
|
|
|
|
|
|
162 |
progress_bar1 = st.progress(0)
|
163 |
+
status_text = st.empty()
|
164 |
for pct_complete in range(1,101):
|
165 |
time.sleep(0.5)
|
166 |
progress_bar1.progress(pct_complete)
|
167 |
+
status_text.text("Progress: {}".format(pct_complete)))
|
168 |
+
status_text.text("Progress: ".format("Done"))
|
169 |
|
170 |
if INTdesc_input is not None and st.button("Map to SBS codes", key='run_st_model'):
|
171 |
HF_model_results = util.semantic_search(INTdesc_embedding, SBScorpus_embeddings)
|