pymaid.get_connectors_in_bbox¶
- pymaid.get_connectors_in_bbox(bbox, unit='NM', limit=None, restrict_to=False, ret='COORDS', remote_instance=None, **kwargs)[source]¶
Retrieves connectors within given bounding box.
- Parameters:
bbox (list-like | dict | pymaid.Volume) –
Coordinates of the bounding box. Can be either:
List/np.array:
[[left, right], [top, bottom], [z1, z2]]
Dictionary
{'left': int|float, 'right': ..., ...}
unit ('NM' | 'PIXEL') – Unit of your coordinates. Attention: ‘PIXEL’ will also assume that Z1/Z2 is in slices. By default, a X/Y resolution of 3.8nm and a Z resolution of 35nm is assumed. Pass ‘xy_res’ and ‘z_res’ as
**kwargs
to override this.limit (int, optional) – Limit the number of connectors returned.
restrict_to (list, optional) – List of skeleton IDs to return connectors for.
ret (‘IDS’ |’COORDS’ | ‘LINKS’) – Connector data to be returned. See below for explanation.
remote_instance (CatmaidInstance) – If not passed directly, will try using global.
- Returns:
pandas.DataFrame – If
ret="COORDS"
(default): DataFrame in which each row represents a connector:connector_id x y z
0 1 ..
list – If
ret="IDS"
: list of connector IDs.pandas.DataFrame – If
ret="LINKS"
: DataFrame in which each row represents a connector. Please note that connectors can show up multiple times - once for each link.connector_id x y z skeleton confidence creator_id ..
0 1 ..
0 1 ..