class_docstr: Base class for custom Dataset which follows protocol/formatting of the well-known VOC object detection dataset.
  
  Parameters
  ----------
  class: tuple of classes, default = None
      We reuse the neural network weights if the corresponding class appears in the pretrained model.
      Otherwise, we randomly initialize the neural network weights for new classes.
  root : str, default '~/mxnet/datasets/voc'
      Path to folder storing the dataset.
  splits : list of tuples, default ((2007, 'trainval'), (2012, 'trainval'))
      List of combinations of (year, name)
      For years, candidates can be: 2007, 2012.
      For names, candidates can be: 'train', 'val', 'trainval', 'test'.
  transform : callable, default = None
      A function that takes data and label and transforms them. Refer to
      :doc:`./transforms` for examples.
      A transform function for object detection should take label into consideration,
      because any geometric modification will require label to be modified.
  index_map : dict, default = None
      By default, the 20 classes are mapped into indices from 0 to 19. We can
      customize it by providing a str to int dict specifying how to map class
      names to indices. This is only for advanced users, when you want to swap the orders
      of class labels.
  preload_label : bool, default = True
      If True, then parse and load all labels into memory during
      initialization. It often accelerate speed but require more memory
      usage. Typical preloaded labels took tens of MB. You only need to disable it
      when your dataset is extremely large.
class_docstr_tok: ["Base","class","for","custom","Dataset","which","follows","protocol\/formatting","of","the","well-known","VOC","object","detection","dataset",".","Parameters","--","--","--","--","--","class",":","tuple","of","classes",",","default","=","None","We","reuse","the","neural","network","weights","if","the","corresponding","class","appears","in","the","pretrained","model",".","Otherwise",",","we","randomly","initialize","the","neural","network","weights","for","new","classes",".","root",":","str",",","default","'~\/mxnet\/datasets\/voc'","Path","to","folder","storing","the","dataset",".","splits",":","list","of","tuples",",","default","(","(","2007",",","'trainval","'",")",",","(","2012",",","'trainval","'",")",")","List","of","combinations","of","(","year",",","name",")","For","years",",","candidates","can","be",":","2007",",","2012",".","For","names",",","candidates","can","be",":","'train","'",",","'val","'",",","'trainval","'",",","'test","'",".","transform",":","callable",",","default","=","None","A","function","that","takes","data","and","label","and","transforms","them",".","Refer","to",":","doc",":","`",".\/transforms","`","for","examples",".","A","transform","function","for","object","detection","should","take","label","into","consideration",",","because","any","geometric","modification","will","require","label","to","be","modified",".","index_map",":","dict",",","default","=","None","By","default",",","the","20","classes","are","mapped","into","indices","from","0","to","19",".","We","can","customize","it","by","providing","a","str","to","int","dict","specifying","how","to","map","class","names","to","indices",".","This","is","only","for","advanced","users",",","when","you","want","to","swap","the","orders","of","class","labels",".","preload_label",":","bool",",","default","=","True","If","True",",","then","parse","and","load","all","labels","into","memory","during","initialization",".","It","often","accelerate","speed","but","require","more","memory","usage",".","Typical","preloaded","labels","took","tens","of","MB",".","You","only","need","to","disable","it","when","your","dataset","is","extremely","large","."]
code: def __init__(
      self,
      classes=None,
      root=os.path.join("~", ".mxnet", "datasets", "voc"),
      splits=((2007, "trainval"), (2012, "trainval")),
      transform=None,
      index_map=None,
      preload_label=True,
  ):
      # update classes
      if classes:
          self._set_class(classes)
      super(CustomVOCDetectionBase, self).__init__(
          root=root,
          splits=splits,
          transform=transform,
          index_map=index_map,
          preload_label=False,
      )
      self._items_new = [
          self._items[each_id]
          for each_id in range(len(self._items))
          if self._check_valid(each_id)
      ]
      self._items = self._items_new
      self._label_cache = (
          self._preload_labels() if preload_label else None
      )
  
imports: from __future__ import absolute_import
  from __future__ import division
  import glob
  import logging
  import os
  import warnings
  import numpy
  import mxnet
  from ..base import VisionDataset
label_desc: Use image node_id 1 to create a new CustomVOCDetectionBase object from inherited base classes: VOCDetection with example: obj = CustomVOCDetectionBase(classes, root, splits, transform, index_map, preload_label)