qcodes/dataset/data_export.py
def _all_in_group_or_subgroup(rows: np.ndarray) -> bool:
    """
    Detects whether the setpoints correspond to two groups of
    of identical rows, one being contained in the other.

    This is the test for whether the setpoints correspond to a
    rectangular sweep. It allows for a single rectangular hole
    in the setpoint grid, thus allowing for an interrupted sweep.
    Note that each axis needs NOT be equidistantly spaced.

    Args:
        rows: The output from _rows_from_datapoints

    Returns:
        A boolean indicating whether the setpoints meet the
            criterion
    """

    groups = 1
    comp_to = rows[0]

    aigos = True
    switchindex = 0

    for rowind, row in enumerate(rows[1:]):
        if np.array_equal(row, comp_to):
            continue
        else:
            groups += 1
            comp_to = row
            switchindex = rowind
            if groups > 2:
                aigos = False
                break

    # if there are two groups, check that the rows of one group
    # are all contained in the rows of the other
    if aigos and switchindex > 0:
        for row in rows[1+switchindex:]:
            if sum(r in rows[0] for r in row) != len(row):
                aigos = False
                break

    return aigos

    Detects whether the setpoints correspond to two groups of
    of identical rows, one being contained in the other.

    This is the test for whether the setpoints correspond to a
    rectangular sweep. It allows for a single rectangular hole
    in the setpoint grid, thus allowing for an interrupted sweep.
    Note that each axis needs NOT be equidistantly spaced.

    Args:
        rows: The output from _rows_from_datapoints

    Returns:
        A boolean indicating whether the setpoints meet the
            criterion
    
Detects whether the setpoints correspond to two groups of
of identical rows, one being contained in the other.

This is the test for whether the setpoints correspond to a
rectangular sweep. It allows for a single rectangular hole
in the setpoint grid, thus allowing for an interrupted sweep.
Note that each axis needs NOT be equidistantly spaced.
Detects whether the setpoints correspond to two groups of of identical rows one being contained in the other . This is the test for whether the setpoints correspond to a rectangular sweep . It allows for a single rectangular hole in the setpoint grid thus allowing for an interrupted sweep . Note that each axis needs NOT be equidistantly spaced .
def _all_in_group_or_subgroup(rows: np.ndarray) -> bool:
    groups = 1
    comp_to = rows[0]
    aigos = True
    switchindex = 0
    for rowind, row in enumerate(rows[1:]):
        if np.array_equal(row, comp_to):
            continue
        else:
            groups += 1
            comp_to = row
            switchindex = rowind
            if groups > 2:
                aigos = False
                break
    if aigos and switchindex > 0:
        for row in rows[1+switchindex:]:
            if sum(r in rows[0] for r in row) != len(row):
                aigos = False
                break
    return aigos
def _all_in_group_or_subgroup ( rows : np . ndarray ) -> bool : groups = 1 comp_to = rows [ 0 ] aigos = True switchindex = 0 for rowind , row in enumerate ( rows [ 1 : ] ) : if np . array_equal ( row , comp_to ) : continue else : groups += 1 comp_to = row switchindex = rowind if groups > 2 : aigos = False break if aigos and switchindex > 0 : for row in rows [ 1 + switchindex : ] : if sum ( r in rows [ 0 ] for r in row ) != len ( row ) : aigos = False break return aigos
Detects whether the setpoints correspond to two groups of
of identical rows, one being contained in the other.
Detects whether the setpoints correspond to two groups of of identical rows one being contained in the other .
"""
    Detects whether the setpoints correspond to two groups of
    of identical rows, one being contained in the other.

    This is the test for whether the setpoints correspond to a
    rectangular sweep. It allows for a single rectangular hole
    in the setpoint grid, thus allowing for an interrupted sweep.
    Note that each axis needs NOT be equidistantly spaced.

    Args:
        rows: The output from _rows_from_datapoints

    Returns:
        A boolean indicating whether the setpoints meet the
            criterion
    """ # if there are two groups, check that the rows of one group # are all contained in the rows of the other
A boolean indicating whether the setpoints meet the
criterion
A boolean indicating whether the setpoints meet the criterion
rows
np.ndarray
The output from _rows_from_datapoints
The output from _rows_from_datapoints