class_docstr: Wraps Gensim's `models.keyedvectors` module
  (https://radimrehurek.com/gensim/models/keyedvectors.html)
class_docstr_tok: ["Wraps","Gensim","'s","`","models.keyedvectors","`","module","(","https",":","\/\/radimrehurek.com\/gensim\/models\/keyedvectors.html",")"]
docstr: Gets the embedding vector for word/id
  Args:
      index (Union[str|int]): `index` can either be word or integer representing the id of the word.
  Returns:
      vector (ndarray): 1-D embedding vector. If corresponding vector cannot be found for `index`, returns `None`.
docstr_tok: ["Gets","the","embedding","vector","for","word\/id","Args",":","index","(","Union","[","str|int","]",")",":","`","index","`","can","either","be","word","or","integer","representing","the","id","of","the","word",".","Returns",":","vector","(","ndarray",")",":","1-D","embedding","vector",".","If","corresponding","vector","can","not","be","found","for","`","index","`",",","returns","`","None","`","."]
code: def __getitem__(self, index):
      """Gets the embedding vector for word/id
      Args:
          index (Union[str|int]): `index` can either be word or integer representing the id of the word.
      Returns:
          vector (ndarray): 1-D embedding vector. If corresponding vector cannot be found for `index`, returns `None`.
      """
      if isinstance(index, str):
          try:
              index = self.keyed_vectors.key_to_index.get(index)
          except KeyError:
              return None
      try:
          return self.keyed_vectors.get_normed_vectors()[index]
      except IndexError:
          # word embedding ID out of bounds
          return None
  
imports: from abc import ABC, abstractmethod
  from collections import defaultdict
  import os
  import pickle
  import numpy
  import torch
  from textattack.shared import utils
label_desc: Use image node_id 2 for calling the GensimWordEmbedding obj's underlying member method code with example usage: obj.__getitem__(index) and returns: self, None, None