classes and methods for creating electrode objects (solids with a voltage applied) using gmsh and pythonocc-core. Including fast methods to find segment/ray - triangle/boundary intersections.
During installation a Settings.txt file is created in the same directory that settings.py is being installed to (typically in .../site-packages/py_electrodes/py_electrodes/). The settings handler will look for this Settings.txt file every time the script is loaded. The user can change settings in this file. Better would be to copy it to a local directory.
In Windows, this should be:
$APPDATA\py_electrodes\Settings.txt
(typically this is C:\Users<Username>\AppData\Roaming\py_electrodes). The py_electrodes subdirectory has to be created manually.
In Linux it should be:
$HOME/.local/py_electrodes/Settings.txt
The settings handler wil look in those directories first and in the package path second.
The simplest setup is using conda (Anaconda3-tested) The file conda-env.yml can be found in /PyPATools/documents.
Simply create a new Anaconda3 environment from the Navigator (Environments-->Import) or from the command line
conda env create -f conda-env.ymlThe environment name can be changed in the yml file or with the --name flag.
Note: there is a co-dependency between PyPATools and py_electrodes. Please install both for full functionality.
Either:
git clone https://github.com/DanielWinklehner/PyPATools.git
cd PyPATools
pip install -e .
git clone https://github.com/DanielWinklehner/py_electrodes.git
cd py_electrodes
pip install -e .Or directly (if you don't need the source files and examples):
pip install git+https://github.com/DanielWinklehner/PyPATools.git
pip install git+https://github.com/DanielWinklehner/py_electrodes.gitA community edition of MS Visual Studio (2017 or newer) is also needed to compile some of the c-extensions for cython. Get it for free here: https://visualstudio.microsoft.com/downloads/
In most cases the c compilers for cython are included in the Ubuntu installation. If not, the build-essential package should have what is needed.
sudo apt-get install build-essentialIt looks like the 3D rendering drivers are missing in a vanilla Ubuntu 18 installation, install them using:
sudo apt-get install libglu1-mesa