orionweller commited on
Commit
8947c81
1 Parent(s): d618113
Files changed (1) hide show
  1. app.py +6 -2
app.py CHANGED
@@ -23,7 +23,11 @@ from collections import defaultdict
23
  set_seed(42)
24
 
25
  # Set up logging
26
- logging.basicConfig(level=logging.INFO)
 
 
 
 
27
  logger = logging.getLogger(__name__)
28
 
29
  # Authenticate with HF_TOKEN
@@ -130,7 +134,7 @@ class RepLlamaModel:
130
  # if model is not on cuda, put it there
131
  if self.model.device.type != "cuda":
132
  self.model = self.model.cuda()
133
-
134
  all_embeddings = []
135
  for i in tqdm.tqdm(range(0, len(texts), batch_size)):
136
  batch_texts = texts[i:i+batch_size]
 
23
  set_seed(42)
24
 
25
  # Set up logging
26
+ # Set up logging with time printing
27
+ logging.basicConfig(
28
+ format='%(asctime)s %(levelname)-8s %(message)s',
29
+ level=logging.INFO,
30
+ datefmt='%Y-%m-%d %H:%M:%S')
31
  logger = logging.getLogger(__name__)
32
 
33
  # Authenticate with HF_TOKEN
 
134
  # if model is not on cuda, put it there
135
  if self.model.device.type != "cuda":
136
  self.model = self.model.cuda()
137
+
138
  all_embeddings = []
139
  for i in tqdm.tqdm(range(0, len(texts), batch_size)):
140
  batch_texts = texts[i:i+batch_size]