Config & Decorator #9352
-
Hi, Trying to learn the new way of training a model under Spacy using the CFG file. While looking at the CFG file from some sample codes published in github, notice this "@xxxx" decorator. Understand it is pointing to a "function". Trying to find the documentation, for example, "@architectures", "@layers", "@misc", "@schedules", "@readers", "@batchers" ... etc. Can you please point me to the link/place for me to read up ? Thanks. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
The configuration items starting with The example there uses a function to provide a The function registry section of the documentation lists what kinds of functions can be registered. (I'm new to the spaCy team and this is the first question I'm answering, so I hope my explanation is right!) |
Beta Was this translation helpful? Give feedback.
The configuration items starting with
@
indicate that, instead of a static value, the value is being provided by a function. This idea is introduced in the documentation at https://spacy.io/usage/training#config-functions .The example there uses a function to provide a
batch_size
that changes according to a schedule, instead of being a fixed value.The function registry section of the documentation lists what kinds of functions can be registered.
(I'm new to the spaCy team and this is the first question I'm answering, so I hope my explanation is right!)