muspan.query.

get_collections#

get_collections(domain)#

Retrieve collections and their corresponding object indices from a domain. This function flattens the collection structure if an object is in more than one collection.

Parameters:
domainobject

An object that contains a dictionary of objects, where each object has an attribute in_collections.

Returns:
tuple of numpy.ndarray

A tuple containing two flattened numpy arrays: - The first array contains the collections. - The second array contains the corresponding object indices.