mirror of
https://github.com/explosion/spaCy.git
synced 2025-01-13 02:36:32 +03:00
* Remove non_sparse method --- features wanting this can do it easily enough.
This commit is contained in:
parent
b5ae1471db
commit
32fb50dc35
|
@ -151,15 +151,6 @@ def word_shape(string):
|
||||||
return ''.join(shape)
|
return ''.join(shape)
|
||||||
|
|
||||||
|
|
||||||
def non_sparse(string, prob, cluster, upper_pc, title_pc, lower_pc):
|
|
||||||
if is_alpha(string):
|
|
||||||
return canon_case(string, upper_pc, title_pc, lower_pc)
|
|
||||||
elif prob >= math.log(0.0001):
|
|
||||||
return string
|
|
||||||
else:
|
|
||||||
return word_shape(string)
|
|
||||||
|
|
||||||
|
|
||||||
def asciied(string):
|
def asciied(string):
|
||||||
ascii_string = unidecode(string)
|
ascii_string = unidecode(string)
|
||||||
if not ascii_string:
|
if not ascii_string:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user