Conversions between labelbuddy json and other formats.
Project description
labelutils
Python scripts to perform conversions between labelbuddy’s and other annotation tools’ file formats.
Installation
Can be installed from PyPI with
pip install labelutils
But as this is WIP, it might be better at the moment to install from the Git repository to get a more up-to-date version:
pip install "git+https://github.com/jeromedockes/labelutils.git"
Usage
After installing we can use the command labelutils_convert:
inception → labelbuddy format
labelutils_convert --from inception --to labelbuddy --in_txt_dir /path/to/txt_dir --in_wtsv_dir /path/to/wtsv_dir --out_jsonl docs.jsonl
Where:
/path/to/txt_diris a directory containing.txtfiles that have been imported into Inception, ie the contents of the documents.path/to/wtsv_diris a directory containing the.wtsvWebAnno files exported from Inception, whose names must match those of the.txtfiles except for the extension.
labelbuddy → inception format
labelutils_convert --from labelbuddy --to inception --in_jsonl docs.jsonl --in_wtsv_dir /path/to/wtsv_dir --out_inception_dir inception_docs
Where:
docs.jsonlcontains documents & annotations in labelbuddy format./path/to/wtsv_diris a directory containing.wtsvWebAnno files exported from Inception. If it contains any annotations, they are ignored, but this file is still needed to get Inception's tokenization of the documents.- output will be stored in
inception_docs
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file labelutils-0.0.1.tar.gz.
File metadata
- Download URL: labelutils-0.0.1.tar.gz
- Upload date:
- Size: 8.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1ba5c5c37a86c32bc3500f4dcc71daca4cff5aabf1976bb10b1aa650b5df9065
|
|
| MD5 |
91a9a3515d47b3d3bb4a524ff5ccaa20
|
|
| BLAKE2b-256 |
9e7fd51be5667d1a130ba16ea7f3d5c06269fc3b0442a338a862a47fd0b3f02b
|
File details
Details for the file labelutils-0.0.1-py3-none-any.whl.
File metadata
- Download URL: labelutils-0.0.1-py3-none-any.whl
- Upload date:
- Size: 10.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fadd15743a0d69f789f9c27b1f728c9930f6b78452d8f29b8e9a4fc26b5e1885
|
|
| MD5 |
55ceb53b63787b9bf7a8a8e9fdbcb88f
|
|
| BLAKE2b-256 |
3dc06c97b7847c81ab03c6a895a890a4a7297dee84872ad38058af30732f0bb4
|