-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy path72.dockerfile
66 lines (52 loc) · 1.81 KB
/
72.dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
FROM nvidia/cuda:11.1.1-cudnn8-devel-ubuntu18.04
SHELL [ "/bin/bash", "-c"]
# Install required packages
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update \
&& apt-get install -yq software-properties-common \
&& add-apt-repository ppa:ubuntu-toolchain-r/test \
&& apt-get update \
&& apt install -yq apt-transport-https \
gcc \
g++ \
wget \
git \
ffmpeg \
libsm6 \
libxext6 \
libstdc++6 \
&& rm -rf /var/lib/apt/lists/*
RUN mkdir -p /home/xview3
WORKDIR /home/xview3
ADD environment.yml environment.yml
# Changing parameter back to default
ENV DEBIAN_FRONTEND=newt
# Install Miniconda
ENV PATH="/root/miniconda3/bin:${PATH}"
ARG PATH="/root/miniconda3/bin:${PATH}"
RUN wget -nv https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh \
&& mkdir /root/.conda \
&& bash Miniconda3-latest-Linux-x86_64.sh -b \
&& rm -f Miniconda3-latest-Linux-x86_64.sh \
&& conda update -n base -c defaults conda \
&& conda env create -f ./environment.yml \
&& conda init bash
RUN mkdir /input
RUN mkdir /output
# https://github.com/pytorch/pytorch/issues/27971
ENV LRU_CACHE_CAPACITY 1
# set environment variables
# Prevents Python from writing pyc files to disc
ENV PYTHONDONTWRITEBYTECODE 1
# Prevents Python from buffering stdout and stderr
ENV PYTHONUNBUFFERED 1
ADD xview3 /home/xview3/xview3
ADD run_inference.sh /home/xview3/
ADD docker_inference.py /home/xview3/
RUN chmod +x /home/xview3/run_inference.sh
ADD submissions/1128_b5_b4_vs2_fliplr/traced_ensemble.jit \
/home/xview3/submissions/1128_b5_b4_vs2_fliplr/traced_ensemble.jit
ADD submissions/1128_b5_b4_vs2_fliplr/1128_b5_b4_vs2_fliplr_test__config_0.300_vsl_0.338_fsh_0.350_step_1536_tta_fliplr.yaml \
/home/xview3/config.yaml
# Set entrypoint
ENTRYPOINT [ "/home/xview3/run_inference.sh" ]