NotebookRunConfig Class
Sets up configuration for notebooks runs.
Class NotebookRunConfig constructor.
- Inheritance
-
NotebookRunConfig
Constructor
NotebookRunConfig(source_directory, notebook, output_notebook=None, parameters=None, handler=None, run_config=None, _telemetry_values=None)
Parameters
- run_config
- RunConfiguration
default value: None
- handler
- <xref:.NotebookExecutionHandler>
Required
The instance of the NotebookExecutionHandler.
- run_config
- RunConfiguration
Required
Remarks
# Import dependencies
from azureml.core import Workspace, Experiment, RunConfiguration
from azureml.contrib.notebook import NotebookRunConfig
# Create new experiment
workspace = Workspace.from_config()
exp = Experiment(workspace, "simple_notebook_experiment")
# Customize run configuration to execute in user managed environment
run_config_user_managed = RunConfiguration()
run_config_user_managed.environment.python.user_managed_dependencies = True
# Create notebook run configuration and set parameters values
cfg = NotebookRunConfig(source_directory="./notebooks",
notebook="notebook-sample.ipynb",
parameters={"arg1": "Machine Learning"},
run_config=run_config_user_managed)
# Submit experiment and wait for completion
run = exp.submit(cfg)
run.wait_for_completion(show_output=True)
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for