code: def _check_group_assignment(group_assignment, n_subjects):
      if type(group_assignment) == list:
          pass
      elif type(group_assignment) == np.ndarray:
          group_assignment = group_assignment.tolist()
      else:
          logger.info(
              "No group assignment provided, "
              "performing one-sample test."
          )
  
      if group_assignment and len(group_assignment) != n_subjects:
          raise ValueError(
              "Group assignments ({0}) "
              "do not match number of subjects ({1})!".format(
                  len(group_assignment), n_subjects
              )
          )
      return group_assignment
  
imports: import numpy
  import logging
  from scipy.spatial.distance import squareform
  from itertools import combinations, permutations, product
  from brainiak.fcma.util import compute_correlation
  from brainiak.utils.utils import array_correlation, phase_randomize, p_from_null, _check_timeseries_input
label_desc: Use image node_id 9 for calling a global function with example usage: _check_group_assignment(group_assignment, n_subjects) and returns: group_assignment