The AOCL-DA Python API comes with numerous example scripts, which are installed when you invoke pip install aoclda-*.whl.
To locate these examples, the following commands can be used in your Python interpreter:
>>> from aoclda.examples import info
>>> info.examples_path()
>>> info.examples_list()
Alternatively, from your command prompt, you can call aocl.examples.info as a module to obtain the same information:
python -m aoclda.examples.info
The examples can then be run as standard Python scripts from the command prompt. For example:
python path/to/examples/pca_ex.py
You can also inspect and run the examples from a Python interpreter. For example:
>>> from aoclda.examples import pca_ex
>>> import inspect
>>> print(''.join(inspect.getsourcelines(pca_ex)[0]))
>>> pca_ex.pca_example()