mirror of https://github.com/explosion/spaCy.git
* Move murmurhash to .pxd in strings file
This commit is contained in:
parent
d5a942c4a4
commit
89a1cc1a48
|
@ -1,7 +1,14 @@
|
|||
from cymem.cymem cimport Pool
|
||||
from preshed.maps cimport PreshMap
|
||||
from murmurhash.mrmr cimport hash64
|
||||
|
||||
from .structs cimport Utf8Str
|
||||
from .structs cimport Utf8Str, UniStr
|
||||
|
||||
|
||||
cdef inline void slice_unicode(UniStr* s, Py_UNICODE* chars, int start, int end) nogil:
|
||||
s.chars = &chars[start]
|
||||
s.n = end - start
|
||||
s.key = hash64(s.chars, s.n * sizeof(Py_UNICODE), 0)
|
||||
|
||||
|
||||
cdef class StringStore:
|
||||
|
|
|
@ -2,7 +2,6 @@ import codecs
|
|||
|
||||
from libc.string cimport memcpy
|
||||
|
||||
from murmurhash.mrmr cimport hash64
|
||||
|
||||
from .typedefs cimport hash_t
|
||||
|
||||
|
|
Loading…
Reference in New Issue