Configuration¶
When all prerequisites have been installed, a system environment variable pythonpath
must be set pointing to
the location of the Python module in the BDB installation folder. This can be done at the start of a scripting
session, or set permanently in the operating system.
To set this environment variable in a scripting session, enter the following command line for each application respectively:
For a BASE Editor installation:
set pythonpath=%pythonpath%;C:/Program Files/CARIS/BASE Editor/5.3/python/3.5
For a BDB Server installation:
set pythonpath=%pythonpath%;C:/Program Files/CARIS/BDB Server/5.3/python/3.5
Note
If using Python 3.4, replace 3.5 in the path with 3.4.
To permanently set this environment variable in the operating system:
- Navigate to the system settings in Control Panel > System > Advanced tab.
- Click Environment Variables.
- Under System variables, click New.
- Enter the variable name
pythonpath
and variable valueC:/Program Files/CARIS/BASE Editor/5.3/python/3.5
(or variation as outlined above).
Note
%pythonpath%;
is only needed when defining the variable in a command line session.
Testing Python¶
To test the Python bindings for BDB Server:
Open a Windows Command Prompt window and navigate to the Python installation folder.
Start the Python console interface by typing “Python” and pressing Enter.
Enter the following:
import caris.bathy.db
If there are no errors or warnings generated after executing this statement, the Python bindings for BDB Server have been successfully configured.