Sign inSign up

woffee/keras

By woffee

•Updated almost 5 years ago

Run keras with nvidia

Image
0

2.7K

woffee/keras repository overview

⁠py37 (add setting timezone)

FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu16.04
ARG PYTHON_VERSION=3.7
RUN apt-get update && apt-get install -y --no-install-recommends \
         build-essential \
         cmake \
         git \
         curl \
         wget \
         ca-certificates && \
     rm -rf /var/lib/apt/lists/*
RUN wget https://repo.continuum.io/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh -O ~/miniconda.sh  && \
     chmod +x ~/miniconda.sh && \
     ~/miniconda.sh -b -p /opt/conda && \
     rm ~/miniconda.sh && \
     /opt/conda/bin/conda install -y python=$PYTHON_VERSION numpy pyyaml scipy ipython mkl mkl-include ninja cython typing\
      pytorch torchvision cudatoolkit=10.1 -c pytorch&& \
     /opt/conda/bin/conda clean -ya
ENV PATH /opt/conda/bin:$PATH

RUN pip install pandas gensim==3.8.3 scikit-learn==0.22.2.post1 cvxpy matplotlib tensorflow==1.13.1 keras==2.2.4 nltk==3.4.5 h5py==2.10.0 pytrec_eval pyltr

ENV TZ=America/New_York
RUN echo $TZ > /etc/timezone && \
apt-get update && apt-get install -y tzdata && \
rm /etc/localtime && \
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \
dpkg-reconfigure -f noninteractive tzdata && \
apt-get clean

⁠v3

FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu16.04
ARG PYTHON_VERSION=3.6
RUN apt-get update && apt-get install -y --no-install-recommends \
         build-essential \
         cmake \
         git \
         curl \
         wget \
         ca-certificates && \
     rm -rf /var/lib/apt/lists/*
RUN wget https://repo.continuum.io/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh -O ~/miniconda.sh  && \
     chmod +x ~/miniconda.sh && \
     ~/miniconda.sh -b -p /opt/conda && \
     rm ~/miniconda.sh && \
     /opt/conda/bin/conda install -y python=$PYTHON_VERSION numpy pyyaml scipy ipython mkl mkl-include ninja cython typing\
      pytorch torchvision cudatoolkit=10.1 -c pytorch&& \
     /opt/conda/bin/conda clean -ya
ENV PATH /opt/conda/bin:$PATH

RUN pip install pandas gensim sklearn cvxpy matplotlib tensorflow==1.15 keras==2.2.4 nltk pytrec_eval

⁠py37_qa2 (for QA2021)

FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu16.04
ARG PYTHON_VERSION=3.7
RUN apt-get update && apt-get install -y --no-install-recommends \
         build-essential \
         cmake \
         git \
         curl \
         wget \
         ca-certificates && \
     rm -rf /var/lib/apt/lists/*
RUN wget https://repo.continuum.io/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh -O ~/miniconda.sh  && \
     chmod +x ~/miniconda.sh && \
     ~/miniconda.sh -b -p /opt/conda && \
     rm ~/miniconda.sh && \
     /opt/conda/bin/conda install -y python=$PYTHON_VERSION numpy pyyaml scipy ipython mkl mkl-include ninja cython typing\
      pytorch torchvision cudatoolkit=10.1 -c pytorch&& \
     /opt/conda/bin/conda clean -ya
ENV PATH /opt/conda/bin:$PATH

RUN pip install pandas gensim==3.8.3 scikit-learn==0.22.2.post1 cvxpy matplotlib tensorflow==1.13.1 keras==2.2.4 nltk==3.4.5 h5py==2.10.0 pytrec_eval pyltr

⁠cflow

FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu16.04
ARG PYTHON_VERSION=3.7

RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git curl wget ca-certificates && \
rm -rf /var/lib/apt/lists/*

RUN wget https://repo.continuum.io/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh -O ~/miniconda.sh  && \
     chmod +x ~/miniconda.sh && \
     ~/miniconda.sh -b -p /opt/conda && \
     rm ~/miniconda.sh && \
     /opt/conda/bin/conda install -y python=$PYTHON_VERSION numpy pyyaml scipy ipython mkl mkl-include ninja cython typing\
      pytorch torchvision cudatoolkit=10.1 -c pytorch&& \
     /opt/conda/bin/conda clean -ya

ENV PATH /opt/conda/bin:$PATH

RUN pip install pandas gensim==3.8.3 scikit-learn==0.22.2.post1 cvxpy matplotlib tensorflow==1.13.1 keras==2.2.4 nltk==3.4.5 h5py==2.10.0 pytrec_eval pyltr

RUN wget https://gnu.mirror.constant.com/cflow/cflow-latest.tar.bz2 && tar -xf cflow-latest.tar.bz2 && rm cflow-latest.tar.bz2 && \
cd cflow-1.6 && ./configure && make && make install && cd /

ENV TZ=America/New_York
RUN echo $TZ > /etc/timezone && \
apt-get update && apt-get install -y tzdata && \
rm /etc/localtime && \
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \
dpkg-reconfigure -f noninteractive tzdata && \
apt-get clean

⁠cflow_joern

FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu16.04
ARG PYTHON_VERSION=3.7

RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git curl wget ca-certificates && \
rm -rf /var/lib/apt/lists/*

RUN wget https://repo.continuum.io/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh -O ~/miniconda.sh  && \
     chmod +x ~/miniconda.sh && \
     ~/miniconda.sh -b -p /opt/conda && \
     rm ~/miniconda.sh && \
     /opt/conda/bin/conda install -y python=$PYTHON_VERSION numpy pyyaml scipy ipython mkl mkl-include ninja cython typing\
      pytorch torchvision cudatoolkit=10.1 -c pytorch&& \
     /opt/conda/bin/conda clean -ya

ENV PATH /opt/conda/bin:$PATH

RUN pip install pandas gensim==3.8.3 scikit-learn==0.22.2.post1 cvxpy matplotlib tensorflow==1.13.1 keras==2.2.4 nltk==3.4.5 h5py==2.10.0 pytrec_eval pyltr

RUN wget https://gnu.mirror.constant.com/cflow/cflow-latest.tar.bz2 && tar -xf cflow-latest.tar.bz2 && rm cflow-latest.tar.bz2 && \
cd cflow-1.6 && ./configure && make && make install && cd /

ENV TZ=America/New_York
RUN echo $TZ > /etc/timezone && \
apt-get update && apt-get install -y tzdata && \
rm /etc/localtime && \
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \
dpkg-reconfigure -f noninteractive tzdata && \
apt-get clean

# Install OpenJDK-8
RUN apt-get update && \
    apt-get install -y openjdk-8-jdk && \
    apt-get install -y ant && \
    apt-get clean;

# Fix certificate issues
RUN apt-get update && \
    apt-get install ca-certificates-java && \
    apt-get clean && \
    update-ca-certificates -f;

# Setup JAVA_HOME -- useful for docker commandline
ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64/
RUN export JAVA_HOME

RUN rm -rf cflow-1.6 

RUN apt-get install -y zip sudo && useradd -m docker && echo "docker:docker" | chpasswd && adduser docker sudo

RUN git clone https://github.com/ShiftLeftSecurity/joern && cd joern && sudo ./joern-install.sh && cd /  && apt-get clean

RUN chmod 755 /root 

⁠cflow_joern3

FROM woffee/keras:py37

# install ubuntu packages from file
COPY ubuntu-dependencies.txt /tmp/
RUN xargs -a /tmp/ubuntu-dependencies.txt apt-get install -y && \
rm -rf /var/lib/apt/lists/*


# add scala build tool (needed for building joern)
RUN echo "deb https://dl.bintray.com/sbt/debian /" | tee -a /etc/apt/sources.list.d/sbt.list
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2EE0EA64E40A89B84B2DF73499E82A75642AC823
RUN apt-get update && apt-get install -y sbt


COPY joern /opt/joern/

⁠cflow_joern5

FROM woffee/keras:cflow_joern3

RUN pip install dask networkx clang

RUN apt-get update && apt-get install -y clang-8 && rm -rf /var/lib/apt/lists/*

RUN pip install tensorboardX

RUN pip install torch-scatter torch-sparse torch-cluster torch-spline-conv torch-geometric -f https://pytorch-geometric.com/whl/torch-1.8.0+cu101.html

⁠cflow_joern6

FROM woffee/keras:cflow_joern3

RUN pip install dask networkx clang

RUN apt-get update && apt-get install -y clang-8 && rm -rf /var/lib/apt/lists/*

RUN pip install tensorboardX

RUN pip install torch-scatter torch-sparse torch-cluster torch-spline-conv torch-geometric -f https://pytorch-geometric.com/whl/torch-1.8.0+cu101.html

RUN pip install keras_radam msgpack progressbar2 keras-rectified-adam tqdm
RUN pip install stellargraph
RUN python -m pip install --upgrade nni

COPY config.py /opt/conda/lib/python3.7/site-packages/nni/runtime/config.py
RUN rm -rf ~/.cache/pip
⁠6.1 (added Understand based on joern6)
⁠6.2 (added dgl based on joern6)
FROM woffee/keras:cflow_joern6
RUN pip install dgl-cu100 -f https://data.dgl.ai/wheels/repo.html && rm -rf ~/.cache/pip

Tag summary

Content type

Image

Digest

Size

3 GB

Last updated

almost 5 years ago

docker pull woffee/keras:py37_nni