Skip to content
Snippets Groups Projects
Commit 683ba759 authored by leufen1's avatar leufen1
Browse files

added how to plugin custom model to docs too

parent 319a0af9
No related branches found
No related tags found
4 merge requests!156include current development into release,!155Resolve "new release v0.12.1",!152Resolve "Update README HPC setup",!139Draft: Resolve "KZ filter"
Pipeline #46322 passed
...@@ -308,7 +308,7 @@ class MyCustomisedModel(AbstractModelClass): ...@@ -308,7 +308,7 @@ class MyCustomisedModel(AbstractModelClass):
self.compile_options = {"optimizer" = keras.optimizers.Adam()} self.compile_options = {"optimizer" = keras.optimizers.Adam()}
``` ```
### How to plug in the customised model into the workflow? ## How to plug in the customised model into the workflow?
* Make use of the `model` argument and pass `MyCustomisedModel` when instantiating a workflow. * Make use of the `model` argument and pass `MyCustomisedModel` when instantiating a workflow.
```python ```python
from mlair.workflows import DefaultWorkflow from mlair.workflows import DefaultWorkflow
......
...@@ -143,6 +143,20 @@ How to create a customised model? ...@@ -143,6 +143,20 @@ How to create a customised model?
self.compile_options = {"optimizer" = keras.optimizers.Adam()} self.compile_options = {"optimizer" = keras.optimizers.Adam()}
How to plug in the customised model into the workflow?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Make use of the :py:`model` argument and pass :py:`MyCustomisedModel` when instantiating a workflow.
.. code-block:: python
from mlair.workflows import DefaultWorkflow
workflow = DefaultWorkflow(model=MyCustomisedModel)
workflow.run()
Specials for Branched Models Specials for Branched Models
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment