Skip to content

Commit

Permalink
Add test for serialization issue raised in explosion#1105
Browse files Browse the repository at this point in the history
  • Loading branch information
honnibal committed Oct 10, 2017
1 parent d8a2506 commit f0f2739
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions spacy/tests/serialize/test_serialize_empty_model.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import spacy
import spacy.lang.en
from spacy.pipeline import TextCategorizer

def test_bytes_serialize_issue_1105():
nlp = spacy.lang.en.English()
tokenizer = nlp.tokenizer
textcat = TextCategorizer(tokenizer.vocab, labels=['ENTITY', 'ACTION', 'MODIFIER'])
textcat_bytes = textcat.to_bytes()

0 comments on commit f0f2739

Please sign in to comment.