Skip to content

Commit

Permalink
Annotation is better
Browse files Browse the repository at this point in the history
  • Loading branch information
PonteIneptique committed May 25, 2019
1 parent 6ac1755 commit 7c2f7c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions annotate_text.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
qui estoit senescaus de la tiere ,%.%.
Robiers ses freres ,%.%. Gautiers de voignori ,%.%. Gautiers de Mombelyart ,%.%.
Eustasces d'escouflans ,%.%. Guis dou plaissie %,%. et ses freres ,%% Henris D'ardillieres ,%.%. Ogiers de saint chienon ,%.%.""".replace(
"%", "").replace("\n", " ").replace(" ", "")
"%", "").replace("\n", " ")

print(input_text)

Expand All @@ -30,4 +30,4 @@
logger.setLevel(logging.DEBUG)

tokenizer = Seq2SeqTokenizer.load("/home/thibault/dev/boudams/models/linear-conv2019-05-24--14:08:58-0.0001.tar", device="cpu")
print("".join(tokenizer.annotate_text(input_text)))
print(" ".join(tokenizer.annotate_text(input_text.replace(" ", ""))))

0 comments on commit 7c2f7c3

Please sign in to comment.