File size: 940 Bytes
54e6841
 
 
 
 
 
 
9e32bc9
54e6841
 
 
 
 
 
 
 
 
 
9e32bc9
54e6841
3567bb7
 
 
 
 
 
 
 
 
 
 
54e6841
9e32bc9
 
 
 
 
 
300dcf3
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
FROM --platform=linux/amd64 python:3.10

WORKDIR /code

# Install base utilities
RUN apt-get update \
    && apt-get install -y build-essential \
    && apt-get install -y wget libsnappy-dev \
    && apt-get clean \
    && rm -rf /var/lib/apt/lists/*

# Install miniconda
ENV CONDA_DIR /opt/conda
RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh && \
    /bin/bash ~/miniconda.sh -b -p /opt/conda

# Put conda in path so we can use conda activate
ENV PATH=$CONDA_DIR/bin:$PATH
RUN conda install --yes pytorch torchvision torchaudio pytorch-cuda=12.1 -c pytorch -c nvidia

# User setup
RUN useradd -m -u 1000 user

USER user

ENV HOME=/home/user \
	PATH=/home/user/.local/bin:$PATH

WORKDIR $HOME/app

COPY --chown=user . $HOME/app

RUN git clone https://github.com/TRI-ML/vlm-evaluation.git

RUN cd vlm-evaluation && pip install -e .

RUN pip install -e .

CMD sh $HOME/app/startup.sh