I am using AzureML and I have a blob storage container, where I want read data from it and write data to it. Can I achieve that with the path that is being passed to the experiment as follows (from here):
from azureml.core import Workspace
ws: Workspace = Workspace.from_config()
compute_target: ComputeTarget = ws.compute_targets['<compute-target-name>']
ds: Datastore = ws.get_default_datastore()
data_ref = ds.path('<path/on/datastore>').as_mount()
config = ScriptRunConfig(
source_directory='.',
script='script.py',
arguments=[str(data_ref)], # returns environment variable $AZUREML_DATAREFERENCE_example_data
compute_target=compute_target,
)
config.run_config.data_references[data_ref.data_reference_name] = data_ref.to_config()
If so, what is the purpose of OutputFileDatasetConfig class in the API? Is it just a convenient shortcut to the path in the container?
from azureml.data import OutputFileDatasetConfig
output = OutputFileDatasetConfig(folder, destination=(datastore_obj, path_to_folder))
arguments = [output]
Thanks