Guild supports a plugin API that is used to modify and extend Guild behavior.
Guild plugins can be used for the following functions:
- Extend or modify Guild file configuration
- Perform tasks during a run
- Provide built-in operations
Enable Plugins for an Operation
By default, plugins are not enabled for operations. You can enable one or more plugins for an operation using the
plugins operation attribute.
For example, to enable all summary-related plugins for operation
train: plugins: summary
Guild provides the following built-in plugins:
||Logs CPU usage per step|
||Logs disk usage per step|
||Support for running executable scripts|
||Logs GPU usage per step|
||Support for running Keras scripts|
||Logs memory usage per step|
||Logs last step performance per step|
||Support for running Python scripts|
||Support for queue operations|
||Support for scikit-optimize based operations (e.g. Bayesian optimizers)|
To provide a custom plugin, create a class that extends
guild.plugins.Plugin and register it as a Python entry point.
Refer to Guild AI plugins source code for examples.
Below are specific examples for various uses.
|cpu.py||Log additional scalar values for a given step.|
|python_script.py||Support new operation types — e.g. handling operation specs such as a path to an R script, a Java JAR file, a URL, etc.|
|keras.py||Support new Python based frameworks.|
|skopt.py||Add built-in operations including optimizers.|