Closed nanli-emory closed 6 months ago
Just got to test this out. It looks like this solution worked by chance: I was able to run python3 -m histoqc --help
successfully, but there are two problems.
(base) ray@39580a85d729:/data$ which python3
/home/ray/anaconda3/bin/python3
(base) ray@39580a85d729:/data$ python3
Python 3.8.18 (default, Sep 11 2023, 13:40:15)
[GCC 11.2.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import shapely
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'shapely'
>>>
(base) ray@39580a85d729:/data$ conda deactivate
ray@39580a85d729:/data$ source /opt/HistoQC/venv/bin/activate
(venv) ray@39580a85d729:/data$ pip freeze
bash: /opt/HistoQC/venv/bin/pip: /opt/HistoQC/venv/bin/python: bad interpreter: No such file or directory
(venv) ray@39580a85d729:/data$
(venv) ray@39580a85d729:/data$ python
Python 3.8.18 (default, Sep 11 2023, 13:40:15)
[GCC 11.2.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import shapely
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'shapely'
>>>
Hi @jacksonjacobs1 I updated dockerfile and setup.cfg and setup.py. I put the config_v2.1.ini and .svs files in ./slides and tested on my local docker. pipline runs successfully.:
docker build -t ray-histoqc -f ./Dockerfile .
docker run --name ray-histoqc-instance -it -v ./slides:/data ray-histoqc
Please review and check. Thanks.
Cool! This works for me too.
Quick question: what do we still need the venv for.... https://github.com/nanli-emory/HistoQC/blob/dc85fd0143b090e404a73e03ba23c3fb9ead1bbd/Dockerfile#L13 ....since we are installing HistoQC and it's dependencies again in the conda environment?
IF we don't need to install histoqc in the venv, we also don't need a builder (the python3.8 base image). What do you think? https://github.com/nanli-emory/HistoQC/blob/dc85fd0143b090e404a73e03ba23c3fb9ead1bbd/Dockerfile#L6
Let's keep CMD ["bash"]
at the end for now. Once setup completes, the container will connect the user to an internal bash shell to manually run histoQC commands.
Hi @jacksonjacobs1 , I updated the dockerfile and remove the first stage build part. Please check.
I tried building and running the histoqc image with this docker file and it does not seem to install histoqc:
The reason is because python is only installed in a conda environment: