JasonLiao commited on
Commit
d0e50f4
1 Parent(s): 53d9863

add sentence boundary

Browse files
Files changed (1) hide show
  1. code/prediction.py +1 -1
code/prediction.py CHANGED
@@ -66,7 +66,7 @@ def test_predict(test_loader, device, model, min_label=1, max_label=3):
66
  model.train()
67
  return result
68
 
69
- def add_sentence_table(result, pattern =":;。,?!~!: ", threshold_num=5, threshold_rate=0.5):
70
  for sample in result:
71
  boundary_list = []
72
  for i, char in enumerate(sample['text_a']):
 
66
  model.train()
67
  return result
68
 
69
+ def add_sentence_table(result, pattern =":;。,,?!~!: ", threshold_num=5, threshold_rate=0.5):
70
  for sample in result:
71
  boundary_list = []
72
  for i, char in enumerate(sample['text_a']):