diff --git a/spacy/vocab.pyx b/spacy/vocab.pyx index 023d0bd89..aec01f239 100644 --- a/spacy/vocab.pyx +++ b/spacy/vocab.pyx @@ -11,7 +11,6 @@ import io import math import json import tempfile -import copy_reg from .lexeme cimport EMPTY_LEXEME from .lexeme cimport Lexeme @@ -29,6 +28,11 @@ from . import util from .serialize.packer cimport Packer from .attrs cimport PROB +try: + import copy_reg +except ImportError: + import copyreg as copy_reg + DEF MAX_VEC_SIZE = 100000