hzy46 / Deep-Learning-21-Examples

《21个项目玩转深度学习———基于TensorFlow的实践详解》配套代码
4.49k stars 1.76k forks source link

第五章:深度学习中的目标检测 #30

Open fairystery opened 6 years ago

fairystery commented 6 years ago

我的环境是win10,python3。在复现第五章的代码时,目前遇到了三个问题: 1:http://download.tensorflow.org登录不上,然后faster_rcnn_inception_resnet_v2_...那个模型我是通过其他博客找到的default 2:在运行train.py文件时 E:\Softwave\Anaconda\python.exe E:/Codes/Deep-Learning-21-Examples/Chapter_5/research/object_detection/train.py Traceback (most recent call last): File "E:/Codes/Deep-Learning-21-Examples/Chapter_5/research/object_detection/train.py", line 202, in tf.app.run() File "E:\Softwave\Anaconda\lib\site-packages\tensorflow\python\platform\app.py", line 124, in run _sys.exit(main(argv)) File "E:/Codes/Deep-Learning-21-Examples/Chapter_5/research/object_detection/train.py", line 198, in main worker_job_name, is_chief, FLAGS.train_dir) File "E:/Codes/Deep-Learning-21-Examples/Chapter_5/research\object_detection\trainer.py", line 161, in train detection_model = create_model_fn() File "E:/Codes/Deep-Learning-21-Examples/Chapter_5/research\object_detection\builders\model_builder.py", line 77, in build return _build_faster_rcnn_model(model_config.faster_rcnn, is_training) File "E:/Codes/Deep-Learning-21-Examples/Chapter_5/research\object_detection\builders\model_builder.py", line 218, in _build_faster_rcnn_model first_stage_only = frcnn_config.first_stage_only _AttributeError: 'FasterRcnn' object has no attribute 'first_stageonly'

Process finished with exit code 1 default

然后我的做法是将model_bulider.py文件第218和第222行改为了first_stage_only =False 3:在修改为first_stage_only =False后,运行train.py文件后: File "E:\Softwave\Anaconda\lib\site-packages\tensorflow\python\framework\tensor_util.py", line 328, in _AssertCompatible (dtype.name, repr(mismatch), type(mismatch).name)) TypeError: Expected string, got ['VOC/pet_train.record'] of type 'RepeatedScalarFieldContainer' instead. default

default 请问我该如何修改呢。。。 在复现时遇到 了各种奇怪的问题,度娘谷歌了好久,本以为终于可以了,没想到。。。。。。

Zoushuang86 commented 6 years ago

first_stage_atrous_rate = 1,这是多孔卷积的一个属性,参数是整数。

caoshuaibing1993 commented 5 years ago

hi,i want to request this question?how do ?this first_stage_atrous_rate and first_stage_only? thanks

huangzy97 commented 4 years ago

image 我运行python train.py --train_dir voc/train_dir/ --pipeline_config_path voc/voc.config 到上面就停止了,有没有谁知道是咋回事啊?