Get all intersections of the bounding boxes of strokes.

    Parameters
    ----------
    recording : list of lists of integers

    Returns
    -------
    A symmetrical matrix which indicates if two bounding boxes intersect.

def get_bb_intersections(recording):
    """
    Get all intersections of the bounding boxes of strokes.

    Parameters
    ----------
    recording : list of lists of integers

    Returns
    -------
    A symmetrical matrix which indicates if two bounding boxes intersect.
    """
    intersections = numpy.zeros((len(recording), len(recording)),
                                dtype=bool)
    for i in range(len(recording)-1):
        a = geometry.get_bounding_box(recording[i]).grow(0.2)
        for j in range(i+1, len(recording)):
            b = geometry.get_bounding_box(recording[j]).grow(0.2)
            intersections[i][j] = geometry.do_bb_intersect(a, b)
            intersections[j][i] = intersections[i][j]
    return intersections