To use Python and the Shogun Live Python module, you must first install them.
Both Python 2 and Python 3 are supported. Vicon recommends that you use the latest full release of Python 3, unless your project requires you to use a specific version of Python.
Note |
For information on installation, see:
To install Python 2 or 3:
To install the Python module:
The simplest way is to run the batch file (install_shogun_live_api.bat) that is included in the Shogun Live installation (as shown in the above image). This usually works well if:
Python was installed to the PATH variable; or
Multiple versions of Python are installed but you want to install the API to the latest version that you installed; or
Only a single version of Python is installed.
If any of these conditions apply, install the Python module by running the batch file.
In all other cases, install the Python module by using pip. This usually applies if:
Multiple versions of Python are installed but you want to install to a specific version; or
Multiple different versions of Python are installed and you want to install to all of them (in this case, you must install the module for each version); or
If any of these conditions apply, install the Python module by running pip.
To do this, in a cmd window, run the batch file, install_shogun_live_api.bat.
Important By default, you can find the SDK folder at C:\Program Files\Vicon\ShogunLive1.10\SDK (if you installed Shogun in another location, use this path to find the SDK folder). We recommend copying the SDK folder into a new folder with an easy-to-access location, for example, "C:\ShogunLiveAPI". You can delete this folder after the pip installation is complete. The steps in this guide assume you have copied the SDK folder to C:\ShogunLiveAPI. |
.\pip.exe install "C:\ShogunLiveAPI\SDK\Python\vicon_core_api"
.\pip.exe install "C:\ShogunLiveAPI\SDK\Python\shogun_live_api"
To test that the Shogun Live Python module installed correctly, run Python and try the following import statements:
import vicon_core_api
import shogun_live_api

If these import without any errors then the installation has been successful.