File size: 2,961 Bytes
ab687e7
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
# Arguments to pass to the image
ARG VERSION_DATE=23.01
ARG FROM_IMAGE=nvcr.io/nvidia/pytorch

# Import RAPIDS container as the BASE Image (cuda base image)
FROM ${FROM_IMAGE}:${VERSION_DATE}-py3

# Ubuntu needs noninteractive to be forced
ENV DEBIAN_FRONTEND noninteractive
ENV PROJ_LIB="/usr/share/proj"
ENV CPLUS_INCLUDE_PATH="/usr/include/gdal"
ENV C_INCLUDE_PATH="/usr/include/gdal"

# System dependencies
# System dependencies
RUN apt-get update && \
    apt-get -y install software-properties-common && \
    add-apt-repository ppa:ubuntugis/ubuntugis-unstable && \
    curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash && \
    apt-get update && apt-get -y dist-upgrade && \
    apt-get -y install build-essential \
        libsm6 \
        libxext6 \
        libxrender-dev \
        libfontconfig1 \
        bzip2 \
        diffutils \
        file \
        build-essential \
        make \
        swig \
        libnetcdf-dev \
        libacl1-dev \
        libgeos++-dev \
        libgeos-dev \
        libsqlite3-dev \
        libx11-dev \
        libproj-dev \
        proj-data \
        proj-bin \
        libspatialindex-dev \
        wget \
        vim \
        curl \
        git \
        procps \
        gcc \
        g++ \
        bzip2 \
        libssl-dev \
        libzmq3-dev \
        libpng-dev \
        libfreetype6-dev \ 
        locales \
        git-lfs && \
    apt-get -y install gdal-bin libgdal-dev && \
    apt-get -y autoremove && \
    rm -rf /var/cache/apt /var/lib/apt/lists/*

# Install shiftc
WORKDIR /app
RUN git clone --single-branch --branch master https://github.com/pkolano/shift.git && \
    cd shift/c && \
    make nolustre && \
    cd ../ && \
    install -m 755 perl/shiftc /usr/local/bin/ && \
    install -m 755 c/shift-bin /usr/local/bin/ && \
    install -m 755 perl/shift-mgr /usr/local/bin/ && \
    install -m 644 etc/shiftrc /etc/ && \
    install -m 755 perl/shift-aux /usr/local/bin/ && \
    install -m 755 c/shift-bin /usr/local/bin/ && \
    export LC_ALL=en_US.UTF-8 && \
    export LANG=en_US.UTF-8 && \
    locale-gen en_US.UTF-8 && \
    rm -rf /app

# Pip
RUN pip --no-cache-dir install omegaconf \
    pytorch-lightning \
    Lightning \
    transformers \
    datasets \
    webdataset \
    'huggingface_hub[cli,torch]' \
    torchgeo \
    rasterio \
    rioxarray \
    xarray \
    xarray-spatial \
    geopandas \
    opencv-python \
    opencv-python-headless \
    opencv-contrib-python \
    opencv-contrib-python-headless \
    tifffile \
    webcolors \
    Pillow \
    seaborn \
    xgboost \
    tiler \
    segmentation-models \
    timm \
    supervision \
    pytest \
    coveralls \
    rtree \
    sphinx \
    sphinx_rtd_theme \
    yacs \
    termcolor \
    segmentation-models-pytorch \
    pytorch-caney \
    GDAL==`ogrinfo --version | grep -Eo '[0-9]\.[0-9]\.[0-9]+'`

HEALTHCHECK NONE
ENTRYPOINT []
CMD ["/bin/bash"]