Windows¶
Installing Python on Windows¶
Note
Python is not generally installed by default on Windows and may need to be installed, possibly in a virtual environment. The toolkits can be used with Anaconda, virtualenv, and venv and can be both conda and pip installed.
However python can be downloaded from http://www.python.org/download/ and installed on your system if desired.
Installing OpenEye Python Toolkits As A Conda package¶
The simplest way to install the OpenEye Python Toolkits is as a Conda package.
The Anaconda package can be downloaded from https://www.anaconda.com/download for Windows, macOS and Linux platforms. Follow the very simple instructions given there for installation.
Note
While Anaconda is available free of charge for personal use, users may need to purchase an Anaconda license if they are doing commercial development. Please check the Anaconda license terms.
For first time users we also recommend reading Getting started with conda and print out the Conda user cheat sheet reference.
Note
OpenEye Python Toolkits only supports Python3.
After downloading and installing Anaconda, the OpenEye Python Toolkit package can be installed by the following steps:
First create a new conda environment with the OpenEye Python Toolkit package
$ conda create -n oepython -c openeye openeye-toolkits Solving environment: done ## Package Plan ## environment location: C:\Users\username\anaconda3\envs\oepython added / updated specs: - openeye-toolkits The following packages will be downloaded: ... The following NEW packages will be INSTALLED: ... openeye-toolkits: |pypkgversion| -py39_0 openeye ... Proceed ([y]/n)?
After entering “y” to proceed, a new ‘oepython’ environment will be created be activated with the OpenEye Python Toolkit package.
Activate the newly created ‘oepython’ environment:
$ conda activate oepython
Run the OpenEye example oecheminfo.py to verify the installation has completed successfully:
(oepython) $ oecheminfo.py Installed OEChem version: |oechemversion| platform: microsoft-win64-msvc17-x64 built: |builddate| ...
Alternative Installation Strategies¶
To install OpenEye Python Toolkits in existing environments:
The above two ways are highly recommended since it is considered harmful to install packages into your global Python installation.
For assistance with unusual installation environments such as systems without network access or heterogeneous clusters, please contact support at support@eyesopen.com.
Note
In order to follow the PEP 440 guidelines on versions, the version label for the python toolkit is 2024.1.3 instead of 2024.1.3.
Integration Testing¶
The OpenEye Python Toolkits ship with a simple set of integration tests to make sure all the libraries function as intended. The test suite is not as exhaustive as the test suite used internally, it is just meant to ensure the OpenEye Python Toolkits infrastructure is working as intended.
Warning
Running the integration test requires scripttest and nose Python packages. These packages will be installed on-the-fly, if necessary. Again using conda or virtualenv environments will ensure that these packages will not be installed into the global Python environment.
To run the integration test suite (after activating the environment into which OpenEye Python Toolkits has been installed), execute the following command:
$ python -m openeye.examples.openeye_tests
A message like the following will be shown if all the tests were run successfully:
Requirement already satisfied: pytest
Requirement already satisfied: py>=1.4.29
Collecting scripttest
Installing collected packages: scripttest
Successfully installed scripttest-1.3
Ran 42 tests in 95.877s
OK
Tests are skipped when the license is invalid/expired/doesn’t exist or if functionally is not supported on the OS/platform. For example, when using a license file that only contains an OEChem TK license, a large number of tests will be skipped:
SSSSSSSSSSSSSSS.......SSSSSSSSSSSSSSSSSSS
----------------------------------------------------------------------
Ran 42 tests in 0.956s
OK (SKIP=34)
Similarly, FastROCS, GPU-OMEGA, and GPU-GRAPHSIM tests are skipped on macOS, Windows, and Linux systems without appropriate GPU hardware since their functionality is not available.