SMI-TED-demo1 / Dockerfile
Enzo Reis de Oliveira
Adding Dockerfile
96362fc
raw
history blame
382 Bytes
FROM python:3.9.7
WORKDIR /app
COPY requirements.txt .
RUN pip install -r --no-cache-dir requirements.txt
# preload models
RUN python -c '\
from transformers import BartForConditionalGeneration, AutoTokenizer;\
AutoTokenizer.from_pretrained("ibm/materials.selfies-ted");\
BartForConditionalGeneration.from_pretrained("ibm/materials.selfies-ted")'
COPY . .
CMD ["python", "app.py"]