class_docstr: Semantic segmentation dataset for `ADE20K`_.
  
  This is ADE20K dataset distributed in MIT Scene Parsing Benchmark website.
  It has 20,210 training images and 2,000 validation images.
  
  .. _`MIT Scene Parsing Benchmark`: http://sceneparsing.csail.mit.edu/
  
  Args:
      data_dir (string): Path to the dataset directory. The directory should
          contain the :obj:`ADEChallengeData2016` directory. And that
          directory should contain at least :obj:`images` and
          :obj:`annotations` directries. If :obj:`auto` is given, the dataset
          is automatically downloaded into
          :obj:`$CHAINER_DATASET_ROOT/pfnet/chainercv/ade20k`.
      split ({'train', 'val'}): Select from dataset splits used in
          MIT Scene Parsing Benchmark dataset (ADE20K).
  
  This dataset returns the following data.
  
  .. csv-table::
      :header: name, shape, dtype, format
  
      :obj:`img`, ":math:`(3, H, W)`", :obj:`float32`,         "RGB, :math:`[0, 255]`"
      :obj:`label`, ":math:`(H, W)`", :obj:`int32`,         ":math:`[-1, \#class - 1]`"
class_docstr_tok: ["Semantic","segmentation","dataset","for","`","ADE20K","`","_",".","This","is","ADE20K","dataset","distributed","in","MIT","Scene","Parsing","Benchmark","website",".","It","has","20,210","training","images","and","2,000","validation","images",".","..","_","`","MIT","Scene","Parsing","Benchmark","`",":","http",":","\/\/sceneparsing.csail.mit.edu\/","Args",":","data_dir","(","string",")",":","Path","to","the","dataset","directory",".","The","directory","should","contain","the",":","obj",":","`","ADEChallengeData2016","`","directory",".","And","that","directory","should","contain","at","least",":","obj",":","`","images","`","and",":","obj",":","`","annotations","`","directries",".","If",":","obj",":","`","auto","`","is","given",",","the","dataset","is","automatically","downloaded","into",":","obj",":","`","$","CHAINER_DATASET_ROOT\/pfnet\/chainercv\/ade20k","`",".","split","(","{","'train","'",",","'val","'","}",")",":","Select","from","dataset","splits","used","in","MIT","Scene","Parsing","Benchmark","dataset","(","ADE20K",")",".","This","dataset","returns","the","following","data",".","..","csv-table",":",":",":","header",":","name",",","shape",",","dtype",",","format",":","obj",":","`","img","`",",","``",":","math",":","`","(","3",",","H",",","W",")","`","``",",",":","obj",":","`","float32","`",",","``","RGB",",",":","math",":","`","[","0",",","255","]","`","``",":","obj",":","`","label","`",",","``",":","math",":","`","(","H",",","W",")","`","``",",",":","obj",":","`","int32","`",",","``",":","math",":","`","[","-1",",","\\","#","class","-","1","]","`","``"]
code: def _get_label(self, i):
      label = read_label(self.label_paths[i], dtype=np.int32)
      # [-1, n_class - 1]
      return label - 1
  
file_path: chainercv/chainercv/datasets/ade20k/ade20k_semantic_segmentation_dataset.py
imports: import glob
  import os
  import numpy
  from chainercv.chainer_experimental.datasets.sliceable import GetterDataset
  from chainercv.datasets.ade20k.ade20k_utils import get_ade20k
  from chainercv.utils import read_image
  from chainercv.utils import read_label
label_desc: Use image node_id 4 for calling the ADE20KSemanticSegmentationDataset obj's underlying member method code with example usage: obj._get_label(i) and returns: unknown