CellDraw Status
Starting with CC3D 3.7.6 version, the main part of CC3D interface was ported from PyQt4 to PyQt5. However CellDraw was not a part of this code translation and as result current versions of CC3D do not ship with CellDraw run script. this may cause an inconvenience to users who rely on CellDraw. We will port CellDraw to PyQt5 but meanwhile we would like to suggest the following two solutions
Solution 1
You may install older version of CC3D for the sole purpose of using CellDraw. This way on your system you may have two CC3D installations - 3.7.5 supporting CellDraw and newer version of CC3D (e.g. 3.7.7.) where CellDraw is not supported. Keep in mind that PIFF files generated with cell draw will work with newer versions of CC3D.
Solution 2
This solution involves installing miniconda (Python distribution/python package manager developed by Continuum Analytics) , creating virtual environment and running CellDraw directly from the command line. Here are the steps:
1. Install miniconda2 - Miniconda download page 2. Create Virtual Python Environment.
After you installed miniconda you need to create virtual python environment using the following command:
conda create -n cell_draw_env python
cell_draw_env is a name of the python virtual environment but you can name it however you like. I called it cell_draw_env because it indicates that we created this python virtual environment to run CellDraw
3. Activate new environment:
On Mac/Linux:
source activate cell_draw_env
on Windows
activate cell_draw_env
4. install PyQt4, numpy and vtk :
conda install pyqt=4.11 numpy vtk
5. Clone CC3D Source code :
mkdir /Users/m/CC3D_CELLDRAW_GIT cd CC3D_CELLDRAW_GIT git clone https://github.com/CompuCell3D/CompuCell3D.git . git checkout 3.7.9
Keep in mind that in your case you will need to change /Users/m prefix to the path to your home directory 6. Run CellDraw:
Go to the directory with the CellDraw code - in our example it means executing the following command
cd ~/CC3D_CELLDRAW_GIT/CellDraw/1.5.2/src
Now add two environment variables that CellDraw expects to see (PREFIX_CELLDRAW, PREFIX_CC3D):
export PREFIX_CELLDRAW=/Users/m/CC3D_CELLDRAW_GIT/CellDraw/1.5.2/src export PREFIX_CC3D=/Users/m/Demo2/CC3D_3.7.7/
Note: I have set the path to CC3D installation directory in such a away that it point to 3.7.7. version of CC3D
At this point you should be able to run CellDraw:
cd /Users/m/CC3D_CELLDRAW_GIT/CellDraw/1.5.2/src python cellDrawMain.pyw
Note that you can create a bash script that automates all those steps. Here is an example of such script:
cd "${0%/*}" export PREFIX_CELLDRAW=/Users/m/CC3D_CELLDRAW_GIT/CellDraw/1.5.2/src current_directory=$(pwd) cd $PREFIX_CELLDRAW export PREFIX_CC3D=/Users/m/Demo2/CC3D_3.7.7 export CELLDRAW_MAJOR_VERSION=1 export CELLDRAW_MINOR_VERSION=5 export CELLDRAW_BUILD_VERSION=2 python ${PREFIX_CELLDRAW}/cellDrawMain.pyw. cd ${current_directory}
Keep in mind that you will ned to specify correct paths for PREFIX_CELLDRAW and for PREFIX_CC3D
Save the script as celldraw_custom.sh and make it executable:
chmod +x celldraw_custom.sh
Now to run CellDraw all you need is to type:
./celldraw_custom.sh
and I assumed that this last command is executed from the directory where you stored the script