Render the computation of this object's task graph using graphviz. Requires ``graphviz`` to be installed. Parameters ---------- filename : str or None, optional The name of the file to write to disk. If the provided `filename` doesn't include
(self, filename="mydask", format=None, optimize_graph=False, **kwargs)
| 257 | __slots__ = ("__weakref__",) |
| 258 | |
| 259 | def visualize(self, filename="mydask", format=None, optimize_graph=False, **kwargs): |
| 260 | """Render the computation of this object's task graph using graphviz. |
| 261 | |
| 262 | Requires ``graphviz`` to be installed. |
| 263 | |
| 264 | Parameters |
| 265 | ---------- |
| 266 | filename : str or None, optional |
| 267 | The name of the file to write to disk. If the provided `filename` |
| 268 | doesn't include an extension, '.png' will be used by default. |
| 269 | If `filename` is None, no file will be written, and we communicate |
| 270 | with dot using only pipes. |
| 271 | format : {'png', 'pdf', 'dot', 'svg', 'jpeg', 'jpg'}, optional |
| 272 | Format in which to write output file. Default is 'png'. |
| 273 | optimize_graph : bool, optional |
| 274 | If True, the graph is optimized before rendering. Otherwise, |
| 275 | the graph is displayed as is. Default is False. |
| 276 | color: {None, 'order'}, optional |
| 277 | Options to color nodes. Provide ``cmap=`` keyword for additional |
| 278 | colormap |
| 279 | **kwargs |
| 280 | Additional keyword arguments to forward to ``to_graphviz``. |
| 281 | |
| 282 | Examples |
| 283 | -------- |
| 284 | >>> x.visualize(filename='dask.pdf') # doctest: +SKIP |
| 285 | >>> x.visualize(filename='dask.pdf', color='order') # doctest: +SKIP |
| 286 | |
| 287 | Returns |
| 288 | ------- |
| 289 | result : IPython.display.Image, IPython.display.SVG, or None |
| 290 | See dask.dot.dot_graph for more information. |
| 291 | |
| 292 | See Also |
| 293 | -------- |
| 294 | dask.visualize |
| 295 | dask.dot.dot_graph |
| 296 | |
| 297 | Notes |
| 298 | ----- |
| 299 | For more information on optimization see here: |
| 300 | |
| 301 | https://docs.dask.org/en/latest/optimize.html |
| 302 | """ |
| 303 | return visualize( |
| 304 | self, |
| 305 | filename=filename, |
| 306 | format=format, |
| 307 | optimize_graph=optimize_graph, |
| 308 | **kwargs, |
| 309 | ) |
| 310 | |
| 311 | def persist(self, **kwargs): |
| 312 | """Persist this dask collection into memory |
nothing calls this directly
no test coverage detected