Exemple #1
0
for year in ['2007', '2012']:
    for split in ['train', 'val', 'trainval', 'test']:
        name = 'voc_cycleclipart_{}_{}'.format(year, split)
        __sets[name] = (lambda split=split, year=year: pascal_voc_cycleclipart(
            split, year))
for year in ['2007', '2012']:
    for split in ['train', 'val', 'trainval', 'test']:
        name = 'voc_cyclewater_{}_{}'.format(year, split)
        __sets[name] = (
            lambda split=split, year=year: pascal_voc_cyclewater(split, year))
for year in ['2007']:
    for split in ['trainval', 'test']:
        name = 'clipart_{}'.format(split)
        __sets[name] = (lambda split=split: clipart(split, year))
for year in ['2007']:
    for split in ['train', 'test']:
        name = 'water_{}'.format(split)
        __sets[name] = (lambda split=split: water(split, year))


def get_imdb(name):
    """Get an imdb (image database) by name."""
    if name not in __sets:
        raise KeyError('Unknown dataset: {}'.format(name))
    return __sets[name]()


def list_imdbs():
    """List all registered imdbs."""
    return list(__sets.keys())
Exemple #2
0
      __sets[name] = (lambda split=split, year=year: pascal_voc_cyclewater(split, year))
for split in ['train', 'trainval', 'test']:
  for data_percentage in ['', '_1_00', '_1_01', '_1_02']:
    dataset_name = 'clipart{}'.format(data_percentage)
    name = '{}_{}'.format(dataset_name, split)
    __sets[name] = (lambda split=split, dataset_name=dataset_name: clipart(split,devkit_path=os.path.join('datasets', dataset_name)))
for split in ['train', 'test']:
  for data_percentage in ['', '_1_00', '_1_01', '_1_02']:
    dataset_name = 'comic{}'.format(data_percentage)
    name = '{}_{}'.format(dataset_name, split)
    __sets[name] = (lambda split=split, dataset_name=dataset_name: comic(split,devkit_path=os.path.join('datasets', dataset_name)))
for split in ['train', 'test']:
  for data_percentage in ['', '_1_00', '_1_01', '_1_02']:
    dataset_name = 'watercolor{}'.format(data_percentage)
    name = '{}_{}'.format(dataset_name, split)
    __sets[name] = (lambda split=split, dataset_name=dataset_name: water(split,devkit_path=os.path.join('datasets', dataset_name)))
for split in ['train', 'test']:
  dataset_name = 'amds'
  name = '{}_{}'.format(dataset_name, split)
  __sets[name] = (lambda split=split, dataset_name=dataset_name: amds(split,devkit_path=os.path.join('datasets', dataset_name)))
def get_imdb(name):
  """Get an imdb (image database) by name."""
  if name not in __sets:
    raise KeyError('Unknown dataset: {}'.format(name))
  return __sets[name]()


def list_imdbs():
  """List all registered imdbs."""
  return list(__sets.keys())