code: def _augment_hms_and_segmaps_by_samples(
      self, augmentables, samples, arr_attr_name
  ):
      if self.keep_size:
          return augmentables
  
      kernel_sizes_h, kernel_sizes_w = samples
  
      gen = enumerate(zip(augmentables, kernel_sizes_h, kernel_sizes_w))
      for i, (augmentable, ksize_h, ksize_w) in gen:
          if ksize_h >= 2 or ksize_w >= 2:
              # We could also keep the size of the HM/SM array unchanged
              # here as the library can handle HMs/SMs that are larger
              # than the image. This might be inintuitive however and
              # could lead to unnecessary performance degredation.
              if self._resize_hm_and_sm_arrays:
                  new_shape_arr = _compute_shape_after_pooling(
                      getattr(augmentable, arr_attr_name).shape,
                      ksize_h,
                      ksize_w,
                  )
                  augmentable = augmentable.resize(new_shape_arr[0:2])
  
              new_shape = _compute_shape_after_pooling(
                  augmentable.shape, ksize_h, ksize_w
              )
              augmentable.shape = new_shape
  
              augmentables[i] = augmentable
  
      return augmentables
  
imports: from __future__ import print_function, division, absolute_import
  from abc import ABCMeta, abstractmethod
  import functools
  import six
  import numpy
  import imgaug
  from .None import meta
  from ..None import parameters
label_desc: Use image node_id 8 for calling the _AbstractPoolingBase obj's underlying member method code with example usage: obj._augment_hms_and_segmaps_by_samples(augmentables, samples, arr_attr_name) and returns: augmentables, augmentables