Qifan Zhang commited on
Commit
f54f0db
1 Parent(s): 9d7146c

fix: gradio version

Browse files
Files changed (3) hide show
  1. README.md +1 -1
  2. requirements.txt +3 -5
  3. utils/models.py +2 -0
README.md CHANGED
@@ -4,7 +4,7 @@ emoji: 💡
4
  colorFrom: yellow
5
  colorTo: gray
6
  sdk: gradio
7
- sdk_version: 3.23.0
8
  app_file: app.py
9
  pinned: false
10
  license: mit
 
4
  colorFrom: yellow
5
  colorTo: gray
6
  sdk: gradio
7
+ sdk_version: 4.4.1
8
  app_file: app.py
9
  pinned: false
10
  license: mit
requirements.txt CHANGED
@@ -4,11 +4,9 @@ pandas
4
  transformers
5
  sentence-transformers
6
 
 
 
7
  openpyxl
8
  tabulate
9
- gradio
10
  loguru
11
-
12
- torch
13
-
14
-
 
4
  transformers
5
  sentence-transformers
6
 
7
+ torch
8
+
9
  openpyxl
10
  tabulate
 
11
  loguru
12
+ # gradio
 
 
 
utils/models.py CHANGED
@@ -20,6 +20,7 @@ list_models = [
20
 
21
  class SBert:
22
  def __init__(self, path):
 
23
  self.model = SentenceTransformer(path, device=DEVICE)
24
  logger.info(f'Load {self.__class__} from {path} ...')
25
 
@@ -31,6 +32,7 @@ class SBert:
31
 
32
  class ModelWithPooling:
33
  def __init__(self, path):
 
34
  self.tokenizer = AutoTokenizer.from_pretrained(path)
35
  self.model = AutoModel.from_pretrained(path)
36
  logger.info(f'Load {self.__class__} from {path} ...')
 
20
 
21
  class SBert:
22
  def __init__(self, path):
23
+ logger.info(f'Start loading {self.__class__} from {path} ...')
24
  self.model = SentenceTransformer(path, device=DEVICE)
25
  logger.info(f'Load {self.__class__} from {path} ...')
26
 
 
32
 
33
  class ModelWithPooling:
34
  def __init__(self, path):
35
+ logger.info(f'Start loading {self.__class__} from {path} ...')
36
  self.tokenizer = AutoTokenizer.from_pretrained(path)
37
  self.model = AutoModel.from_pretrained(path)
38
  logger.info(f'Load {self.__class__} from {path} ...')