Installation¶
vipdopt can be installed using pip or from source.
Requirements¶
vipdopt has a number of prerequisites for installation:
Python 3.10
Ansys Lumerical FDTD 2021 edition or later
An installation of MPI, for running simulations in parallel
Qt6
There are also a number of dependencies on other Python libraries, all of which
will be installed automatically with vipdopt:
Installing with pip¶
To install using pip run
pip install vipdopt
We discuss installation from the source code below.
Installation from Source¶
To install using the source code, first clone the GitHub repository using git. This can be done with the following command:
git clone https://github.com/Faraon-Lab/vidpopt.git
cd vipdopt
Then you want to do the following:
Create a development environment (virtual environemnt or conda environment)
Install all the dependencies (build, dev, and test requirements)
Build vipdopt (this will look the same regardless of if you’re using vevn or conda)
If you’re using pip this will look like:
Create and activate a new virtual environment named venv.
python -m venv venv
source venv/bin/activate
Then install the Python dependencies from PyPi:
python -m pip install -r all_requirements.txt
Create and activate a new conda environment named vipdopt-dev with the
requirements installed with:
conda env create -f environment.yaml
conda activate vipdopt-dev
To build vipdopt in an activated environment, run:
python setup.py install
Lumerical Installation Path¶
By default, running setup.py will search for Lumerical in the default directory.
This is C:\Program Files\Lumerical for Windows or /opt/lumerical/ on Linux.
If you would like to use an installation of Lumerical that is not in the default
installation diectory, you can specify this by editing setup.cfg.
The property lumapi_path is the path to the Lumerical Python API. It might be
C:\Program Files\Lumerical\v221\api\python\lumapi.py
You can also change your preferred version with the lumerical_version option.
This option supports glob patterns. If unset, it will use the latest compatible version.