- spaCy Tutorial
- spaCy - Home
- spaCy - Introduction
- spaCy - Getting Started
- spaCy - Models and Languages
- spaCy - Architecture
- spaCy - Command Line Helpers
- spaCy - Top-level Functions
- spaCy - Visualization Function
- spaCy - Utility Functions
- spaCy - Compatibility Functions
- spaCy - Containers
- Doc Class ContextManager and Property
- spaCy - Container Token Class
- spaCy - Token Properties
- spaCy - Container Span Class
- spaCy - Span Class Properties
- spaCy - Container Lexeme Class
- Training Neural Network Model
- Updating Neural Network Model
- spaCy Useful Resources
- spaCy - Quick Guide
- spaCy - Useful Resources
- spaCy - Discussion
spaCy - Package Command
As name implies, this command will generate a model python package from an existing model data directory. Using this command, all the data files are copied over. For example, if the path to a file meta.json is supplied, this file will be used.
On the other hand, the data can also be entered directly from the command line as well. Once packaging is done, to turn the model into an installable archive file, we can run python setup.py sdist.
The Package command is as follows:
python -m spacy package [input_dir] [output_dir] [--meta-path] [--create-meta] [--force]
Arguments
The table below explains its arguments −
ARGUMENT | TYPE | DESCRIPTION |
---|---|---|
input_dir | positional | This represents the path to directory which contains model data. |
output_dir | positional | This represents the directory to create package folder in. |
--meta-path, -m | option | Introduced in version 2.0, represents the path to meta.json file. It is optional. |
--create-meta, -c V2.0 | flag | Introduced in version 2.0, this argument will create a meta.json file on the command line, even if one already exists in the directory. But, if an existing file is found, the entries will be shown as the defaults in the command line prompt. |
--force, -f | flag | It will force overwriting of existing folder in output directory. |
--help, -h | flag | This argument will show help message and other available arguments. |
spacy_command_line_helpers.htm
Advertisements
To Continue Learning Please Login
Login with Google