class_docstr: The list-like object that contains every :class:`SingleImage`
  in the :class:`~wand.image.Image` container.  It implements
  :class:`collections.abc.Sequence` protocol.
  
  .. versionadded:: 0.3.0
class_docstr_tok: ["The","list-like","object","that","contains","every",":","class",":","`","SingleImage","`","in","the",":","class",":","`","~wand.image.Image","`","container",".","It","implements",":","class",":","`","collections.abc.Sequence","`","protocol",".","..","versionadded",":",":","0.3.0"]
code: def __getitem__(self, index):
      if isinstance(index, slice):
          slice_ = self.validate_slice(index)
          return [self[i] for i in xrange(slice_.start, slice_.stop)]
      index = self.validate_position(index)
      instances = self.instances
      instances_length = len(instances)
      if index < instances_length:
          instance = instances[index]
          if (
              instance is not None
              and getattr(instance, "c_resource", None) is not None
          ):
              return instance
      else:
          number_to_extend = index - instances_length + 1
          instances.extend(None for _ in xrange(number_to_extend))
      wand = self.image.wand
      tmp_idx = library.MagickGetIteratorIndex(wand)
      library.MagickSetIteratorIndex(wand, index)
      image = library.GetImageFromMagickWand(wand)
      exc = libmagick.AcquireExceptionInfo()
      single_image = libmagick.CloneImages(
          image, binary(str(index)), exc
      )
      libmagick.DestroyExceptionInfo(exc)
      single_wand = library.NewMagickWandFromImage(single_image)
      single_image = libmagick.DestroyImage(single_image)
      library.MagickSetIteratorIndex(wand, tmp_idx)
      instance = SingleImage(single_wand, self.image, image)
      self.instances[index] = instance
      return instance
  
imports: import contextlib
  import ctypes
  import numbers
  from .api import libmagick, library
  from .compat import abc, binary, xrange
  from .image import BaseImage, ImageProperty
  from .version import MAGICK_VERSION_INFO
label_desc: Use image node_id 8 for calling the Sequence obj's underlying member method code with example usage: obj.__getitem__(index) and returns: instance, unknown, instance