{"id":19310117,"url":"https://github.com/cedadev/jasmin-daskgateway","last_synced_at":"2025-11-15T09:28:11.456Z","repository":{"id":66788749,"uuid":"505879913","full_name":"cedadev/jasmin-daskgateway","owner":"cedadev","description":null,"archived":false,"fork":false,"pushed_at":"2023-04-17T08:44:43.000Z","size":23,"stargazers_count":7,"open_issues_count":5,"forks_count":0,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-01-06T02:09:23.146Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cedadev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-06-21T14:33:16.000Z","updated_at":"2024-08-28T11:00:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"8a700c86-e6fa-4985-8b35-af215c5e6991","html_url":"https://github.com/cedadev/jasmin-daskgateway","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedadev%2Fjasmin-daskgateway","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedadev%2Fjasmin-daskgateway/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedadev%2Fjasmin-daskgateway/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedadev%2Fjasmin-daskgateway/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cedadev","download_url":"https://codeload.github.com/cedadev/jasmin-daskgateway/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240410828,"owners_count":19796968,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T00:22:41.637Z","updated_at":"2025-11-15T09:28:06.402Z","avatar_url":"https://github.com/cedadev.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Using Dask in Lotus from the JASMIN Notebooks Service.\nUsing dask in Lotus requires connecting to a proxy service, called dask-gateway, which will create Lotus jobs on your behalf and proxy communication between your dask client and the dask clusters running in Lotus.\n\nBefore using dask gateway on JASMIN, you **first need to apply for the \"dask\" service on the JASMIN accounts portal**, which you can do so here: https://accounts.jasmin.ac.uk/services/additional_services/dask/\n\n## Creating a dask cluster.\nTo create and connect to a dask cluster, you can use the following python snippet. Note that this will only work on the JASMIN Notebook service.\n```python\nimport dask_gateway\n\n# Create a connection to dask-gateway.\ngw = dask_gateway.Gateway(\"https://dask-gateway.jasmin.ac.uk\", auth=\"jupyterhub\")\n\n# Inspect and change the options if required before creating your cluster.\noptions = gw.cluster_options()\noptions.worker_cores = 2\n\n# Create a dask cluster, or, if one already exists, connect to it.\n# This stage creates the scheduler job in SLURM, so may take some time.\n# While your job queues.\nclusters = gw.list_clusters()\nif not clusters:\n    cluster = gw.new_cluster(options, shutdown_on_close=False)\nelse:\n    cluster = gw.connect(clusters[0].name)\n\n# Create at least one worker, and allow your cluster to scale to three.\ncluster.adapt(minimum=1, maximum=3)\n\n# Get a dask client.\nclient = cluster.get_client()\n```\n\nWhen you are done, and whish to release your cluster:\n```python\ncluster.shutdown()\n```\n\n## Other information and FAQs.\n### Accessing the dask dashboard.\nCurrently the dask dashboard is not accessible from a browser outside the JASMIN firewall. If you're browser fails to load the dashboard link returned, please use our [interactive login service](https://help.jasmin.ac.uk/article/4810-graphical-linux-desktop-access-using-nx) to run a browser inside the firewall to view your dashboard.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedadev%2Fjasmin-daskgateway","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcedadev%2Fjasmin-daskgateway","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedadev%2Fjasmin-daskgateway/lists"}