def calculate_group_statistics(outcomes, num_groups=5):
    """
    Calculate group-wise means and the standard deviation between groups.

    Splits outcomes into groups and calculates statistics to estimate variance.

    Args:
        outcomes (list): Binary outcomes (0 or 1) for each puzzle
        num_groups (int): Number of groups to split the data into

    Returns:
        tuple: (group_means, group_std) where group_means is a list of percentages
               and group_std is the standard deviation between groups
    """
    if not outcomes:
        return [], 0.0

    # Convert to numpy array for easier manipulation
    outcomes = np.array(outcomes)

    # Calculate number of items per group
    group_size = len(outcomes) // num_groups

    # Split into groups and calculate mean for each group
    group_means = []
    for i in range(num_groups):
        start_idx = i * group_size
        end_idx = start_idx + group_size if i < num_groups - 1 else len(outcomes)
        group = outcomes[start_idx:end_idx]
        group_means.append(np.mean(group) * 100)  # Convert to percentage

    # Calculate standard deviation between group means
    group_std = np.std(group_means)

    return group_means, group_std

    Calculate group-wise means and the standard deviation between groups.

    Splits outcomes into groups and calculates statistics to estimate variance.

    Args:
        outcomes (list): Binary outcomes (0 or 1) for each puzzle
        num_groups (int): Number of groups to split the data into

    Returns:
        tuple: (group_means, group_std) where group_means is a list of percentages
               and group_std is the standard deviation between groups
    
vlmeval/dataset/utils/vgrpbench/score.py