2022-12-15 07:14:29 +00:00
|
|
|
FROM nvcr.io/nvidia/cuda:11.0.3-cudnn8-devel-ubuntu20.04
|
2022-12-01 01:31:55 +00:00
|
|
|
LABEL maintainer="bigscience-workshop"
|
|
|
|
LABEL repository="petals"
|
|
|
|
|
|
|
|
WORKDIR /home
|
|
|
|
# Set en_US.UTF-8 locale by default
|
|
|
|
RUN echo "LC_ALL=en_US.UTF-8" >> /etc/environment
|
|
|
|
|
|
|
|
# Install packages
|
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
|
|
build-essential \
|
|
|
|
wget \
|
|
|
|
git \
|
|
|
|
&& apt-get clean autoclean && rm -rf /var/lib/apt/lists/{apt,dpkg,cache,log} /tmp/* /var/tmp/*
|
|
|
|
|
|
|
|
RUN wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O install_miniconda.sh && \
|
|
|
|
bash install_miniconda.sh -b -p /opt/conda && rm install_miniconda.sh
|
|
|
|
ENV PATH="/opt/conda/bin:${PATH}"
|
|
|
|
|
2023-07-13 15:34:17 +00:00
|
|
|
RUN conda install python~=3.10.12 pip && \
|
2022-12-08 23:54:57 +00:00
|
|
|
pip install --no-cache-dir "torch>=1.12" && \
|
2022-12-01 01:31:55 +00:00
|
|
|
conda clean --all && rm -rf ~/.cache/pip
|
|
|
|
|
2022-12-08 23:54:57 +00:00
|
|
|
VOLUME /cache
|
|
|
|
ENV PETALS_CACHE=/cache
|
|
|
|
|
2022-12-01 01:31:55 +00:00
|
|
|
COPY . petals/
|
2022-12-15 07:14:29 +00:00
|
|
|
RUN pip install --no-cache-dir -e petals
|
2022-12-01 01:31:55 +00:00
|
|
|
|
|
|
|
WORKDIR /home/petals/
|
|
|
|
CMD bash
|