def deriveRefinedCollisionData(model):
    """This function collects all collision bitmasks in a given model.

    Args:
      model(dict): The robot model to search in.

    Returns:
      : dict -- a dictionary containing all bitmasks with corresponding element name (key).

    """
    collisiondata = {}
    for linkname in model['links']:
        for elementname in model['links'][linkname]['collision']:
            element = model['links'][linkname]['collision'][elementname]
            data = {
                key: element[key]
                for key in (a for a in element.keys() if a not in ['geometry', 'name', 'pose'])
            }
            if data:
                data['name'] = model['links'][linkname]['collision'][elementname]['name']
                data['link'] = linkname
                collisiondata[elementname] = data
    return collisiondata