Skip to content

Commit

Permalink
Need to explicitly link correct openblas lib in nvconf
Browse files Browse the repository at this point in the history
Note that this path differs in Debian vs Ubuntu-based images
  • Loading branch information
cboettig committed Jul 31, 2019
1 parent cc40ba7 commit a08d32d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 8 deletions.
10 changes: 5 additions & 5 deletions ubuntu/10.0/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,20 @@ RUN . /tmp/install_R.sh


COPY install_rstudio.sh /tmp/install_rstudio.sh
RUN . /tmp/install_rstudio.sh
#RUN . /tmp/install_rstudio.sh
COPY userconf.sh /etc/cont-init.d/userconf
EXPOSE 8787
CMD ["/init"]
#CMD ["/init"]



COPY install_tidyverse.sh /tmp/install_tidyverse.sh
RUN . /tmp/install_tidyverse.sh
#RUN . /tmp/install_tidyverse.sh



COPY install_verse.sh /tmp/install_verse.sh
RUN . /tmp/install_verse.sh
#RUN . /tmp/install_verse.sh



Expand All @@ -57,5 +57,5 @@ RUN . /tmp/install_python.sh


COPY install_tensorflow-gpu.sh /tmp/install_tensorflow-gpu.sh
RUN . /tmp/install_tensorflow-gpu.sh
#RUN . /tmp/install_tensorflow-gpu.sh

9 changes: 7 additions & 2 deletions ubuntu/10.0/config_R_cuda.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,18 @@ set -e
## (From https://tensorflow.rstudio.com/tools/local_gpu.html#environment-variables)
echo "\n\
\nCUDA_HOME=$CUDA_HOME\
\nPATH=$PATH" >> ${R_HOME}/etc/Renviron && \
\nPATH=$PATH" >> ${R_HOME}/etc/Renviron

if test -f /etc/rstudio/rserver.conf; then
echo "rsession-ld-library-path=$LD_LIBRARY_PATH" >> /etc/rstudio/rserver.conf
fi

touch /var/log/nvblas.log && chown :staff /var/log/nvblas.log

## Configure R & RStudio to use drop-in CUDA blas
## Allow R to use CUDA for BLAS, with fallback on openblas
echo "\nNVBLAS_LOGFILE /var/log/nvblas.log \
\nNVBLAS_CPU_BLAS_LIB /usr/lib/libopenblas.so \
\nNVBLAS_CPU_BLAS_LIB /usr/lib/x86_64-linux-gnu/openblas/libblas.so.3 \
\nNVBLAS_GPU_LIST ALL" > /etc/nvblas.conf

echo "NVBLAS_CONFIG_FILE=$NVBLAS_CONFIG_FILE" >> ${R_HOME}/etc/Renviron
Expand Down
2 changes: 1 addition & 1 deletion ubuntu/10.0/install_python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@ echo "\nRETICULATE_PYTHON_ENV=${RETICULATE_PYTHON_ENV}" >> ${R_HOME}/etc/Renviro
ln -s ${PYTHON_VENV_PATH}/bin/pip /usr/local/bin/pip
ln -s ${PYTHON_VENV_PATH}/bin/virtualenv /usr/local/bin/virtualenv

chown -R rstudio:rstudio ${PYTHON_VENV_PATH}
chown :staff ${PYTHON_VENV_PATH}

0 comments on commit a08d32d

Please sign in to comment.