[英]tensorflow Protobuf Compilation issue
I want to compile protobuf libraries for google object detection API. 我想为google对象检测API编译protobuf库。 I followed the official tutorial and typed protoc object_detection/protos/*.proto --python_out=.
我按照官方教程输入了protoc object_detection/protos/*.proto --python_out=.
. 。 Then what I got is "object_detection/protos/*.proto: Invalid argument". 然后我得到的是“object_detection / protos / * .proto:无效的参数”。 Can anyone tell me what should I do? 谁能告诉我该怎么办? Thanks! 谢谢!
If your operating system is windows, then *. 如果您的操作系统是Windows,那么*。 may not work. 可能行不通。 A good way to solve this problem is to use bash. 解决这个问题的一个好方法是使用bash。 Download git for windows , don't forget to select git bash when you install it. 下载git for windows ,不要忘记在安装时选择git bash。 From tensorflow/models/research/, right click, select git bash, then paste the command, it works well on my laptop. 从tensorflow / models / research /,右键单击,选择git bash,然后粘贴命令,它在我的笔记本电脑上运行良好。
Try 尝试
protoc --python_out=. object_detection/protos/*.proto
Usage: 用法:
protoc [OPTION] PROTO_FILES
I know this is a late answer but after some 20 minutes trying out different things, i decided to try it on another terminal and i tried it on git bash. 我知道这是一个迟到的答案,但在尝试了不同的事情后约20分钟,我决定在另一个终端尝试它,我尝试在git bash上。
You need to be in the correct directory so just cd
into /models-master/research
and make a folder named 1prts
using mkdir
once you are inside the research
directory. 你需要在正确的目录中,以便只是cd
到/models-master/research
并建立文件夹命名1prts
使用mkdir
一旦你在里面research
目录。
Since the last release, the repos has changed so this is the command you need to run: 自上次发布以来,repos已更改,因此这是您需要运行的命令:
protoc object_detection/protos/*.proto --python_out=./1prts
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.