Models: object_detection.protos.SsdFeatureExtractor" has no field named

Created on 29 Apr 2018  路  12Comments  路  Source: tensorflow/models

When train ssd_inception_v2 and ssd_mobilenetV2, I got a message as below

===============================================================================

jeonghyunsu@jeonghyunsu:~/氚旐儠頇旊┐/models/research/object_detection$ python3 train.py --logtostderr --train_dir=training/ --pipeline_config_path=training/ssd_inception_v2_coco.config
Traceback (most recent call last):
File "train.py", line 167, in
tf.app.run()
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/platform/app.py", line 124, in run
_sys.exit(main(argv))
File "train.py", line 92, in main
FLAGS.pipeline_config_path)
File "/usr/local/lib/python3.5/dist-packages/object_detection-0.1-py3.5.egg/object_detection/utils/config_util.py", line 88, in get_configs_from_pipeline_file
text_format.Merge(proto_str, pipeline_config)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 533, in Merge
descriptor_pool=descriptor_pool)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 587, in MergeLines
return parser.MergeLines(lines, message)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 620, in MergeLines
self._ParseOrMerge(lines, message)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 635, in _ParseOrMerge
self._MergeField(tokenizer, message)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 735, in _MergeField
merger(tokenizer, message, field)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 823, in _MergeMessageField
self._MergeField(tokenizer, sub_message)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 735, in _MergeField
merger(tokenizer, message, field)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 823, in _MergeMessageField
self._MergeField(tokenizer, sub_message)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 735, in _MergeField
merger(tokenizer, message, field)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 823, in _MergeMessageField
self._MergeField(tokenizer, sub_message)
File "/usr/local/lib/python3.5/dist-packages/google/protobuf/text_format.py", line 703, in _MergeField
(message_descriptor.full_name, name))
google.protobuf.text_format.ParseError: 101:7 : Message type "object_detection.protos.SsdFeatureExtractor" has no field named "override_base_feature_extractor_hyperparams".

===============================================================================

In this issue, some said "should change "is_training=False->is_training=True".
ssd_mobilenet_v2_feature_extractor.py has above code ("is_training=False"),
but ssd_inception_v2_feature_extractor.py hasn't above code. So, I don't know the solution.
(I used "tensorflow/models" downloaded in Jan)
(I followed "https://www.youtube.com/watch?v=kq2Gjv_pPe8" to train mobilenetV1 model,
I succeeded ssd mobilenet V1 model. but, failed ssd_inception_V2 and mobilenet V2)

Most helpful comment

I solved! I remove protobuf version 2 and install protobut 3.5 (latest version).
1 2018-05-14 14-39-32
2 2018-05-14 14-40-52
3 2018-05-14 14-57-01
4 2018-05-14 15-06-17
6 2018-05-14 15-16-28

And, I downloaded "tensorflow/models github (the latest version) " and insert command "protoc object_detection/protos/*.proto --python_out=."
7 2018-05-14 15-24-38

and then insert train command "python3 train.py --logtostderr --train_dir=training/ --pipeline_config_path=training/ssd_mobilenet_v2_coco.config "

Without any modification, I succeeded to train another models, ssd_mobilenet V2 and ssd_inception_v2.

All 12 comments

Thank you for your post. We noticed you have not filled out the following field in the issue template. Could you update them if they are relevant in your case, or leave them as N/A? Thanks.
What is the top-level directory of the model you are using
Have I written custom code
OS Platform and Distribution
TensorFlow installed from
TensorFlow version
Bazel version
CUDA/cuDNN version
GPU model and memory
Exact command to reproduce

I have exactly the same issue, trying to use ssd_inception_v2_coco model.

What is the top-level directory of the model you are using N/A
Have I written custom code: No
OS Platform and Distribution: Windows
TensorFlow installed from: pip
TensorFlow version 1.4
Bazel version N/A
CUDA/cuDNN version Cuda 8.0
GPU model and memory Nvidia Titan X, 12 GB
Exact command to reproduce: python train.py --logtostderr --train_dir=training/ --pipeline_config_path=training/ssd_inception_v2_coco.config

I commented out "override_base_feature_extractor_hyperparams: true" (line 101) in the config file

@ransalmo , the version of TensorFlow you are using is out of date; does the problem persist if you upgrade TensorFlow?

Hi, I got the same problem using 1.7. I will try with Mr-Optimistic approach.

Hi, I also got this error when I update object_detection git. I fixed it by running again Protobuf Compilation:
protoc object_detection/protos/*.proto --python_out=.

Hope this help !

Hi guys, I upgraded to the latest version of TensorFlow and I removed the line 101 "override_base_feature_extractor_hyperparams: true" from the config file. Looks like it works.

What does that command "protoc object_detection/protos/*.proto --python_out=." do exactly?

I solved! I remove protobuf version 2 and install protobut 3.5 (latest version).
1 2018-05-14 14-39-32
2 2018-05-14 14-40-52
3 2018-05-14 14-57-01
4 2018-05-14 15-06-17
6 2018-05-14 15-16-28

And, I downloaded "tensorflow/models github (the latest version) " and insert command "protoc object_detection/protos/*.proto --python_out=."
7 2018-05-14 15-24-38

and then insert train command "python3 train.py --logtostderr --train_dir=training/ --pipeline_config_path=training/ssd_mobilenet_v2_coco.config "

Without any modification, I succeeded to train another models, ssd_mobilenet V2 and ssd_inception_v2.

It works for me 馃憤

Updating the repo resolved this issue for me

Closing this issue since its resolved. Thanks!

Was this page helpful?
0 / 5 - 0 ratings