code: def apply_stripe_group_permutation(
      sgp, stripes, group_width, permutation
  ):
      new_permutation = permutation.copy()
      for subset_idx in range(len(sgp)):
          dst_stripe_idx = stripes[int(subset_idx / group_width)]
          dst_col_idx = subset_idx % group_width
  
          subset_val = sgp[subset_idx]
          src_stripe_idx = stripes[int(subset_val / group_width)]
          src_col_idx = subset_val % group_width
  
          new_permutation[
              dst_stripe_idx * group_width + dst_col_idx
          ] = permutation[src_stripe_idx * group_width + src_col_idx]
  
      return new_permutation
  
file_path: apex/apex/contrib/sparsity/permutation_search_kernels/exhaustive_search.py
imports: from .permutation_utilities import *
  import pickle
  import os.path
  from os import path
  import math
label_desc: Use image node_id 7 for calling a global function with example usage: apply_stripe_group_permutation(sgp, stripes, group_width, permutation) and returns: new_permutation