google.protobuf.text_format.ParseError: 110:25 : Expected string but found: '“'
It looks like I have some problems when specifying my PATH_TO_BE_CONFIGURED, but I follows the tutorial and don't get what's wrong with my file path.
fine_tune_checkpoint: “/Users/johson/Data/Tensorflow/Models/object_detection/samples/checkpoints/faster_rcnn_resnet101_coco_11_06_2017/model.ckpt"
python object_detection/train.py
--logtostderr
--pipeline_config_path=object_detection/samples/configs/faster_rcnn_resnet101_pets.config
--train_dir=object_detection/models/model/train Traceback (most recent call last): File "object_detection/train.py", line 198, intf.app.run() File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/tensorflow/python/platform/app.py", line 48, in run _sys.exit(main(_sys.argv[:1] + flags_passthrough)) File "object_detection/train.py", line 143, in main model_config, train_config, input_config = get_configs_from_pipeline_file() File "object_detection/train.py", line 103, in get_configs_from_pipeline_file text_format.Merge(f.read(), pipeline_config) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 476, in Merge descriptor_pool=descriptor_pool) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 526, in MergeLines return parser.MergeLines(lines, message) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 559, in MergeLines self._ParseOrMerge(lines, message) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 574, in _ParseOrMerge self._MergeField(tokenizer, message) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 675, in _MergeField merger(tokenizer, message, field) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 764, in _MergeMessageField self._MergeField(tokenizer, sub_message) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 675, in _MergeField merger(tokenizer, message, field) File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 809, in _MergeScalarField value = tokenizer.ConsumeString() File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 1151, in ConsumeString the_bytes = self.ConsumeByteString() File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 1166, in ConsumeByteString the_list = [self._ConsumeSingleByteString()] File "/Users/johson/anaconda3/envs/envy/lib/python3.6/site-packages/google/protobuf/text_format.py", line 1185, in _ConsumeSingleByteString raise self.ParseError('Expected string but found: %r' % (text,)) google.protobuf.text_format.ParseError: 133:19 : Expected string but found: '“'
Solved. It's some quotation marks issues with Textedit.
@johnsonlegend How did you solved this? I have a very similar issue.
google.protobuf.text_format.ParseError: 112:25 : Expected string but found: '/'
Sloved. It was a mistake in the .config file.
@XYAskWhy what type of mistake was that ? Kindly elaborate.
I forgot the " ' ' " in one of the PATH_TO_BE_CONFIGUREDs. @RakeshChandran
Thank you for your response @XYAskWhy .. In my case it was a \n and \t operator in the path name.
@XYAskWhy , @johnsonlegend @RakeshChandran I have this problem when I run train.py in object_detection. This is what I get "TypeError: Expected string, got ['data/train.records'] of type 'RepeatedScalarFieldContainer' instead." I have repleased all path_to_be_configured parts properly. Could you please advise?
i have also the same issue
/home/gopalakrishna/anaconda2/lib/python2.7/site-packages/h5py/init.py:36: FutureWarning: Conversion of the second argument of issubdtype from float to np.floating is deprecated. In future, it will be treated as np.float64 == np.dtype(float).type.
from ._conv import register_converters as _register_converters
Traceback (most recent call last):
File "object_detection/train.py", line 167, in
please help me
Hi! found a solution. I checked my label files with small Linux command-line program "file", the result was:
broken.pbtxt: UTF-8 Unicode (with BOM) text, with CRLF line terminators
working.pbtxt: ASCII text
So when you editing your files keep track of it.
Hopefully it helps
I faced a similar problem relating to label_map_path when running on local machine. Solved by removing spaces between lines in the label map pbtxt file.
i faced a problem when running train.py for object detection..my error is like this:
doe@doe:~/anaconda3/envs/tensorflow/models/research/object_detection$ python3 train.py --logtostderr --train_dir=training/ --pipeline_config_path=training/ssd_mobilenet_v1_coco.config WARNING:tensorflow:From /home/doe/anaconda3/lib/python3.6/site-packages/tensorflow/python/platform/app.py:124: main (from main) is deprecated and will be removed in a future version. Instructions for updating: Use object_detection/model_main.py. Traceback (most recent call last): File "/home/doe/.local/lib/python3.6/site-packages/google/protobuf/text_format.py", line 1500, in _ParseAbstractInteger return int(text, 0) ValueError: invalid literal for int() with base 0: '03'
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/home/doe/.local/lib/python3.6/site-packages/google/protobuf/text_format.py", line 1449, in _ConsumeInteger result = ParseInteger(tokenizer.token, is_signed=is_signed, is_long=is_long) File "/home/doe/.local/lib/python3.6/site-packages/google/protobuf/text_format.py", line 1471, in ParseInteger result = _ParseAbstractInteger(text, is_long=is_long) File "/home/doe/.local/lib/python3.6/site-packages/google/protobuf/text_format.py", line 1502, in _ParseAbstractInteger raise ValueError('Couldn't parse integer: %s' % text) ValueError: Couldn't parse integer: 03
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "train.py", line 184, in
@pixx1 can you elaborate on your solution?
@johnsonlegend how did you solve it? what did you do exactly?
@ruksin not quite sure about you file. But it sais
"ValueError: Couldn't parse integer: 03"
is there something wrong with your label_map? Maybe you wrote id: 03 insteat of id: 3?
@chaine09 Maybe there was a problem with line break: https://stackoverflow.com/questions/1552749/difference-between-cr-lf-lf-and-cr-line-break-types#1552775
(tensorflow1) C:\tensorflow1\models\research\object_detection>python train.py --logtostderr --train_dir=training/ --pipeline_config_path=training/faster_rcnn_inception_v2_pets.config
WARNING:tensorflow:From D:\Anaconda3\envs\tensorflow1\lib\site-packages\tensorflow\python\platform\app.py:125: main (from main) is deprecated and will be removed in a future version.
Instructions for updating:
Use object_detection/model_main.py.
Traceback (most recent call last):
File "train.py", line 184, in
請問遇到上面這個問題要怎麼解決? 謝謝
I'm getting the below error. please do help.
google.protobuf.text_format.ParseError: 158:3 : Message type "object_detection.protos.TrainConfig" has no field named "load_all_detection_checkpoint_vars".
@ravikd123 I'm getting the same error as well. Were you able to fix it?
I had encountered same problem and fix it by removing all comments in the top of the config file
I had encountered same problem and fix it by removing all comments in the top of the config file
could you tell me how to solve this problem in detail?