class_docstr: Immutable, internal container for a fixed size stack.
  
  The implementation is backed by a `Tensor` each for the stack and the
  (batched) stack pointer.
  
  As a namedtuple, it can be directly passed through TF's nest library for
  flattening and restructuring as an element passed to e.g. a TF while loop.
docstr: Put in runtime asserts of stack bounds? Overridden by UnsafeStack.
docstr_tok: ["Put","in","runtime","asserts","of","stack","bounds","?","Overridden","by","UnsafeStack","."]
code: def _safety_checks(self):
      """Put in runtime asserts of stack bounds? Overridden by UnsafeStack."""
      return True
  
imports: import collections
  import contextlib
  import six
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_probability.python.experimental.auto_batching import instructions
  from tensorflow_probability.python.experimental.auto_batching import xla
  from tensorflow_probability.python.internal import dtype_util
  from tensorflow.python.ops import control_flow_util
label_desc: Use image node_id 1 for calling the Stack obj's underlying member method code with example usage: obj._safety_checks() and returns: True