Lets say, from a jupyter-notebook, one scatter an object to a cluster of workers, ( using the GatewayCluster in my case ). Followed by shutting down, and restarting the jupyter-kernel. I can reconnect to the cluster, and see the scattered object still being present from the dashboard.
Is it also possible to recreate the reference to the object?
Something like:
from dask_gateway import GatewayCluster, Gateway
cluster = GatewayCluster()
from distributed import Client
client = Client(cluster)
n_workers = 4
cluster.scale(n_workers)
client.wait_for_workers(n_workers)
data_scattered = client.scatter(np.empty((10,)))
followed by restarting the local jupyter-kernel, and running the following
from dask_gateway import GatewayCluster, Gateway
g = Gateway()
cluster = g.connect(g.list_clusters()[0].name)
from distributed import Client
client = Client(cluster)
### Recreate reference to data_scattered here?
Best,