[Tensorflow][Train] Oxford-IIIT Pets 数据集训练

一 获取数据集

 

wget http://www.robots.ox.ac.uk/~vgg/data/pets/data/images.tar.gz
wget http://www.robots.ox.ac.uk/~vgg/data/pets/data/annotations.tar.gz
tar -xvf images.tar.gz
tar -xvf annotations.tar.gz

 

下载完成后,是这样的目录结构

 

tensorflow/models/research/ directory should appear as follows:

- images.tar.gz
- annotations.tar.gz
+ images/
+ annotations/
+ object_detection/
... other files and directories


二把数据集raw格式转成TFRecords形式

 

 

# From tensorflow/models/research/
python object_detection/create_pet_tf_record.py \
    --label_map_path=object_detection/data/pet_label_map.pbtxt \
    --data_dir=`pwd` \
    --output_dir=`pwd`

转换完成后会生成pet_train.record and pet_val.record 文件
 

 

三上传给google cloud去训练

 

 

参考:

https://github.com/tensorflow/models/blob/master/research/object_detection/g3doc/running_pets.md

你可能感兴趣的:(DL)