class_docstr: A random shuffling buffer implementation. Items can be added to the buffer and retrieved in a random order.
code: def add_many(self, items):
      if self._done_adding:
          raise RuntimeError(
              "Can not call add_many after done_adding() was called."
          )
  
      if not self.can_add():
          raise RuntimeError(
              'Can not enqueue. Check the return value of "can_enqueue()" to check if more '
              "items can be added."
          )
  
      # We leave self._extra_capacity slack to make sure we don't reallocate self._items array
      expected_size = self._size + len(items)
      maximal_capacity = (
          self._shuffling_queue_capacity + self._extra_capacity
      )
      if expected_size > maximal_capacity:
          raise RuntimeError(
              "Attempt to enqueue more elements than the capacity allows. "
              "Current size: {}, new size {}, maximum allowed: {}".format(
                  self._size, expected_size, maximal_capacity
              )
          )
      self._items[self._size : self._size + len(items)] = items
      self._size = expected_size
  
imports: import abc
  from collections import deque
  import numpy
  import six
label_desc: Use image node_id 2 for calling the RandomShufflingBuffer obj's underlying member method code with example usage: obj.add_many(items) without return types