tiled.client.from_tree

tiled.client.from_tree(tree, *, authentication=None, server_settings=None, query_registry=None, serialization_registry=None, compression_registry=None, structure_clients='numpy', cache=None, offline=False, username=None, token_cache='/home/runner/.config/tiled/tokens', headers=None)[source]

Connect to a Node directly, running the app in this same process.

NOTE: This is experimental. It may need to be re-designed or even removed.

In this configuration, we are using the server, but we are communicating with it directly within this process, not over a local network. It is generally faster.

Specifically, we are using HTTP over ASGI rather than HTTP over TCP. There are no sockets or network-related syscalls.

Parameters
treeNode
authenticationdict, optional

Dict of authentication configuration.

usernamestr, optional

Username for authenticated access.

structure_clientsstr or dict, optional

Use “dask” for delayed data loading and “numpy” for immediate in-memory structures (e.g. normal numpy arrays, pandas DataFrames). For advanced use, provide dict mapping a structure_family or a spec to a client object.

cacheCache, optional
offlinebool, optional

False by default. If True, rely on cache only.

token_cachestr, optional

Path to directory for storing refresh tokens.

prompt_for_reauthentication{“at_init”, “always”, “never”}