pynomer is a simple python wrapper for nomer. Nomer is a stand-alone java application which maps identifiers and names to taxonomic names and ontological terms.
Make sure you installed the latest version of nomer, or use the Docker image instead.
$ pip install pynomer
pynomer --help Usage: pynomer [OPTIONS] COMMAND [ARGS]... Options: --help Show this message and exit. Commands: append Append term match to row using id and name columns... clean Cleans term matcher cache. input-schema Show input schema in JSON. matchers Lists supported matcher and (optionally) their... output-schema Show output schema. properties Lists configuration properties. replace Replace exact term matches in row. validate-term Validate terms. validate-term-link Validate term links. version Show Version.
>>> from pynomer import * >>> version() ('nomer version', '0.1.21')
Build image from source:
git clone https://github.com/nleguillarme/pynomer.git cd pynomer docker build -t pynomer:latest .
Run commands in the container:
docker run -v$PWD/.nomer:/.nomer pynomer:latest pynomer append "\tHomo sapiens" -e -o json
|:warning:| When running pynomer append and replace commands in Docker, you have to use the -e option !
Build server image from source:
docker build -f Dockerfile.server -t pynomer-server:latest https://github.com/nleguillarme/pynomer.git
Run pynomer server:
docker run --rm -v$PWD/nomer:/nomer -p9090:9090 pynomer-server:latest
Create the client:
>>> from pynomer.client import NomerClient >>> client = NomerClient(base_url="http:https://localhost:9090/") >>> client.version() '0.1.21'
License: MIT
pynomer was written by nleguillarme.