因此,我正在尝试使用张量流重新训练Mobilenet_SSD_V2对象检测。运行object_detection / model_mail.py脚本时遇到困难,因为它给了我以下错误:
Traceback (most recent call last):
File "object_detection/model_main.py", line 110, in <module>
tf.app.run()
File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/platform/app.py", line 125, in run
_sys.exit(main(argv))
File "object_detection/model_main.py", line 74, in main
eval_input_fns = train_and_eval_dict['eval_input_fns']
KeyError: 'eval_input_fns'
我一直在遵循tensorflow的Running Locally页面来尝试训练网络,但是我一直没有运气。
这是我pipeline.config文件的train_config部分:
train_config {
batch_size: 24
data_augmentation_options {
random_horizontal_flip {
}
}
data_augmentation_options {
ssd_random_crop {
}
}
optimizer {
rms_prop_optimizer {
learning_rate {
exponential_decay_learning_rate {
initial_learning_rate: 0.00400000018999
decay_steps: 800720
decay_factor: 0.949999988079
}
}
momentum_optimizer_value: 0.899999976158
decay: 0.899999976158
epsilon: 1.0
}
}
fine_tune_checkpoint: "/home/owl/jetson_nano_detection_and_tracking/data/ssd_mobilenet_v2_coco_2018_03_29/model.ckpt"
from_detection_checkpoint: true
num_steps: 50000
load_all_detection_checkpoint_vars: true
fine_tune_checkpoint_type: "detection"
}
train_input_reader {
label_map_path: "/usr/local/lib/python3.6/dist-packages/tensorflow/models/research/object_detection/data/pet_label_detection.pbtxt"
tf_record_input_reader {
input_path: "/usr/local/lib/python3.6/dist-packages/tensorflow/models/research/object_detection/data/pet_faces_train.record-?????-of-00010"
}
}
eval_config {
num_examples: 8000
max_evals: 10
use_moving_averages: false
retain_original_images: true
}
eval_input_reader {
label_map_path: "/usr/local/lib/python3.6/dist-packages/tensorflow/models/research/object_detection/data/pet_label_map.pbtxt"
shuffle: false
num_readers: 1
tf_record_input_reader {
input_path: "/usr/local/lib/python3.6/dist-packages/tensorflow/models/research/object_detection/data/pet_faces_val.record-?????-of-00010"
}
}