Skip to content
Snippets Groups Projects
Commit d6ffaecb authored by Jean-Baptiste Keck's avatar Jean-Baptiste Keck
Browse files

fixed advection test path, reduced transposition test load, added working debian dockerfile

parent 897ea3a1
No related branches found
No related tags found
No related merge requests found
Pipeline #
# Test docker for gitlab-ci # Test docker for gitlab-ci
FROM debian:latest FROM debian:stretch
MAINTAINER Franck.Perignon@imag.fr MAINTAINER Jean-Baptiste.Keck@imag.fr
# we need cmake, python ...
RUN apt-get update && apt-get install -y \ # upgrade initial image
cmake\ RUN apt-get update
ssh\ RUN apt-get upgrade -y
python-dev\
libblas-dev\ # get build tools and required libraries
python\ RUN apt-get install -y expat
liblapacke-dev\ RUN apt-get install -y automake
libatlas-base-dev\ RUN apt-get install -y pkg-config
libatlas-dev\ RUN apt-get install -y cmake
gcc\ RUN apt-get install -y git
libgfortran3\ RUN apt-get install -y ssh
libgcc1\ RUN apt-get install -y gcc
libgcc-4.9-dev\ RUN apt-get install -y gfortran
gfortran\ RUN apt-get install -y cython
python-pip\ RUN apt-get install -y swig
openmpi-bin\ RUN apt-get install -y libreadline-dev
libopenmpi-dev\ RUN apt-get install -y libboost-all-dev
libhdf5-openmpi-dev\ RUN apt-get install -y libblas-dev
cython\ RUN apt-get install -y liblapack-dev
python-numpy\ RUN apt-get install -y libcgal-dev
python-scipy\ RUN apt-get install -y libatlas-base-dev
python-pyopencl\ RUN apt-get install -y libatlas-dev
python-scitools\ RUN apt-get install -y libopenblas-dev
libfftw3-dev\ RUN apt-get install -y libgfortran3
libfftw3-mpi-dev\ RUN apt-get install -y libgcc1
python-pytest\ RUN apt-get install -y libopenmpi-dev
wget && \ RUN apt-get install -y libhdf5-openmpi-dev
rm -rf /var/lib/apt/lists/* RUN apt-get install -y libfftw3-dev
RUN apt-get install -y libfftw3-mpi-dev
RUN apt-get install -y libgmp-dev
RUN apt-get install -y libmpfr-dev
RUN apt-get install -y libmpc-dev
RUN apt-get install -y libsparsehash-dev
RUN apt-get install -y python
RUN apt-get install -y python-dev
RUN apt-get install -y python-pip
RUN apt-get install -y opencl-headers
RUN apt-get install -y ocl-icd-libopencl1
RUN apt-get install -y clinfo
# python packages
RUN pip install --upgrade pip RUN pip install --upgrade pip
RUN pip install --upgrade setuptools RUN pip install --upgrade setuptools
RUN pip install cffi
RUN pip install wheel
RUN pip install pytest
RUN pip install numpy
RUN pip install scipy
RUN pip install sympy
RUN pip install matplotlib
RUN pip install mpi4py RUN pip install mpi4py
RUN pip install sphinx RUN pip install sphinx
RUN pip install wheel RUN pip install h5py
RUN wget https://pypi.python.org/packages/22/82/64dada5382a60471f85f16eb7d01cc1a9620aea855cd665609adf6fdbb0d/h5py-2.6.0.tar.gz && \ RUN pip install gmpy2
tar -zxvf h5py-2.6.0.tar.gz && \ RUN pip install psutil
cd h5py-2.6.0 && \ RUN pip install py-cpuinfo
export CC=mpicc && \ RUN pip install Mako
export CFLAGS="-I/usr/include/hdf5/openmpi/"&& \
export LDFLAGS="-L /usr/lib/x86_64-linux-gnu/hdf5/openmpi/"&& \ RUN cd /tmp \
python setup.py configure --mpi --hdf5=/usr/ && \ && git clone https://github.com/hplgit/scitools \
python setup.py install && \ && cd scitools \
cd .. && \ && pip install . \
rm -rf h5py-2.6.0* && cd - \
RUN cd .. && rm -Rf /tmp/scitools
# patchelf
RUN cd /tmp \
&& git clone https://github.com/NixOS/patchelf \
&& cd patchelf \
&& ./bootstrap.sh \
&& ./configure \
&& make \
&& make install \
&& cd - \
&& rm -Rf /tmp/patchelf
# precompiled python graphtools (need to be patched with patchelf)
RUN echo 'deb http://downloads.skewed.de/apt/stretch stretch main' >> /etc/apt/sources.list \
&& echo 'deb-src http://downloads.skewed.de/apt/stretch stretch main' >> /etc/apt/sources.list \
&& apt-get update \
&& apt-get install --assume-yes --allow-unauthenticated python-graph-tool \
&& patchelf --add-needed libboost_context.so $(find /usr/ -name 'libgraph_tool_search.so')
RUN echo 'deb http://apt.llvm.org/stretch/ llvm-toolchain-stretch main' >> /etc/apt/sources.list \
&& echo 'deb-src http://apt.llvm.org/stretch/ llvm-toolchain-stretch main' >> /etc/apt/sources.list \
&& apt-get update \
&& apt-get install --assume-yes --allow-unauthenticated llvm-3.8 clang-3.8 libllvm3.8 libclang-3.8-dev
# POCL
RUN cd /tmp \
&& git clone http://github.com/pocl/pocl \
&& cd pocl \
&& mkdir build \
&& cd build \
&& cmake -DCMAKE_BUILD_TYPE=Release .. \
&& make \
&& make install \
&& cd -- \
&& rm -Rf /tmp/pocl
# pyopencl
RUN cd /tmp \
&& rm -f /usr/lib/x86_64-linux-gnu/libOpenCL.so.* \
&& ldconfig \
&& git clone https://github.com/inducer/pyopencl \
&& cd pyopencl \
&& git submodule update --init \
&& ./configure.py \
&& echo 'CL_PRETEND_VERSION="1.2"' >> siteconf.py \
&& make \
&& pip install --upgrade . \
&& cd - \
&& rm -Rf /tmp/pyopencl
# oclgrind
RUN apt-get install --assume-yes --allow-unauthenticated llvm-6.0 clang-6.0 libllvm6.0 libclang-6.0-dev
RUN cd /tmp \
&& git clone https://github.com/jrprice/Oclgrind \
&& cd Oclgrind \
&& mkdir build \
&& cd build \
&& cmake -DCMAKE_BUILD_TYPE=Release .. \
&& make \
&& make install \
&& cd - \
&& rm -Rf /tmp/Oclgrind
# clean cached packages
RUN rm -rf /var/lib/apt/lists/*
RUN rm -rf $HOME/.cache/pip/*
RUN rm -rf /tmp/*
CMD ["/bin/bash"] CMD ["/bin/bash"]
...@@ -35,7 +35,7 @@ python -c 'import hysop; print hysop' ...@@ -35,7 +35,7 @@ python -c 'import hysop; print hysop'
python "$HYSOP_DIR/backend/device/codegen/kernels/tests/test_directional_advection.py" python "$HYSOP_DIR/backend/device/codegen/kernels/tests/test_directional_advection.py"
python "$HYSOP_DIR/backend/device/codegen/kernels/tests/test_directional_remesh.py" python "$HYSOP_DIR/backend/device/codegen/kernels/tests/test_directional_remesh.py"
python "$HYSOP_DIR/operator/tests/test_transpose.py" python "$HYSOP_DIR/operator/tests/test_transpose.py"
python "$HYSOP_DIR/operator/tests/test_advection.py" python "$HYSOP_DIR/operator/tests/test_directional_advection.py"
python "$HYSOP_DIR/operator/tests/test_custom_symbolic.py" python "$HYSOP_DIR/operator/tests/test_custom_symbolic.py"
cp -r /root/.cache/* $CACHE_DIR/ cp -r /root/.cache/* $CACHE_DIR/
......
...@@ -212,13 +212,15 @@ class TestTransposeOperator(object): ...@@ -212,13 +212,15 @@ class TestTransposeOperator(object):
def perform_tests(self): def perform_tests(self):
self.test_2d_out_of_place() self.test_2d_out_of_place()
self.test_3d_out_of_place() self.test_3d_out_of_place()
self.test_4d_out_of_place() if __ENABLE_LONG_TESTS__:
self.test_upper_dimensions_out_of_place() self.test_4d_out_of_place()
self.test_upper_dimensions_out_of_place()
self.test_2d_inplace() self.test_2d_inplace()
self.test_3d_inplace() self.test_3d_inplace()
self.test_4d_inplace() if __ENABLE_LONG_TESTS__:
self.test_upper_dimensions_inplace() self.test_4d_inplace()
self.test_upper_dimensions_inplace()
if __name__ == '__main__': if __name__ == '__main__':
TestTransposeOperator.setup_class(enable_extra_tests=False, TestTransposeOperator.setup_class(enable_extra_tests=False,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment