mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nlp.git
synced 2024-12-26 21:44:18 +00:00
Install models via an alternative way.
This commit is contained in:
parent
af293d6141
commit
a16b010bdc
32
Dockerfile
32
Dockerfile
@ -26,25 +26,25 @@ RUN tar -xzf "pyflow-${PYFLOW_VERSION}.tar.gz" \
|
|||||||
"pyflow-${PYFLOW_VERSION}" \
|
"pyflow-${PYFLOW_VERSION}" \
|
||||||
"pyflow-${PYFLOW_VERSION}.tar.gz"
|
"pyflow-${PYFLOW_VERSION}.tar.gz"
|
||||||
|
|
||||||
ENV SPACY_MODELS_DE=de_core_news_sm \
|
ENV SPACY_MODEL_DE=de_core_news_sm \
|
||||||
SPACY_MODELS_EL=el_core_news_sm \
|
SPACY_MODEL_EL=el_core_news_sm \
|
||||||
SPACY_MODELS_EN=en_core_web_sm \
|
SPACY_MODEL_EN=en_core_web_sm \
|
||||||
SPACY_MODELS_ES=es_core_news_sm \
|
SPACY_MODEL_ES=es_core_news_sm \
|
||||||
SPACY_MODELS_FR=fr_core_news_sm \
|
SPACY_MODEL_FR=fr_core_news_sm \
|
||||||
SPACY_MODELS_IT=it_core_news_sm \
|
SPACY_MODEL_IT=it_core_news_sm \
|
||||||
SPACY_MODELS_NL=nl_core_news_sm \
|
SPACY_MODEL_NL=nl_core_news_sm \
|
||||||
SPACY_MODELS_PT=pt_core_news_sm \
|
SPACY_MODEL_PT=pt_core_news_sm \
|
||||||
SPACY_VERSION=2.1.0
|
SPACY_VERSION=2.1.0
|
||||||
RUN pip3 install \
|
RUN pip3 install \
|
||||||
"spacy==${SPACY_VERSION}" \
|
"spacy==${SPACY_VERSION}" \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_DE}-${SPACY_VERSION}/${SPACY_MODELS_DE}-${SPACY_VERSION}.tar.gz" \
|
&& python3 -m spacy download "${SPACY_MODEL_DE}-${SPACY_VERSION}" --direct \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_EL}-${SPACY_VERSION}/${SPACY_MODELS_EL}-${SPACY_VERSION}.tar.gz" \
|
&& python3 -m spacy download "${SPACY_MODEL_EL}-${SPACY_VERSION}" --direct \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_EN}-${SPACY_VERSION}/${SPACY_MODELS_EN}-${SPACY_VERSION}.tar.gz" \
|
&& python3 -m spacy download "${SPACY_MODEL_EN}-${SPACY_VERSION}" --direct \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_ES}-${SPACY_VERSION}/${SPACY_MODELS_ES}-${SPACY_VERSION}.tar.gz" \
|
&& python3 -m spacy download "${SPACY_MODEL_ES}-${SPACY_VERSION}" --direct \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_FR}-${SPACY_VERSION}/${SPACY_MODELS_FR}-${SPACY_VERSION}.tar.gz" \
|
&& python3 -m spacy download "${SPACY_MODEL_FR}-${SPACY_VERSION}" --direct \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_IT}-${SPACY_VERSION}/${SPACY_MODELS_IT}-${SPACY_VERSION}.tar.gz" \
|
&& python3 -m spacy download "${SPACY_MODEL_IT}-${SPACY_VERSION}" --direct \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_NL}-${SPACY_VERSION}/${SPACY_MODELS_NL}-${SPACY_VERSION}.tar.gz" \
|
&& python3 -m spacy download "${SPACY_MODEL_NL}-${SPACY_VERSION}" --direct \
|
||||||
"https://github.com/explosion/spacy-models/releases/download/${SPACY_MODELS_PT}-${SPACY_VERSION}/${SPACY_MODELS_PT}-${SPACY_VERSION}.tar.gz"
|
&& python3 -m spacy download "${SPACY_MODEL_PT}-${SPACY_VERSION}" --direct
|
||||||
|
|
||||||
|
|
||||||
# Install NLP pipeline
|
# Install NLP pipeline
|
||||||
|
@ -5,7 +5,7 @@ import argparse
|
|||||||
import os
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
container_image = 'gitlab.ub.uni-bielefeld.de:4567/sfb1288inf/nlp:latest'
|
container_image = 'gitlab.ub.uni-bielefeld.de:4567/sfb1288inf/nlp:2.1.0'
|
||||||
container_input_dir = '/input'
|
container_input_dir = '/input'
|
||||||
container_output_dir = '/output'
|
container_output_dir = '/output'
|
||||||
uid = str(os.getuid())
|
uid = str(os.getuid())
|
||||||
|
Loading…
Reference in New Issue
Block a user