Windows

Note

Make sure the Python version matches the GSTPy installation package. For example, GSTPy For Python 3.13 requires a Python 3.13.x package. Alternatively, if you already have an existing Python package you want to use, make sure to use the matching GSTPy version.

Install GSTPy

Install the GSTPy Module with the supplied installer. (If you are reading this, you’ve probably already done this).

Install Python

GSTPy requires a Python installation.

  • Go to the official download page and select the desired version. For example, for GSTPy for Python 3.13, select the latest 3.13.x link under “Looking for a specific release?”.

  • Choose the file “Windows installer (64-bit)”.

  • Execute the installer and follow the installation instructions.

Generally, any matching patch release should work. For example, GSTPy for Python 3.13 should work with any Pyhton 3.13.x package.

The GSTPy module depends on the pythonXY.dll. If you used the offical installer, this should work out of the box. Otherwise you need to add the directory containing your pythonXY.dll to your PATH environment variable. Alternatively, you could also copy your pythonXY.dll directly into the GSTPy module directory. (X is the major, Y the minor verison of the Python package. For example, for Python 3.13 this would be python313.dll).

Install Visual C++ Redistributable Packages

Let Python find the GSTPy module

The GSTPy module is located in the bin subdirectory.

If you installed GSTPy under C:\Users\Max\Documents\GiGa infosystems\GSTPy the GSTPy module directory is C:\Users\Max\Documents\GiGa infosystems\GSTPy\bin.

There are three options how we can tell Python about this module directory.

.pth File in Python site-packages

  1. Navigate to your Python install directory (default: “C:\Python27”).

  2. Go to Lib\site-packages.

  3. Add a new file named GSTPy.pth

  4. Edit GSTPy.pth and add the GSTPy module directory as entry.

Example:

C:\Python27\Lib\site-packages\GSTPy.pth
C:\Users\Max\Documents\GiGa infosystems\GSTPy\bin

Environment variable

Add the GSTPy module directory to the PYTHONPATH environment variable.

Local to a Python script

There also exists a method to add it directly in a Python script.

import sys
sys.path.insert(0, r"C:\Users\Max\Documents\GiGa infosystems\GSTPy\bin")
# now Python can find the GSTPy module
import GSTPy

Disadvantage is, you have to use this in any script that imports GSTPy.