Skip to content

Commit

Permalink
update docker-compose for new tagger variants
Browse files Browse the repository at this point in the history
  • Loading branch information
PrinsINT committed Nov 15, 2024
1 parent 798808d commit 8826af7
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 9 deletions.
2 changes: 1 addition & 1 deletion buildall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ echo "Will build taggers with version <$VERSION>. Set VERSION to override this."
# Base image
docker build --build-arg VERSION=$VERSION -t instituutnederlandsetaal/taggers-dockerized-base:$VERSION base

# ud-parsers
# UD-parsers
docker build --build-arg VERSION=$VERSION --build-arg SPACY_MODEL=nl_core_news_lg -t instituutnederlandsetaal/taggers-dockerized-spacy:$VERSION spacy
docker build --build-arg VERSION=$VERSION -t instituutnederlandsetaal/taggers-dockerized-stanza:$VERSION stanza
docker build --build-arg VERSION=$VERSION -t instituutnederlandsetaal/taggers-dockerized-flair:$VERSION flair
5 changes: 5 additions & 0 deletions buildandpushall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ docker push instituutnederlandsetaal/taggers-dockerized-pie-tdn-clvn:$VERSION
docker push instituutnederlandsetaal/taggers-dockerized-pie-tdn-cour:$VERSION
docker push instituutnederlandsetaal/taggers-dockerized-pie-tdn-dbnldq:$VERSION

# UD-parsers
docker push instituutnederlandsetaal/taggers-dockerized-spacy:$VERSION
docker push instituutnederlandsetaal/taggers-dockerized-stanza:$VERSION
docker push instituutnederlandsetaal/taggers-dockerized-flair:$VERSION

# Huggingface
# Commented for now, as we need Git LFS to build these. Perhaps in the future.
# docker push instituutnederlandsetaal/taggers-dockerized-hug-tdn-1400-1600:$VERSION
Expand Down
40 changes: 32 additions & 8 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ services:
- NUM_WORKERS=6
- CALLBACK_SERVER=${CALLBACK_SERVER}
ports:
- 8120:8080
- 8120:8080 # cpu & gpu share port: choose one
deploy:
resources:
limits:
Expand All @@ -23,29 +23,53 @@ services:
image: instituutnederlandsetaal/taggers-dockerized-spacy:${VERSION}
restart: unless-stopped
environment:
- NUM_WORKERS=1
- CALLBACK_SERVER=${CALLBACK_SERVER}
ports:
- 8120:8080
- 8120:8080 # cpu & gpu share port: choose one

stanza:
stanza-alpino-conll02:
image: instituutnederlandsetaal/taggers-dockerized-stanza:${VERSION}
restart: unless-stopped
environment:
- NUM_WORKERS=1
- STANZA_MODEL=alpino
- CALLBACK_SERVER=${CALLBACK_SERVER}
ports:
- 8121:8080

flair:
image: instituutnederlandsetaal/taggers-dockerized-flair:${VERSION}
stanza-lassysmall-wikiner:
image: instituutnederlandsetaal/taggers-dockerized-stanza:${VERSION}
restart: unless-stopped
environment:
- NUM_WORKERS=1
- STANZA_MODEL=lassysmall
- CALLBACK_SERVER=${CALLBACK_SERVER}
ports:
- 8122:8080

flair-cpu:
image: instituutnederlandsetaal/taggers-dockerized-flair:${VERSION}
restart: unless-stopped
environment:
- CALLBACK_SERVER=${CALLBACK_SERVER}
ports:
- 8123:8080

flair-gpu:
image: instituutnederlandsetaal/taggers-dockerized-flair:${VERSION}
restart: unless-stopped
environment:
- CALLBACK_SERVER=${CALLBACK_SERVER}
ports:
- 8123:8080
deploy:
resources:
limits:
memory: 4G
reservations:
devices:
- driver: nvidia
count: all
capabilities: [ gpu ]

networks:
default:
name: taggers-network
Expand Down

0 comments on commit 8826af7

Please sign in to comment.