mirror of
https://github.com/open-mmlab/mmsegmentation.git
synced 2025-06-03 22:03:48 +08:00
* [Fix] Convert SyncBN to BN when training on DP. * Modify SyncBN2BN. * Add SyncBN2BN unit test. * Resolve some comments. * use mmcv official revert_sync_batchnorm * Remove local syncbn2bn unit tests. * Update mmcv version. * Fix bugs of gather model tools. * Modify warnings. * Modify docker mmcv version. * Update mmcv version table.
30 lines
865 B
Docker
30 lines
865 B
Docker
ARG PYTORCH="1.6.0"
|
|
ARG CUDA="10.1"
|
|
ARG CUDNN="7"
|
|
ARG MMCV="1.3.13"
|
|
|
|
FROM pytorch/pytorch:${PYTORCH}-cuda${CUDA}-cudnn${CUDNN}-devel
|
|
|
|
ENV TORCH_CUDA_ARCH_LIST="6.0 6.1 7.0+PTX"
|
|
ENV TORCH_NVCC_FLAGS="-Xfatbin -compress-all"
|
|
ENV CMAKE_PREFIX_PATH="$(dirname $(which conda))/../"
|
|
|
|
RUN apt-get update && apt-get install -y git ninja-build libglib2.0-0 libsm6 libxrender-dev libxext6 \
|
|
&& apt-get clean \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
RUN conda clean --all
|
|
|
|
# Install MMCV
|
|
ARG PYTORCH
|
|
ARG CUDA
|
|
ARG MMCV
|
|
RUN ["/bin/bash", "-c", "pip install mmcv-full==${MMCV} -f https://download.openmmlab.com/mmcv/dist/cu${CUDA//./}/torch${PYTORCH}/index.html"]
|
|
|
|
# Install MMSegmentation
|
|
RUN git clone https://github.com/open-mmlab/mmsegmentation.git /mmsegmentation
|
|
WORKDIR /mmsegmentation
|
|
ENV FORCE_CUDA="1"
|
|
RUN pip install -r requirements.txt
|
|
RUN pip install --no-cache-dir -e .
|