mirror of
https://github.com/explosion/spaCy.git
synced 2024-11-13 05:07:03 +03:00
Fixes
This commit is contained in:
parent
034d803b7a
commit
fe0cdcd461
|
@ -50,7 +50,8 @@ def HashEmbed(
|
||||||
width,
|
width,
|
||||||
rows if feature == NORM else rows // 2,
|
rows if feature == NORM else rows // 2,
|
||||||
column=cols.index(feature),
|
column=cols.index(feature),
|
||||||
seed=seed
|
seed=seed,
|
||||||
|
dropout=0.0
|
||||||
)
|
)
|
||||||
|
|
||||||
if also_embed_subwords:
|
if also_embed_subwords:
|
||||||
|
@ -67,14 +68,14 @@ def HashEmbed(
|
||||||
model = chain(
|
model = chain(
|
||||||
concatenate(
|
concatenate(
|
||||||
chain(FeatureExtractor(cols), concatenate(*embeddings)),
|
chain(FeatureExtractor(cols), concatenate(*embeddings)),
|
||||||
StaticVectors(width, dropout=dropout)
|
StaticVectors(width, dropout=0.0)
|
||||||
),
|
),
|
||||||
Maxout(width, dropout=dropout, normalize=True)
|
Maxout(width, pieces=3, dropout=0.0, normalize=True)
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
model = chain(
|
model = chain(
|
||||||
chain(FeatureExtractor(cols), concatenate(*embeddings)),
|
chain(FeatureExtractor(cols), concatenate(*embeddings)),
|
||||||
Maxout(width, concat_size, dropout=dropout, normalize=True)
|
Maxout(width, pieces=3, dropout=0.0, normalize=True)
|
||||||
)
|
)
|
||||||
return model
|
return model
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user