当前位置: 首页>>代码示例>>Python>>正文


Python download_and_convert_cifar10.run方法代码示例

本文整理汇总了Python中datasets.download_and_convert_cifar10.run方法的典型用法代码示例。如果您正苦于以下问题:Python download_and_convert_cifar10.run方法的具体用法?Python download_and_convert_cifar10.run怎么用?Python download_and_convert_cifar10.run使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在datasets.download_and_convert_cifar10的用法示例。


在下文中一共展示了download_and_convert_cifar10.run方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'cifar10':
    download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'wikiart':
    if not FLAGS.input_dataset_dir is None:
      convert_wikiart.run(FLAGS.input_dataset_dir, FLAGS.dataset_dir)

    else:
      raise ValueError("For wikiart, you must supply a valid input directory with --input_dataset_dir")
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_name) 
开发者ID:mlberkeley,项目名称:Creative-Adversarial-Networks,代码行数:23,代码来源:download_and_convert_data.py

示例2: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'cifar10':
    if FLAGS.shard:
      download_convert_and_shard_cifar10.run(FLAGS.dataset_dir)
    else:
      download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_dir) 
开发者ID:wenwei202,项目名称:terngrad,代码行数:20,代码来源:download_and_convert_data.py

示例3: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'cifar10':
    download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'fer':
    download_and_convert_fer.run(FLAGS.dataset_dir,FLAGS.pic_path)
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_name) 
开发者ID:ucloud,项目名称:uai-sdk,代码行数:19,代码来源:download_and_convert_data.py

示例4: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'cifar10':
    download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'diabetic':
      download_and_convert_diabetic.run(FLAGS.dataset_dir)
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_name) 
开发者ID:PacktPublishing,项目名称:Machine-Learning-with-TensorFlow-1.x,代码行数:19,代码来源:download_and_convert_data.py

示例5: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'customized':
    convert_customized.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'cifar10':
    download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_name) 
开发者ID:yeephycho,项目名称:nasnet-tensorflow,代码行数:19,代码来源:convert_customized_data.py

示例6: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'cifar10':
    download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'visualwakewords':
    download_and_convert_visualwakewords.run(
        FLAGS.dataset_dir, FLAGS.small_object_area_threshold,
        FLAGS.foreground_class_of_interest)
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_name) 
开发者ID:tensorflow,项目名称:models,代码行数:21,代码来源:download_and_convert_data.py

示例7: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'cifar10':
    download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_name) 
开发者ID:ringringyi,项目名称:DOTA_models,代码行数:17,代码来源:download_and_convert_data.py

示例8: main

# 需要导入模块: from datasets import download_and_convert_cifar10 [as 别名]
# 或者: from datasets.download_and_convert_cifar10 import run [as 别名]
def main(_):
  if not FLAGS.dataset_name:
    raise ValueError('You must supply the dataset name with --dataset_name')
  if not FLAGS.dataset_dir:
    raise ValueError('You must supply the dataset directory with --dataset_dir')

  if FLAGS.dataset_name == 'cifar10':
    download_and_convert_cifar10.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'flowers':
    download_and_convert_flowers.run(FLAGS.dataset_dir)
  elif FLAGS.dataset_name == 'mnist':
    download_and_convert_mnist.run(FLAGS.dataset_dir)
  else:
    raise ValueError(
        'dataset_name [%s] was not recognized.' % FLAGS.dataset_dir) 
开发者ID:logicalclocks,项目名称:hops-tensorflow,代码行数:17,代码来源:download_and_convert_data.py


注:本文中的datasets.download_and_convert_cifar10.run方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。