code: def ensemble_center(self, site_list, indices, cartesian=True):
          
          if cartesian:
              return np.average([site_list[i].coords for i in indices],
                                axis=0)
          else:
              return np.average([site_list[i].frac_coords for i in indices],
                                axis=0)
docs: Finds the center of an ensemble of sites selected from
          a list of sites.  Helper method for the find_adsorption_sites
          algorithm.
  
          Args:
              site_list (list of sites): list of sites
              indices (list of ints): list of ints from which to select
                  sites from site list
              cartesian (bool): whether to get average fractional or
                  cartesian coordinate