“没有这样的文件或目录"可以仅表示没有“这样的文件或目录"吗? [英] Can `No such file or directory` only mean that there is `No such file or directory`?
问题描述
我正在尝试使用caffe训练网络,但是却遇到了一个文件未找到的异常:
I am trying to train a network using caffe, but am getting a file-not-found exception:
I0111 11:19:27.339706 5151 layer_factory.hpp:76] Creating layer data
I0111 11:19:27.340117 5151 net.cpp:106] Creating Layer data
I0111 11:19:27.340126 5151 net.cpp:411] data -> data
I0111 11:19:27.340154 5151 net.cpp:411] data -> label
I0111 11:19:27.340165 5151 data_transformer.cpp:25] Loading mean file from: /home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/imagenet_mean_10biggest.binaryproto
F0111 11:19:27.340873 5157 db_lmdb.hpp:14] Check failed: mdb_status == 0 (2 vs. 0) No such file or directory
*** Check failure stack trace: ***
@ 0x7f7f1c8f35cd google::LogMessage::Fail()
@ 0x7f7f1c8f5433 google::LogMessage::SendToLog()
@ 0x7f7f1c8f315b google::LogMessage::Flush()
@ 0x7f7f1c8f5e1e google::LogMessageFatal::~LogMessageFatal()
@ 0x7f7f1d032532 caffe::db::LMDB::Open()
@ 0x7f7f1cfe9966 caffe::DataReader::Body::InternalThreadEntry()
@ 0x7f7f1cfdfc25 caffe::InternalThread::entry()
@ 0x7f7f127285d5 (unknown)
@ 0x7f7f11fd66ba start_thread
@ 0x7f7f1be6c82d clone
@ (nil) (unknown)
Aborted (core dumped)
可能有各种各样的原因导致错误,但是似乎确实存在该特定文件.我已经将路径更改为绝对路径,检查了拼写(在这个确切的文件夹中确实存在一个具有这个确切名称的文件),并再次检查了该文件的读写权限.
困难之处在于,当文件似乎确实存在时,查找此错误的原因.我的意思是,还有什么可能的原因?
所以我的问题是:有人知道这个错误的原因吗?
There could be all kinds of things causing errors, but this specific file does seem to be there. I already changed the path to the absolute path, checked spelling (there is indeed a file with this exact name in this exact folder) and double checked the permissions of the file to be read-write.
The difficulty is finding the cause of this error when the file does seem to be there. I mean, what else could be the cause?
So my question is: does anyone know what could be the cause of this error?
根据要求提供ls -ltrh /home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/imagenet_mean_10biggest.binaryproto
的输出:
-rwxrwxr-x 1 myUser myUser 769K jan 10 16:39 /home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/imagenet_mean_10biggest.binaryproto
我假设prototxt文件的相关部分是:
I'm assuming the relevant part of the prototxt file is:
name: "rfnn_ILSVRC2012_Small"
layer {
top: "data"
top: "label"
name: "data"
type: "Data"
data_param {
source: "/home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/ilsvrc12_train_lmdb_10biggest"
backend: LMDB
batch_size: 32
}
transform_param {
crop_size: 224
mirror: true
mean_file: "/home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class
/imagenet_mean_10biggest.binaryproto"
}
include: { phase: TRAIN }
}
layer {
top: "data"
top: "label"
name: "data"
type: "Data"
data_param {
source: "/home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/ilsvrc12_val_lmdb_10biggest"
backend: LMDB
batch_size: 32
}
transform_param {
crop_size: 224
mirror: false
mean_file: "/home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/imagenet_mean_10biggest.binaryproto"
}
include: { phase: TEST }
}
推荐答案
您的平均文件确实存在,但这不是caffe所抱怨的.
您的数据库文件'/home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/ilsvrc12_train_lmdb_10biggest'
呢?在正确的位置吗?
Your mean file is indeed in place, but this is not what caffe is complaining about.
What about your database file, '/home/myUser/Documents/code/RFNN/data/ILSVRC2012/10class/ilsvrc12_train_lmdb_10biggest'
? is it in the right location?
No such file or directory
只能表示存在No such file or directory
吗?
Can
No such file or directory
only mean that there isNo such file or directory
?
是的
这篇关于“没有这样的文件或目录"可以仅表示没有“这样的文件或目录"吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!