class_docstr: An OrderedSet is a custom MutableSet that remembers its order, so that
  every entry has an index that can be looked up.
  
  Example:
      >>> OrderedSet([1, 1, 2, 3, 2])
      OrderedSet([1, 2, 3])
class_docstr_tok: ["An","OrderedSet","is","a","custom","MutableSet","that","remembers","its","order",",","so","that","every","entry","has","an","index","that","can","be","looked","up",".","Example",":",">",">",">","OrderedSet","(","[","1",",","1",",","2",",","3",",","2","]",")","OrderedSet","(","[","1",",","2",",","3","]",")"]
docstr: Get the index of a given entry, raising an IndexError if it's not
  present.
  
  `key` can be an iterable of entries that is not a string, in which case
  this returns a list of indices.
  
  Example:
      >>> oset = OrderedSet([1, 2, 3])
      >>> oset.index(2)
      1
docstr_tok: ["Get","the","index","of","a","given","entry",",","raising","an","IndexError","if","it","'s","not","present",".","`","key","`","can","be","an","iterable","of","entries","that","is","not","a","string",",","in","which","case","this","returns","a","list","of","indices",".","Example",":",">",">",">","oset","=","OrderedSet","(","[","1",",","2",",","3","]",")",">",">",">","oset.index","(","2",")","1"]
code: def index(self, key):
      """
      Get the index of a given entry, raising an IndexError if it's not
      present.
  
      `key` can be an iterable of entries that is not a string, in which case
      this returns a list of indices.
  
      Example:
          >>> oset = OrderedSet([1, 2, 3])
          >>> oset.index(2)
          1
      """
      if is_iterable(key):
          return [self.index(subkey) for subkey in key]
      return self.map[key]
  
imports: import itertools
  from collections import deque
label_desc: Use image node_id 10 for calling the OrderedSet obj's underlying member method code with example usage: obj.index(key) and returns: self, unknown