spaCy/website/docs/api
Daniël de Kok 8a5814bf2c
Add distillation loop (#12542)
* Add distillation initialization and loop

* Fix up configuration keys

* Add docstring

* Type annotations

* init_nlp_distill -> init_nlp_student

* Do not resolve dot name distill corpus in initialization

(Since we don't use it.)

* student: do not request use of optimizer in student pipe

We apply finish up the updates once in the training loop instead.

Also add the necessary logic to `Language.distill` to mirror
`Language.update`.

* Correctly determine sort key in subdivide_batch

* Fix _distill_loop docstring wrt. stopping condition

* _distill_loop: fix distill_data docstring

Make similar changes in train_while_improving, since it also had
incorrect types and missing type annotations.

* Move `set_{gpu_allocator,seed}_from_config` to spacy.util

* Update Language.update docs for the sgd argument

* Type annotation

Co-authored-by: Madeesh Kannan <shadeMe@users.noreply.github.com>

---------

Co-authored-by: Madeesh Kannan <shadeMe@users.noreply.github.com>
2023-04-21 13:49:40 +02:00
..
architectures.mdx Merge branch 'master' into sync/master-into-v4 2023-03-02 16:24:15 +01:00
attributeruler.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
attributes.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
cli.mdx Merge branch 'master' into sync/master-into-v4 2023-03-02 16:24:15 +01:00
coref.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
corpus.mdx Add spacy.PlainTextCorpusReader.v1 (#12122) 2023-01-26 11:33:22 +01:00
cython-classes.mdx Refactor lexeme mem passing (#12125) 2023-01-25 12:50:21 +09:00
cython-structs.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
cython.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
data-formats.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
dependencymatcher.mdx Add new tags in docs for #12334 (#12348) 2023-03-01 10:46:13 +01:00
dependencyparser.mdx Add Language.distill (#12116) 2023-01-30 12:44:11 +01:00
doc.mdx Return Tuple[Span] for all Doc/Span attrs that provide spans (#12288) 2023-03-01 16:00:02 +01:00
docbin.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
edittreelemmatizer.mdx Add Language.distill (#12116) 2023-01-30 12:44:11 +01:00
entitylinker.mdx Merge branch 'master' into sync/master-into-v4 2023-03-02 16:24:15 +01:00
entityrecognizer.mdx Add Language.distill (#12116) 2023-01-30 12:44:11 +01:00
entityruler.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
example.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
index.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
inmemorylookupkb.mdx Entity linking: use SpanGroup instead of Iterable[Span] for mentions (#12344) 2023-03-20 12:25:18 +01:00
kb.mdx Entity linking: use SpanGroup instead of Iterable[Span] for mentions (#12344) 2023-03-20 12:25:18 +01:00
language.mdx Add distillation loop (#12542) 2023-04-21 13:49:40 +02:00
legacy.mdx Merge the parser refactor into v4 (#10940) 2023-01-18 11:27:45 +01:00
lemmatizer.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
lexeme.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
lookups.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
matcher.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
morphologizer.mdx Cleanup/remove backwards compat overwrite settings (#11888) 2023-02-02 14:13:38 +01:00
morphology.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
phrasematcher.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
pipe.mdx Add Language.distill (#12116) 2023-01-30 12:44:11 +01:00
pipeline-functions.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
scorer.mdx Rename language codes (Icelandic, multi-language) (#12149) 2023-01-31 17:30:43 +01:00
sentencerecognizer.mdx Add Language.distill (#12116) 2023-01-30 12:44:11 +01:00
sentencizer.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
span-resolver.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
span.mdx Return Tuple[Span] for all Doc/Span attrs that provide spans (#12288) 2023-03-01 16:00:02 +01:00
spancategorizer.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
spangroup.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
spanruler.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
stringstore.mdx Add info that Vocab and StringStore are not static in docs (#12427) 2023-03-27 09:18:23 +02:00
tagger.mdx Add Language.distill (#12116) 2023-01-30 12:44:11 +01:00
textcategorizer.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
tok2vec.mdx Tok2Vec: Add distill method (#12108) 2023-03-09 09:37:19 +01:00
token.mdx Merge branch 'copy_master' into copy_v4 2023-01-11 18:40:55 +01:00
tokenizer.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
top-level.mdx Merge branch 'master' into sync/master-into-v4 2023-03-02 16:24:15 +01:00
transformer.mdx Website migration from Gatsby to Next (#12058) 2023-01-11 17:30:07 +01:00
vectors.mdx Remove names for vectors (#12243) 2023-02-08 14:37:42 +01:00
vocab.mdx Add info that Vocab and StringStore are not static in docs (#12427) 2023-03-27 09:18:23 +02:00