question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Not able to create Dask client using AzureMLCluster object

See original GitHub issue

I have created a Dask cluster on Azure ML using the following API.

amlcluster = AzureMLCluster(ws,
                            vm_size="STANDARD_D1",
                            datastores=[Datastore.get(ws, "my_datastore")], 
                            environment_definition=ws.environments['AzureML-Dask-CPU'], 
                            initial_node_count=2, 
                            scheduler_idle_timeout=600,
                            vnet='some_vnet',
                            subnet='subnet1',
                            vnet_resource_group='some_rsrc_group',
                            ct_name="my_dask_cluster"
)

Once the cluster is created, if I try to print the variable amlcluster in Jupyter Lab, it throws the following error.

KeyError Traceback (most recent call last) /anaconda/envs/azureml_custom_py37/lib/python3.7/site-packages/IPython/core/formatters.py in call(self, obj) 916 method = get_real_method(obj, self.print_method) 917 if method is not None: –> 918 method() 919 return True 920

/anaconda/envs/azureml_custom_py37/lib/python3.7/site-packages/distributed/deploy/cluster.py in ipython_display(self, **kwargs) 361 from IPython.display import display 362 –> 363 data = {“text/plain”: repr(self), “text/html”: self.repr_html()} 364 display(data, raw=True) 365

/anaconda/envs/azureml_custom_py37/lib/python3.7/site-packages/distributed/deploy/cluster.py in repr(self) 389 self._cluster_class_name, 390 self.scheduler_address, –> 391 len(self.scheduler_info[“workers”]), 392 sum(w[“nthreads”] for w in self.scheduler_info[“workers”].values()), 393 )

KeyError: ‘workers’

After the error, it provides just a Dashboard Link. Not sure if it is supposed to print anything else.

image

If I try to create a Dask Client that alos fails:

client = Client(amlcluster)

This is how the library version looks like for me:

dask 2.20.0 py_0 dask-cloudprovider 0.4.1 <pip> dask-core 2.20.0 py_0 dask-glm 0.2.0 py_1 conda-forge dask-ml 1.6.0 py_0 conda-forge dask-xgboost 0.1.10 <pip>

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:16 (16 by maintainers)

github_iconTop GitHub Comments

1reaction
nickeubankcommented, Nov 12, 2020

Huh, ok! Guess the problem is more recent than 2.20! Maybe there’s another line of code added somewhere elses. I’ll change the bump suggestion in #165 to 2.30.

1reaction
nickeubankcommented, Nov 11, 2020

Replicated! I downgraded distributed to 2.11, and I got this:

image

Opening new issue about bumping the version requirement.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Can't setup an AzureML Dask Cluster · Issue #242 - GitHub
When I follow along the using-dask tutorial to setup a Dask cluster, I fail to create a new cluster with an odd error...
Read more >
Dask Cluster on Azure Example - Practical Data Science
You can see this quota by going to the Compute Clusters tab using the steps above and clicking the View Quota . (Note...
Read more >
Library to turn Azure ML Compute into Ray and Dask cluster
To address this gap, we have developed a library that can easily turn Azure ML compute instance and compute cluster into Ray and...
Read more >
Deploy Dask Clusters - Dask documentation
This page describes various ways to set up Dask clusters on different hardware, either locally on your own machine or on a distributed...
Read more >
Use a Dask Cluster in a PythonScriptStep - Stack Overflow
We've been working and recently released a dask_cloudprovider.AzureMLCluster that might be of interest to you: link to repo.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found