Installation instructions
-
Download and install the latest Anaconda distribution from here
-
Start the Anaconda Powershell Prompt if running Windows, or a terminal otherwise. Make sure conda is available in the command line path.
-
Create a conda environment running
conda create -n pvcastro-iberlef python=3.6 -
Update Anaconda running
conda update -n base -c defaults conda -
Install pytorch running
conda install pytorch-cpu -c pytorch -n pvcastro-iberlef -
Activate the created conda environment using
conda activate pvcastro-iberlef -
Install the AllenNLP framework running
pip install -U allennlp -
Download the spacy model running
python -m spacy download en_core_web_sm -
Install the pvcastro-iberlef module running
pip install -U pvcastro-iberlef
Execution instructions
Run the NER prediction with a command as python -m pvcastro_iberlef.predict_ner --document-path path_to_the_input_document --out-path path_to_the_output_file
Parameters:
- document-path: path to the document containing the text to be predicted for NER, with one token per line, with sentences separated by blank lines.
- out-path: path to the document where the predictions results will be written. Must specify a filename. Example: C:\iberlef\predictions.txt
Observations
Since the IberLEF NER model uses two language models based on ELMo, the trained model ended up quite big, with 1.4Gb aproximately. It takes a while to download it the first time, but the model is cached, so following executions after the first will be quicker.
Metadata
Release files for pvcastro-iberlef 0.4.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pvcastro_iberlef-0.4.1-py3-none-any.whl | Python 3 | none | any | Details for pvcastro_iberlef-0.4.1-py3-none-any.whl |
Release files / pvcastro_iberlef-0.4.1-py3-none-any.whl
| Download URL | pvcastro_iberlef-0.4.1-py3-none-any.whl |
|---|---|
| Size | 7.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
54b68b0b5aee7cae030fabc7c2768df8278453e5761d869a2d1fdb8f6cff9d98
|
|
BLAKE2b-256 checksum How to use checksums |
99fa39d88426024f920758414058a64b821ce403398855dcece2e23f9c3f61aa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.0 requests-toolbelt/0.9.1 tqdm/4.23.4 CPython/3.7.2
|
Security for pvcastro-iberlef 0.4.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.