24 lines
883 B
Docker
24 lines
883 B
Docker
FROM ubuntu
|
|
|
|
RUN apt-get update && apt-get install -y python3 python3-pip unzip make build-essential libssl-dev zlib1g-dev \
|
|
libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev \
|
|
xz-utils tk-dev libffi-dev liblzma-dev python-openssl git \
|
|
&& curl https://pyenv.run | bash \
|
|
&& echo 'export PATH="/root/.pyenv/bin:$PATH"' >> ~/.bashrc \
|
|
&& echo 'eval "$(pyenv init -)"' >> ~/.bashrc \
|
|
&& echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.bashrc \
|
|
&& /bin/bash -c "source ~/.bashrc" \
|
|
&& python3 -m pip install pandas numpy tensorflow imbalanced-learn sklearn sacred pymongo mlflow
|
|
|
|
COPY train.py /app/train.py
|
|
COPY predictions.py /app/predictions.py
|
|
COPY data.csv /app/data.csv
|
|
|
|
WORKDIR /app
|
|
|
|
RUN export SACRED_IGNORE_GIT=TRUE
|
|
|
|
RUN /bin/bash -c "source ~/.bashrc && mlflow run . -P epochs=10"
|
|
|
|
CMD ["python3", "predictions.py"]
|