class_docstr: `Flickr30k Entities <https://bryanplummer.com/Flickr30kEntities/>`_ Dataset.
  
  Args:
      root (string): Root directory where images are downloaded to.
      ann_file (string): Path to annotation file.
      transform (callable, optional): A function/transform that takes in a PIL image
          and returns a transformed version. E.g, ``transforms.PILToTensor``
      target_transform (callable, optional): A function/transform that takes in the
          target and transforms it.
docstr: Args:
      index (int): Index
  
  Returns:
      tuple: Tuple (image, target). target is a list of captions for the image.
docstr_tok: ["Args",":","index","(","int",")",":","Index","Returns",":","tuple",":","Tuple","(","image",",","target",")",".","target","is","a","list","of","captions","for","the","image","."]
code: def __getitem__(self, index: int) -> Tuple[Any, Any]:
      """
      Args:
          index (int): Index
  
      Returns:
          tuple: Tuple (image, target). target is a list of captions for the image.
      """
      img_id = self.ids[index]
  
      # Image
      filename = os.path.join(self.root, img_id)
      img = Image.open(filename).convert("RGB")
      if self.transform is not None:
          img = self.transform(img)
  
      # Captions
      target = self.annotations[img_id]
      if self.target_transform is not None:
          target = self.target_transform(target)
  
      return img, target
  
imports: import glob
  import os
  from collections import defaultdict
  from html.parser import HTMLParser
  from typing import Any, Callable, Dict, List, Optional, Tuple
  from PIL import Image
  from .vision import VisionDataset
label_desc: Use image node_id 2 for calling the Flickr30k obj's underlying member method code with example usage: obj.__getitem__(index) and returns: img,  target