Basanth commited on
Commit
82015f4
·
1 Parent(s): 9939488

cache added

Browse files
Files changed (1) hide show
  1. src/utils.py +2 -2
src/utils.py CHANGED
@@ -25,13 +25,13 @@ def default_text():
25
  text = fs.read()
26
  return text
27
 
28
- @st.cache_resource(allow_output_mutation=True,suppress_st_warning=True)
29
  def load_model():
30
  model_path = "./models/distilbert/"
31
  model = ktrain.load_predictor(model_path)
32
  return model
33
 
34
- @st.cache_resource(allow_output_mutation=True, suppress_st_warning=True)
35
  def load_skill_extractor():
36
  # This function will only be run the first time it's called
37
  import spacy
 
25
  text = fs.read()
26
  return text
27
 
28
+ @st.cache(allow_output_mutation=True,suppress_st_warning=True)
29
  def load_model():
30
  model_path = "./models/distilbert/"
31
  model = ktrain.load_predictor(model_path)
32
  return model
33
 
34
+ @st.cache(allow_output_mutation=True, suppress_st_warning=True)
35
  def load_skill_extractor():
36
  # This function will only be run the first time it's called
37
  import spacy