bigartm / bigartm-docker

Docker image with latest BigARTM build
3 stars 4 forks source link

Use jupyter notebook with bigartm-docker #3

Open elluminatte opened 6 years ago

elluminatte commented 6 years ago

Hello! Thanks for your great platform!

Is it possible to use jupyter notebook for communication with BigARTM running in Docker container?

I've started ofrei/bigartm, then tried to start notebook as described here (https://github.com/jupyter-attic/docker-notebook/tree/master/notebook), but got artm import error.

I've tried to replace ipython/scipystack with ipython/scipyserver too, but got building error.

Looks like I'm frustrated with this. I hope that you've already tried to use notebook together with ofrei/bigartm, and it will be very easy for you to prompt me the solution.

Regards, Nikolay

elluminatte commented 6 years ago

Investigated the problem myself.

So to be able to use Jupyter Notebook with BigARTM in docker I made:

  1. Fixed tornado version issue in original ofrei/bigartm image - notebook requires v >= 4.0, but image provides v 3.1. I used this snippet in Dockerfile:
WORKDIR /usr/lib/python3/dist-packages

RUN apt-get remove -y python-tornado
RUN rm -rf tornado-3.1.1.egg-info && rm -rf tornado

RUN pip2 install tornado --upgrade --ignore-installed
RUN pip3 install tornado --upgrade --ignore-installed
  1. Build scipyserver image from fixed image (see previous item). Just replaced first line in scipyserver Dockerfile:
FROM <your-awesome-tag>/bigartm

May be this will be useful for somebody, so I've pushed images to Dockerhub: elluminatte/scipyserver and elluminatte/bigartm