Here we list the requirements of this library from the point of view of the Python versions that are supported and the external programs needed in order to use it.
In order to use the library you need to have Java installed in your system. And, in particular, the environment variable JAVA_HOME must be setted to your current Java installation.
If JAVA_HOME is not setted an error will be thrown at the first import of the library. In that case the following steps must be perfomed:
Install the latest version of Java (follows this link)
Set JAVA_HOME. This can be done differently depending on the your OS:
echo export "JAVA_HOME=/path/to/java" >> ~/.bash_profile source ~/.bash_profile
echo export "JAVA_HOME=\$(/usr/libexec/java_home)" >> ~/.bash_profile source ~/.bash_profile
- Right click My Computer and select Properties
- On the Advanced tab, select Environment Variables, and then edit JAVA_HOME to point to where the JDK software is located, for example, C:\Program Files\Java\jdk1.6.0_02
Currently PyGMQL supports only Python 3.5, 3.6 and 3.7.
Using the github repository¶
You can install this library by downloading its source code from the github repository:
git clone https://github.com/DEIB-GECO/PyGMQL.git
and then using:
cd PyGMQL/ pip install -e .
This will install the library and its dependencies in your system.
The package can be also downloaded and installed directly in your python distribution using:
pip install gmql
Installation of the backend¶
PyGMQL computational engine is written in Scala. The backend comes as a JAR file which will be downloaded at the first usage of the library: