Protoc object_detection / protos / *. proto: No such file or directory

I follow the example found here . But whenever I enter the command "C: / Program Files / protoc / bin / protoc", object_detection / protos / .proto --python_out =. I get the error message: object_detection / protos / .proto: there is no such file or directory. I cannot create a directory named * .proto. So I do not have enough fundamental information on how to do this. Since I cannot find anyone to complain about this problem, this should be pretty simple. I am using windows.

+12
source share
17 answers

It was decided for Windows to be in a “ study ” and have a “ protocol ” in the way, then this would work:

for /f %i in ('dir /b object_detection\protos\*.proto') do protoc object_detection\protos\%i --python_out=.

Good luck

+8
source

Be sure to change the directory to "models \ research \" and try the steps from the tutorial using protoc 3.4.0, just like the tutorial. I only worked for me using 3.4.0.

my work on cmd:

C:\Users\...\protoc-3.4.0-win32\bin\protoc object_detection/protos/*.proto --python_out=.
+6
source

, , . .

:

protoc object_detection/protos/*.proto --python_out=.

*.Proto, , . 3.5, .

, :

  1. cmd
  2. , ( ):

    cd /d C:\Users\yourusername\Desktop\TensorFlow\models-master\models-master\research
    
  3. protroc.exe,

    C:\Users\yourusername\Desktop\TensorFlow\protoc-3.5.1-win32\bin\protoc 
    
  4. protos, ,

    C:\Users\yourusername\Desktop\TensorFlow\models-master\models-master\research\object_detection\protos
    
  5. .proto cmd:

    C:\Users\yourusername\Desktop\TensorFlow\protoc-3.5.1-win32\bin\protoc object_detection/protos/anchor_generator.proto --python_out=.
    C:\Users\yourusername\Desktop\TensorFlow\protoc-3.5.1-win32\bin\protoc object_detection/protos/argmax_matcher.proto --python_out=.
    C:\Users\yourusername\Desktop\TensorFlow\protoc-3.5.1-win32\bin\protoc object_detection/protos/bipartite_matcher.proto --python_out=.
    ....and so on until you finish all items in the protos folder
    
  6. 3.4 :

    C:\Users\yourusername\Projects\TensorFlow\protoc-3.5.1-win32\bin\protoc object_detection/protos/*.proto --python_out=.
    

, . , .

+4

tenorflow, .proto protobuff, ,

protoc --python_out=. .\object_detection\protos\anchor_generator.proto 
protoc --python_out=. .\object_detection\protos\argmax_matcher.proto  
protoc --python_out=. .\object_detection\protos\bipartite_matcher.proto 
protoc --python_out=. .\object_detection\protos\box_coder.proto 
protoc --python_out=. .\object_detection\protos\box_predictor.proto 
protoc --python_out=. .\object_detection\protos\eval.proto 
protoc --python_out=. .\object_detection\protos\faster_rcnn.proto 
protoc --python_out=. .\object_detection\protos\faster_rcnn_box_coder.proto 
protoc --python_out=. .\object_detection\protos\grid_anchor_generator.proto 
protoc --python_out=. .\object_detection\protos\hyperparams.proto 
protoc --python_out=. .\object_detection\protos\image_resizer.proto 
protoc --python_out=. .\object_detection\protos\input_reader.proto 
protoc --python_out=. .\object_detection\protos\losses.proto 
protoc --python_out=. .\object_detection\protos\matcher.proto 
protoc --python_out=. .\object_detection\protos\mean_stddev_box_coder.proto 
protoc --python_out=. .\object_detection\protos\model.proto 
protoc --python_out=. .\object_detection\protos\optimizer.proto 
protoc --python_out=. .\object_detection\protos\pipeline.proto 
protoc --python_out=. .\object_detection\protos\post_processing.proto 
protoc --python_out=. .\object_detection\protos\preprocessor.proto 
protoc --python_out=. .\object_detection\protos\region_similarity_calculator.proto 
protoc --python_out=. .\object_detection\protos\square_box_coder.proto 
protoc --python_out=. .\object_detection\protos\ssd.proto 
protoc --python_out=. .\object_detection\protos\ssd_anchor_generator.proto 
protoc --python_out=. .\object_detection\protos\string_int_label_map.proto 
protoc --python_out=. .\object_detection\protos\train.proto 
protoc --python_out=. .\object_detection\protos\keypoint_box_coder.proto 
protoc --python_out=. .\object_detection\protos\multiscale_anchor_generator.proto
+3

-... protoc 3.5... WINDOWS... , 3.4.0, :! protoc object_detection/protos/*. proto --python_out =.

+2

, models/research/object_detection/protos , https://github.com/tensorflow/models. , .. No such file or directory.

+1

, , tenorflow:

:

1- 64- Google Protobuf Windows 10, . https://github.com/protocolbuffers/protobuf/releases/tag/v3.4.0 "protoc-3.4.0-win32.zip". ( - protoc-3.6.0)

2- . https://github.com/tensorflow/models

3. protobuf :

4- : cd C:\Users\Ankit\tenorflow\models\research Enter//

5- :

"C:\Users\Ankit\Desktop\Tensorflow\protbuf\bin\protoc.exe" object_detection/protos/*. Proto --python_out =. Enter ( , )

6-. object_detection/protos, , .py, .proto

+1

.proto tensorflow-models/research/object_detection/protos/.

,

cd C:\path\to\tensorflow-models\research 

. Windows. . , :

C:\Program Files\protoc-<version>\bin\protoc object_detection/protos/.proto --python_out=.

, . <version> protoc.

- , . protoc object_detection/protos/.proto --python_out=.

0

Cmd '*'. . . Loop Cmd checkout . https://ss64.com/nt/for.html : protoc Windows 7

0

missing output directive. , , , , *.proto .

0

Ubuntu 16.04. , .

0

protoc protoc-3.4.0-win32.zip, , protoc.exe bin. .

/ .

protoc.

protoc object_detection/protos/*. proto --python_out =.

0

Python-, protoc

import os

#folder where protos are located
os.chdir('C:\\Users\\ ~ \\models-master\\research\\object_detection\\protos')
#list protos
fs=os.listdir()

#back to where your protoc.exe is located
os.chdir('C:\\Users\\ ~ \\models-master\\research')

for f in fs:
if f.find(".proto")>-1:
    print(f)
    s='protoc object_detection/protos/'+f+' --python_out=.'
    print(s)
    os.system(s)
0

, , 3.4 3.6 Windows 7 Professional

C:\tensorflow1\models\research>for /F %i in 
('dir /b 
.\object_detection\protos\*
.proto') do ( c:\tensorflow1\models\research\bin/protoc 
.\object_detection\protos\%i --python_out=.)
0

Object_detection/protos/.proto: No such file or directory.

, Protocol Buffers v3.4.0.

, models-master\research :

FullPathToProtoc/protoc-3.4.0-win32/bin/protoc object_detection/protos/*.proto --python_out=.

0

protoc-3.6.1-win32.zip..

, .proto .

%% v object_detection\protos *.proto do (D:\bin\protoc %% v --python_out =.)

models\research. . , , protoc.

0

Source: https://habr.com/ru/post/1686647/


All Articles