Hi All, I am running a kedro pipeline along with d...
# questions
a
Hi All, I am running a kedro pipeline along with databricks notebooks. using the below code in a databricks.
Copy code
reload_kedro("../../../", env="base", extra_params=extra_params)

 with KedroSession.create(project_path="../", env="base", extra_params=extra_params) as session:
        session.run(pipeline_name="kedro_pipeline_name")
It runs a kedro session with the input parameters. Is there a way the kedro pipeline can return params/value back to the databricks notebooks? something similar to a
return
statement.
a
Hey Adith, what values do you want the session to return? The
session.run()
returns a
dict
of datasets that are “free outputs”, i.e. datasets that are
MemoryDataSet
by default
a
I am looking to return a dictionary of values (which can be the output of a kedro node). So if I am not wrong, if I define the output of the kedro node as a MemoryDataSet, I can access the output as a return value of session.run()?
a
Yes if the outputs are not defined in the catalog, they’re treated as
MemoryDataSet
and should be returned as the result of the
session.run()