egumasa commited on
Commit
fe440f1
·
1 Parent(s): bdd6f8b
Files changed (1) hide show
  1. demo.py +3 -3
demo.py CHANGED
@@ -32,7 +32,7 @@ st.set_page_config(
32
  )
33
 
34
 
35
- @st.cache_resource()
36
  def load_model():
37
  # nlp = spacy.load("en_engagement_RoBERTa_context_flz")
38
  nlp = spacy.load("en_engagement_LSTM")
@@ -123,7 +123,7 @@ TEXT_LIST = [
123
  ]
124
 
125
 
126
- @st.cache_resource()
127
  def preprocess(text):
128
  text = re.sub("\n\n", " &&&&&&&&#&#&#&#&", text)
129
  text = re.sub("\n", " ", text)
@@ -132,7 +132,7 @@ def preprocess(text):
132
  return text
133
 
134
 
135
- @st.cache_resource()
136
  def delete_span(span_sc: dict):
137
  id_del = []
138
  for n, spn in enumerate(span_sc, start=1):
 
32
  )
33
 
34
 
35
+ @st.cache_resource
36
  def load_model():
37
  # nlp = spacy.load("en_engagement_RoBERTa_context_flz")
38
  nlp = spacy.load("en_engagement_LSTM")
 
123
  ]
124
 
125
 
126
+ @st.cache_resource
127
  def preprocess(text):
128
  text = re.sub("\n\n", " &&&&&&&&#&#&#&#&", text)
129
  text = re.sub("\n", " ", text)
 
132
  return text
133
 
134
 
135
+ @st.cache_resource
136
  def delete_span(span_sc: dict):
137
  id_del = []
138
  for n, spn in enumerate(span_sc, start=1):