diff --git a/Dockerfile b/Dockerfile index 6899ae7..f58db32 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ # _|_| \|||_| \| ||_|_/_|_/--\||_ _|_| |/--\\_||_ ############################################################################################### -FROM murphylab/matlabmcr2018b-jupyter as intermediate +FROM murphylab/matlabmcr2018b-jupyter:18.04 as intermediate ############################################################################################### # INSTALL BFTOOLS @@ -24,8 +24,8 @@ RUN echo "Downloading CellOrganizer v2.8.0" && \ wget -nc --quiet http://www.cellorganizer.org/Downloads/v2.8.0/docker/cellorganizer-binaries-matlabmcr2018b.tgz && \ tar -xvf cellorganizer-binaries-matlabmcr2018b.tgz && \ rm cellorganizer-binaries-matlabmcr2018b.tgz && \ - mv cellorganizer-binaries /opt - + mv cellorganizer-binaries /opt +COPY tiff2ometiff /opt/cellorganizer-binaries RUN mkdir /home/murphylab/cellorganizer-python && mkdir /home/murphylab/cellorganizer COPY cellorganizer-python /home/murphylab/cellorganizer-python ############################################################################################### @@ -55,7 +55,7 @@ COPY files /home/murphylab/cellorganizer ############################################################################################### # COPY CELLORGANIZER LOGO TO JUPYTER NOTEBOOK RUN wget --quiet -nc http://www.cellorganizer.org/Downloads/v2.8.0/docker/logo.png && \ - mv -v logo.png /opt/conda/lib/python3.6/site-packages/notebook/static/base/images + mv -v logo.png /opt/conda/lib/python3.7/site-packages/notebook/static/base/images ############################################################################################### ############################################################################################### @@ -65,7 +65,7 @@ RUN wget --quiet -nc http://www.cellorganizer.org/Downloads/v2.8.0/docker/logo.p # ############################################################################################### -FROM murphylab/matlabmcr2018b-jupyter +FROM murphylab/matlabmcr2018b-jupyter:18.04 ############################################################################################### MAINTAINER Ivan E. Cao-Berg @@ -92,11 +92,13 @@ RUN chmod +x /opt/cellorganizer-binaries/img2slml && \ chmod +x /opt/cellorganizer-binaries/slml2report && \ chmod +x /opt/cellorganizer-binaries/slml2info && \ chmod +x /opt/cellorganizer-binaries/slml2slml && \ + chmod +x /opt/cellorganizer-binaries/tiff2ometiff && \ ln -s /opt/cellorganizer-binaries/img2slml /usr/local/bin/img2slml && \ ln -s /opt/cellorganizer-binaries/slml2img /usr/local/bin/slml2img && \ ln -s /opt/cellorganizer-binaries/slml2report /usr/local/bin/slml2report && \ ln -s /opt/cellorganizer-binaries/slml2info /usr/local/bin/slml2info && \ - ln -s /opt/cellorganizer-binaries/slml2slml /usr/local/bin/slml2slml + ln -s /opt/cellorganizer-binaries/slml2slml /usr/local/bin/slml2slml && \ + ln -s /opt/cellorganizer-binaries/tiff2ometiff /usr/local/bin/tiff2ometiff # COPY HOME DIRECTORY FROM INTERMEDIATE TO FINAL IMAGE COPY --from=intermediate /home/murphylab /home/murphylab @@ -107,7 +109,12 @@ RUN cd /home/murphylab/cellorganizer-python && python setup.py install RUN rm -rf /home/murphylab/cellorganizer-python # MOVE LOGO FROM INTERMEDIATE TO FINAL IMAGE -COPY --from=intermediate /opt/conda/lib/python3.6/site-packages/notebook/static/base/images/logo.png /opt/conda/lib/python3.6/site-packages/notebook/static/base/images/logo.png +COPY --from=intermediate /opt/conda/lib/python3.7/site-packages/notebook/static/base/images/logo.png /opt/conda/lib/python3.7/site-packages/notebook/static/base/images/logo.png + +# Install Extensions +RUN conda install -c conda-forge jupyter_contrib_nbextensions +RUN jupyter nbextension enable hide_input_all/main +RUN jupyter nbextension enable init_cell/main ############################################################################################### ##############################################################################################\ diff --git a/build.sh b/build.sh index dab7503..4d0ca7f 100644 --- a/build.sh +++ b/build.sh @@ -5,5 +5,5 @@ git submodule update cd cellorganizer-python git checkout master cd .. -docker build --no-cache -t $(whoami)/cellorganizer-jupyter . +docker build -t $(whoami)/cellorganizer-jupyter . diff --git a/cellorganizer-python b/cellorganizer-python index 2bf604f..55ce2f7 160000 --- a/cellorganizer-python +++ b/cellorganizer-python @@ -1 +1 @@ -Subproject commit 2bf604f805ed370bf6adca071f6475e18151957d +Subproject commit 55ce2f752a3d66a80af90f4786e757948caa1fb2 diff --git a/run.sh b/run.sh index dabb737..bcf3df1 100644 --- a/run.sh +++ b/run.sh @@ -1,3 +1,21 @@ #!/bin/bash -docker run --rm -p 8888:8888 -e JUPYTER_LAB_ENABLE=yes murphylab/cellorganizer-jupyter +if [ ! -d data ]; then + mkdir -p data/images + cd data/images + wget -nc http://murphylab.web.cmu.edu/data/TcellModels/LATFull.tgz + tar -xvf LATFull.tgz + rm -fv LATFull.tgz + + wget -nc http://murphylab.web.cmu.edu/data/Hela/3D/multitiff/cellorganizer_full_image_collection.zip + unzip cellorganizer_full_image_collection.zip + rm -fv cellorganizer_full_image_collection.zip + cd ../.. +fi + +docker run --rm -p 8888:8888 \ + -v $(pwd)/data:/home/murphylab/cellorganizer/local \ + --memory="8g" \ + --cpus=2 \ + -e JUPYTER_LAB_ENABLE=yes \ + murphylab/cellorganizer-jupyter