Skip to content

Commit

Permalink
Print replaced with logging
Browse files Browse the repository at this point in the history
Signed-off-by: Frank-lilinjie <lilinjie@bupt.edu.cn>
  • Loading branch information
Frank-lilinjie committed Oct 31, 2024
1 parent 363dc73 commit bda7194
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def evaluate(self, data, **kwargs):

def load(self, model_url, **kwargs):
if model_url:
print("load model url: ",model_url)
logging.info("load model url: ",model_url)

def save(self, model_path = None):
pass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
import numpy as np
from sedna.common.class_factory import ClassType, ClassFactory
from transformers import AutoTokenizer,AutoModelForCausalLM
import logging

@ClassFactory.register(ClassType.GENERAL, alias="rouge1")
def rouge1(y_true, y_pred, **kwargs):
Expand Down Expand Up @@ -34,7 +35,7 @@ def rougeL(y_true, y_pred, **kwargs):
return rougeL

def calculate_mean(lst):
print(lst)
logging.info(lst)
if not isinstance(lst,list):
return lst
if not lst:
Expand Down

0 comments on commit bda7194

Please sign in to comment.