Git Product home page Git Product logo

opencl-caffe's Introduction

This was experimental branch of Caffe for OpenCL, we know recommend you use the now official OpenCL port of Caffe in BVLC GitHub Repo at https://github.com/BVLC/caffe/tree/opencl

OpenCL Caffe Experimental branch by AMD Reserach- No new development is happing on it.

This is an OpenCL implementation of Caffe, a mainstream DNN framework (https://github.com/BVLC/caffe). It includes a largely complete Caffe feature set as of August 2015. The project is under active development to improve performance and add new features. Contributions from the community are welcome.

OpenCL (https://en.wikipedia.org/wiki/OpenCL) is an open standard parallel programming language for heterogeneous platforms. OpenCL is supported by a variety of commercial chip manufacturers.

Branches

We have three branches in this repo.

-stable, the stable branch for users

-dev, the developer branch, we encourage people to contribute on this branch

-master, the original Caffe's master branch against which our code is synchronized.

Design features

-All Caffe layers ported to OpenCL

-Performance improvement by batched implementation for conv layer based on clBLAS

-The user can choose the optimal batch number depending on H/W properties, image size and minibatch size

-Supports OpenCL 2.0, 1.2

-Implemented in C++ and OpenCL, maintaining the same interfaces as the original Caffe

-Users can directly run DNN models: AlexNet, VGG-16 and VGG-19

Note: More features are planned in the near future. Currently this implementation has been verified and tuned on AMD devices (CPUs/GPUs/APUs). Compatibility across different chip manufacturers will be considered for future addition.

Performance

We intend to keep updating the latest performance as we make optimizations. Fury results are preliminary and are actively being improved.

  • Training speed (Model: AlexNet, minibatch size 128)
Platform Speed (images per second)
AMD W9100 & A10-7850k 255
AMD R9 Fury & A10-7850k 261
AMD R290X @1000MHz & A10-7850k 268
AMD S9150 @900MHz & Xeon E5-2640 227
  • Recognition speed (Model: AlexNet, minibatch size 128)
Platform Speed (images per second)
AMD W9100 & A10-7850k 590
AMD R9 Fury & A10-7850k 699
AMD R290X @1000MHz & A10-7850k 606
AMD S9150 @900MHz & Xeon E5-2640 452

Wiki

For more information on how to install, use or contribute to this code base, please visit our wiki page: https://github.com/amd/OpenCL-caffe/wiki

Contributors

Junli Gu, Yibing Liu, Yuan Gao, Maohua Zhu

We thank Mauricio Breternitz, Hanjin Chu and Greg Stoner for their technical suggestions and support.

If you have any questions, please send an email to [email protected]

Support needed

As an open source project, we hope to maintain an open dynamics and sharing culture. We encourage the contribution and support from the community to improve it together.

License

The original Caffe is provided in the BSD 2-Clause license open source license. The OpenCL ports written by AMD is covered by AMD license. We encourage the contribution and support from external, your contribution will be covered either by BSD 2-Clause license or whichever your preferred license.

Original Caffe information

Caffe

Caffe is a deep learning framework made with expression, speed, and modularity in mind. It is developed by the Berkeley Vision and Learning Center (BVLC) and community contributors.

Check out the project site for all the details like

and step-by-step examples.

Join the chat at https://gitter.im/BVLC/caffe

Please join the caffe-users group or gitter chat to ask questions and talk about methods and models. Framework development discussions and thorough bug reports are collected on Issues.

Happy brewing!

License and Citation

Caffe is released under the BSD 2-Clause license. The BVLC reference models are released for unrestricted use.

Please cite Caffe in your publications if it helps your research:

@article{jia2014caffe,
  Author = {Jia, Yangqing and Shelhamer, Evan and Donahue, Jeff and Karayev, Sergey and Long, Jonathan and Girshick, Ross and Guadarrama, Sergio and Darrell, Trevor},
  Journal = {arXiv preprint arXiv:1408.5093},
  Title = {Caffe: Convolutional Architecture for Fast Feature Embedding},
  Year = {2014}
}

opencl-caffe's People

Contributors

arntanguy avatar chyojn avatar cnikolaou avatar dgolden1 avatar erictzeng avatar flx42 avatar gujunli avatar jamt9000 avatar jeffdonahue avatar jyegerlehner avatar kloudkl avatar longjon avatar lukeyeager avatar mavenlin avatar mohomran avatar mtamburrano avatar netheril96 avatar philkr avatar pluskid avatar qipeng avatar rbgirshick avatar ronghanghu avatar sergeyk avatar sguada avatar shelhamer avatar ste-m5s avatar tdomhan avatar tnarihi avatar yangqing avatar yosinski avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

opencl-caffe's Issues

Indentation not consistent with caffe indentation

caffe indentation appears to be 1 space per indent level, which is a bit bizarre, but nevertheless what they appear to be using (I just looked a couple of files, I could be wrong...). I reckon you probably wnat to use the same indentation as existing caffe, rather than change to, what looks to me like, 1 tab per indent level?

make runtest error in ocl_util.cpp

when I make runtest,I get the error that:
[ RUN ] SoftmaxWithLossLayerTest/3.TestForwardIgnoreLabel
F0323 15:31:53.025662 2818 ocl_util.cpp:77] Check failed: error == 0 (-54 vs. 0) -54
*** Check failure stack trace: ***
@ 0x2b4e19c16daa (unknown)
@ 0x2b4e19c16ce4 (unknown)
@ 0x2b4e19c166e6 (unknown)
@ 0x2b4e19c19687 (unknown)
@ 0x2b4e1964b5e8 caffe::ocl_memset()
@ 0x2b4e1964e35b caffe::SyncedMemory::mutable_gpu_data()
@ 0x2b4e195ab632 caffe::Blob<>::mutable_gpu_data()
@ 0x2b4e19707d41 caffe::SoftmaxLayer<>::Forward_gpu()
@ 0x2b4e19670599 caffe::SoftmaxWithLossLayer<>::Forward_gpu()
@ 0x721ab8 caffe::Layer<>::Forward()
@ 0x9f41d5 caffe::SoftmaxWithLossLayerTest_TestForwardIgnoreLabel_Test<>::TestBody()
@ 0xa409d3 testing::internal::HandleExceptionsInMethodIfSupported<>()
@ 0xa371f7 testing::Test::Run()
@ 0xa3729e testing::TestInfo::Run()
@ 0xa373a5 testing::TestCase::Run()
@ 0xa3a0f8 testing::internal::UnitTestImpl::RunAllTests()
@ 0xa3a397 testing::UnitTest::Run()
@ 0x6f2c25 main
@ 0x2b4e1bc51ec5 (unknown)
@ 0x6f7d62 (unknown)
@ (nil) (unknown)
Aborted (core dumped)
make[3]: *** [src/caffe/test/CMakeFiles/runtest] error 134
make[2]: *** [src/caffe/test/CMakeFiles/runtest.dir/all] error 2
make[1]: *** [src/caffe/test/CMakeFiles/runtest.dir/rule] error 2
make: *** [runtest] error 2

How can I solve the error?
It seems that the problem is due to the opencl, but I install opencl from AMDAPPSDK-2.9-1, and I can find opencl when cmake

thank you!

Cannot find any dGPU?I use A10-7850

Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160319-002926.5520!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160319-002926.5520!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160319-002926.5520!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160319-002926.5520!F0319 00:29:26.820322 5520 device.cpp:95] Cannot find any dGPU!
*** Check failure stack trace: ***
@ 0x7fbf1b7d0ea4 (unknown)
@ 0x7fbf1b7d0deb (unknown)
@ 0x7fbf1b7d07bf (unknown)
@ 0x7fbf1b7d3a35 (unknown)
@ 0x7fbf1bad9a77 caffe::Device::Init()
@ 0x7fbf1badaedd caffe::Caffe::Caffe()
@ 0x409865 train()
@ 0x4069d1 main
@ 0x7fbf1aab0a40 (unknown)
@ 0x407019 _start
@ (nil) (unknown)
Aborted (core dumped)

Trouble with classify.py

I am trying to get the classification functionality of Caffe to work.

I am running this command, which I found here to test classification with the classify.py defaults:

/python/classify.py --raw_scale=255 examples/images/cat.jpg out.npy

It's saying it failed to parse the netParameter file, but I find that to be sort of confusing because it prints out the details of the network from that file before it fails.

Any help or tips would be appreciated, not sure how to proceed.

This is the printout:

nathan@10:/OpenCL-caffe$ ./python/classify.py --raw_scale=255 examples/images/cat.jpg out.npy
WARNING: Logging before InitGoogleLogging() is written to STDERR
I0402 00:38:06.527276 8318 device.cpp:233] Number of platforms found:1
I0402 00:38:06.527321 8318 device.cpp:265] CL_PLATFORM_NAME AMD Accelerated Parallel Processing
I0402 00:38:06.527338 8318 device.cpp:265] CL_PLATFORM_PROFILE FULL_PROFILE
I0402 00:38:06.527351 8318 device.cpp:265] CL_PLATFORM_VERSION OpenCL 2.0 AMD-APP (1800.8)
I0402 00:38:06.527365 8318 device.cpp:265] CL_PLATFORM_VENDOR Advanced Micro Devices, Inc.
I0402 00:38:06.527379 8318 device.cpp:265] CL_PLATFORM_EXTENSIONS cl_khr_icd cl_amd_event_callback cl_amd_offline_devices
I0402 00:38:06.527395 8318 device.cpp:289] Number of devices found:4
I0402 00:38:06.527403 8318 device.cpp:291] DeviceID: 0x3735180
I0402 00:38:06.527420 8318 device.cpp:380] Device Type: CL_DEVICE_TYPE_GPU
I0402 00:38:06.527434 8318 device.cpp:407] Is it integrated GPU?: 0
I0402 00:38:06.527448 8318 device.cpp:407] Max clock frequency MHz: 880
I0402 00:38:06.527462 8318 device.cpp:407] Host-Device unified mem: 0
I0402 00:38:06.527477 8318 device.cpp:407] ECC support: 0
I0402 00:38:06.527489 8318 device.cpp:407] Endian little: 1
I0402 00:38:06.527503 8318 device.cpp:407] Max compute units: 28
I0402 00:38:06.527529 8318 device.cpp:407] Max work group size: 256
I0402 00:38:06.527541 8318 device.cpp:407] Max work item dimensions: 3
I0402 00:38:06.527555 8318 device.cpp:407] Max work item sizes: 0x100
I0402 00:38:06.527570 8318 device.cpp:403] CL_DEVICE_QUEUE_PROPERTIES: CL_QUEUE_PROFILING_ENABLE
I0402 00:38:06.527585 8318 device.cpp:391] CL_DEVICE_EXECUTION_CAPABILITIES: CL_EXEC_KERNEL
I0402 00:38:06.527598 8318 device.cpp:407] Max mem alloc size: 2128871424
I0402 00:38:06.527612 8318 device.cpp:407] Global mem size: 2960130048
I0402 00:38:06.527626 8318 device.cpp:407] Local mem size: 32768
I0402 00:38:06.527638 8318 device.cpp:291] DeviceID: 0x3ca1fe0
I0402 00:38:06.527652 8318 device.cpp:380] Device Type: CL_DEVICE_TYPE_GPU
I0402 00:38:06.527667 8318 device.cpp:407] Is it integrated GPU?: 0
I0402 00:38:06.527680 8318 device.cpp:407] Max clock frequency MHz: 880
I0402 00:38:06.527693 8318 device.cpp:407] Host-Device unified mem: 0
I0402 00:38:06.527706 8318 device.cpp:407] ECC support: 0
I0402 00:38:06.527720 8318 device.cpp:407] Endian little: 1
I0402 00:38:06.527734 8318 device.cpp:407] Max compute units: 28
I0402 00:38:06.527747 8318 device.cpp:407] Max work group size: 256
I0402 00:38:06.527760 8318 device.cpp:407] Max work item dimensions: 3
I0402 00:38:06.527775 8318 device.cpp:407] Max work item sizes: 0x100
I0402 00:38:06.527788 8318 device.cpp:403] CL_DEVICE_QUEUE_PROPERTIES: CL_QUEUE_PROFILING_ENABLE
I0402 00:38:06.527802 8318 device.cpp:391] CL_DEVICE_EXECUTION_CAPABILITIES: CL_EXEC_KERNEL
I0402 00:38:06.527815 8318 device.cpp:407] Max mem alloc size: 2205941760
I0402 00:38:06.527829 8318 device.cpp:407] Global mem size: 3183476736
I0402 00:38:06.527842 8318 device.cpp:407] Local mem size: 32768
I0402 00:38:06.527855 8318 device.cpp:291] DeviceID: 0x3c74630
I0402 00:38:06.527869 8318 device.cpp:380] Device Type: CL_DEVICE_TYPE_GPU
I0402 00:38:06.527883 8318 device.cpp:407] Is it integrated GPU?: 0
I0402 00:38:06.527896 8318 device.cpp:407] Max clock frequency MHz: 880
I0402 00:38:06.527909 8318 device.cpp:407] Host-Device unified mem: 0
I0402 00:38:06.527923 8318 device.cpp:407] ECC support: 0
I0402 00:38:06.527936 8318 device.cpp:407] Endian little: 1
I0402 00:38:06.527951 8318 device.cpp:407] Max compute units: 28
I0402 00:38:06.527963 8318 device.cpp:407] Max work group size: 256
I0402 00:38:06.527982 8318 device.cpp:407] Max work item dimensions: 3
I0402 00:38:06.527995 8318 device.cpp:407] Max work item sizes: 0x100
I0402 00:38:06.528009 8318 device.cpp:403] CL_DEVICE_QUEUE_PROPERTIES: CL_QUEUE_PROFILING_ENABLE
I0402 00:38:06.528023 8318 device.cpp:391] CL_DEVICE_EXECUTION_CAPABILITIES: CL_EXEC_KERNEL
I0402 00:38:06.528038 8318 device.cpp:407] Max mem alloc size: 2205941760
I0402 00:38:06.528050 8318 device.cpp:407] Global mem size: 3183476736
I0402 00:38:06.528064 8318 device.cpp:407] Local mem size: 32768
I0402 00:38:06.528077 8318 device.cpp:291] DeviceID: 0x3e60b10
I0402 00:38:06.528091 8318 device.cpp:380] Device Type: CL_DEVICE_TYPE_GPU
I0402 00:38:06.528105 8318 device.cpp:407] Is it integrated GPU?: 0
I0402 00:38:06.528118 8318 device.cpp:407] Max clock frequency MHz: 880
I0402 00:38:06.528131 8318 device.cpp:407] Host-Device unified mem: 0
I0402 00:38:06.528144 8318 device.cpp:407] ECC support: 0
I0402 00:38:06.528158 8318 device.cpp:407] Endian little: 1
I0402 00:38:06.528172 8318 device.cpp:407] Max compute units: 28
I0402 00:38:06.528184 8318 device.cpp:407] Max work group size: 256
I0402 00:38:06.528203 8318 device.cpp:407] Max work item dimensions: 3
I0402 00:38:06.528216 8318 device.cpp:407] Max work item sizes: 0x100
I0402 00:38:06.528230 8318 device.cpp:403] CL_DEVICE_QUEUE_PROPERTIES: CL_QUEUE_PROFILING_ENABLE
I0402 00:38:06.528255 8318 device.cpp:391] CL_DEVICE_EXECUTION_CAPABILITIES: CL_EXEC_KERNEL
I0402 00:38:06.528270 8318 device.cpp:407] Max mem alloc size: 2205941760
I0402 00:38:06.528283 8318 device.cpp:407] Global mem size: 3183476736
I0402 00:38:06.528296 8318 device.cpp:407] Local mem size: 32768
I0402 00:38:06.528312 8318 device.cpp:90] Picked default device type : dGPU 0
I0402 00:38:12.589821 8318 device.cpp:159] Build Program
CPU mode
I0402 00:38:12.591653 8318 net.cpp:43] Initializing net from parameters:
name: "CaffeNet"
input: "data"
input_dim: 10
input_dim: 3
input_dim: 227
input_dim: 227
state {
phase: TEST
}
layer {
name: "conv1"
type: "Convolution"
bottom: "data"
top: "conv1"
convolution_param {
num_output: 96
kernel_size: 11
stride: 4
}
}
layer {
name: "relu1"
type: "ReLU"
bottom: "conv1"
top: "conv1"
}
layer {
name: "pool1"
type: "Pooling"
bottom: "conv1"
top: "pool1"
pooling_param {
pool: MAX
kernel_size: 3
stride: 2
}
}
layer {
name: "norm1"
type: "LRN"
bottom: "pool1"
top: "norm1"
lrn_param {
local_size: 5
alpha: 0.0001
beta: 0.75
}
}
layer {
name: "conv2"
type: "Convolution"
bottom: "norm1"
top: "conv2"
convolution_param {
num_output: 256
pad: 2
kernel_size: 5
group: 2
}
}
layer {
name: "relu2"
type: "ReLU"
bottom: "conv2"
top: "conv2"
}
layer {
name: "pool2"
type: "Pooling"
bottom: "conv2"
top: "pool2"
pooling_param {
pool: MAX
kernel_size: 3
stride: 2
}
}
layer {
name: "norm2"
type: "LRN"
bottom: "pool2"
top: "norm2"
lrn_param {
local_size: 5
alpha: 0.0001
beta: 0.75
}
}
layer {
name: "conv3"
type: "Convolution"
bottom: "norm2"
top: "conv3"
convolution_param {
num_output: 384
pad: 1
kernel_size: 3
}
}
layer {
name: "relu3"
type: "ReLU"
bottom: "conv3"
top: "conv3"
}
layer {
name: "conv4"
type: "Convolution"
bottom: "conv3"
top: "conv4"
convolution_param {
num_output: 384
pad: 1
kernel_size: 3
group: 2
}
}
layer {
name: "relu4"
type: "ReLU"
bottom: "conv4"
top: "conv4"
}
layer {
name: "conv5"
type: "Convolution"
bottom: "conv4"
top: "conv5"
convolution_param {
num_output: 256
pad: 1
kernel_size: 3
group: 2
}
}
layer {
name: "relu5"
type: "ReLU"
bottom: "conv5"
top: "conv5"
}
layer {
name: "pool5"
type: "Pooling"
bottom: "conv5"
top: "pool5"
pooling_param {
pool: MAX
kernel_size: 3
stride: 2
}
}
layer {
name: "fc6"
type: "InnerProduct"
bottom: "pool5"
top: "fc6"
inner_product_param {
num_output: 4096
}
}
layer {
name: "relu6"
type: "ReLU"
bottom: "fc6"
top: "fc6"
}
layer {
name: "drop6"
type: "Dropout"
bottom: "fc6"
top: "fc6"
dropout_param {
dropout_ratio: 0.5
}
}
layer {
name: "fc7"
type: "InnerProduct"
bottom: "fc6"
top: "fc7"
inner_product_param {
num_output: 4096
}
}
layer {
name: "relu7"
type: "ReLU"
bottom: "fc7"
top: "fc7"
}
layer {
name: "drop7"
type: "Dropout"
bottom: "fc7"
top: "fc7"
dropout_param {
dropout_ratio: 0.5
}
}
layer {
name: "fc8"
type: "InnerProduct"
bottom: "fc7"
top: "fc8"
inner_product_param {
num_output: 1000
}
}
layer {
name: "prob"
type: "Softmax"
bottom: "fc8"
top: "prob"
}
I0402 00:38:12.592326 8318 net.cpp:380] Input 0 -> data
I0402 00:38:12.592362 8318 layer_factory.hpp:74] Creating layer conv1
I0402 00:38:12.592377 8318 net.cpp:90] Creating Layer conv1
I0402 00:38:12.592386 8318 net.cpp:423] conv1 <- data
I0402 00:38:12.592397 8318 net.cpp:378] conv1 -> conv1
I0402 00:38:12.592417 8318 net.cpp:120] Setting up conv1
I0402 00:38:12.593049 8318 net.cpp:127] Top shape: 10 96 55 55 (2904000)
I0402 00:38:12.593086 8318 layer_factory.hpp:74] Creating layer relu1
I0402 00:38:12.593103 8318 net.cpp:90] Creating Layer relu1
I0402 00:38:12.593113 8318 net.cpp:423] relu1 <- conv1
I0402 00:38:12.593123 8318 net.cpp:367] relu1 -> conv1 (in-place)
I0402 00:38:12.593135 8318 net.cpp:120] Setting up relu1
I0402 00:38:12.593152 8318 net.cpp:127] Top shape: 10 96 55 55 (2904000)
I0402 00:38:12.593163 8318 layer_factory.hpp:74] Creating layer pool1
I0402 00:38:12.593174 8318 net.cpp:90] Creating Layer pool1
I0402 00:38:12.593183 8318 net.cpp:423] pool1 <- conv1
I0402 00:38:12.593192 8318 net.cpp:378] pool1 -> pool1
I0402 00:38:12.593204 8318 net.cpp:120] Setting up pool1
I0402 00:38:12.593228 8318 net.cpp:127] Top shape: 10 96 27 27 (699840)
I0402 00:38:12.593238 8318 layer_factory.hpp:74] Creating layer norm1
I0402 00:38:12.593250 8318 net.cpp:90] Creating Layer norm1
I0402 00:38:12.593260 8318 net.cpp:423] norm1 <- pool1
I0402 00:38:12.593269 8318 net.cpp:378] norm1 -> norm1
I0402 00:38:12.593281 8318 net.cpp:120] Setting up norm1
I0402 00:38:12.593294 8318 net.cpp:127] Top shape: 10 96 27 27 (699840)
I0402 00:38:12.593302 8318 layer_factory.hpp:74] Creating layer conv2
I0402 00:38:12.593314 8318 net.cpp:90] Creating Layer conv2
I0402 00:38:12.593327 8318 net.cpp:423] conv2 <- norm1
I0402 00:38:12.593336 8318 net.cpp:378] conv2 -> conv2
I0402 00:38:12.593348 8318 net.cpp:120] Setting up conv2
I0402 00:38:12.593807 8318 net.cpp:127] Top shape: 10 256 27 27 (1866240)
I0402 00:38:12.593847 8318 layer_factory.hpp:74] Creating layer relu2
I0402 00:38:12.593861 8318 net.cpp:90] Creating Layer relu2
I0402 00:38:12.593870 8318 net.cpp:423] relu2 <- conv2
I0402 00:38:12.593883 8318 net.cpp:367] relu2 -> conv2 (in-place)
I0402 00:38:12.593896 8318 net.cpp:120] Setting up relu2
I0402 00:38:12.593909 8318 net.cpp:127] Top shape: 10 256 27 27 (1866240)
I0402 00:38:12.593919 8318 layer_factory.hpp:74] Creating layer pool2
I0402 00:38:12.593930 8318 net.cpp:90] Creating Layer pool2
I0402 00:38:12.593940 8318 net.cpp:423] pool2 <- conv2
I0402 00:38:12.593950 8318 net.cpp:378] pool2 -> pool2
I0402 00:38:12.593964 8318 net.cpp:120] Setting up pool2
I0402 00:38:12.593982 8318 net.cpp:127] Top shape: 10 256 13 13 (432640)
I0402 00:38:12.593992 8318 layer_factory.hpp:74] Creating layer norm2
I0402 00:38:12.594004 8318 net.cpp:90] Creating Layer norm2
I0402 00:38:12.594014 8318 net.cpp:423] norm2 <- pool2
I0402 00:38:12.594024 8318 net.cpp:378] norm2 -> norm2
I0402 00:38:12.594036 8318 net.cpp:120] Setting up norm2
I0402 00:38:12.594051 8318 net.cpp:127] Top shape: 10 256 13 13 (432640)
I0402 00:38:12.594060 8318 layer_factory.hpp:74] Creating layer conv3
I0402 00:38:12.594074 8318 net.cpp:90] Creating Layer conv3
I0402 00:38:12.594084 8318 net.cpp:423] conv3 <- norm2
I0402 00:38:12.594094 8318 net.cpp:378] conv3 -> conv3
I0402 00:38:12.594106 8318 net.cpp:120] Setting up conv3
I0402 00:38:12.595118 8318 net.cpp:127] Top shape: 10 384 13 13 (648960)
I0402 00:38:12.595156 8318 layer_factory.hpp:74] Creating layer relu3
I0402 00:38:12.595171 8318 net.cpp:90] Creating Layer relu3
I0402 00:38:12.595180 8318 net.cpp:423] relu3 <- conv3
I0402 00:38:12.595194 8318 net.cpp:367] relu3 -> conv3 (in-place)
I0402 00:38:12.595207 8318 net.cpp:120] Setting up relu3
I0402 00:38:12.595219 8318 net.cpp:127] Top shape: 10 384 13 13 (648960)
I0402 00:38:12.595229 8318 layer_factory.hpp:74] Creating layer conv4
I0402 00:38:12.595242 8318 net.cpp:90] Creating Layer conv4
I0402 00:38:12.595250 8318 net.cpp:423] conv4 <- conv3
I0402 00:38:12.595262 8318 net.cpp:378] conv4 -> conv4
I0402 00:38:12.595275 8318 net.cpp:120] Setting up conv4
I0402 00:38:12.596067 8318 net.cpp:127] Top shape: 10 384 13 13 (648960)
I0402 00:38:12.596101 8318 layer_factory.hpp:74] Creating layer relu4
I0402 00:38:12.596115 8318 net.cpp:90] Creating Layer relu4
I0402 00:38:12.596124 8318 net.cpp:423] relu4 <- conv4
I0402 00:38:12.596137 8318 net.cpp:367] relu4 -> conv4 (in-place)
I0402 00:38:12.596150 8318 net.cpp:120] Setting up relu4
I0402 00:38:12.596163 8318 net.cpp:127] Top shape: 10 384 13 13 (648960)
I0402 00:38:12.596173 8318 layer_factory.hpp:74] Creating layer conv5
I0402 00:38:12.596184 8318 net.cpp:90] Creating Layer conv5
I0402 00:38:12.596194 8318 net.cpp:423] conv5 <- conv4
I0402 00:38:12.596204 8318 net.cpp:378] conv5 -> conv5
I0402 00:38:12.596216 8318 net.cpp:120] Setting up conv5
I0402 00:38:12.596774 8318 net.cpp:127] Top shape: 10 256 13 13 (432640)
I0402 00:38:12.596810 8318 layer_factory.hpp:74] Creating layer relu5
I0402 00:38:12.596824 8318 net.cpp:90] Creating Layer relu5
I0402 00:38:12.596834 8318 net.cpp:423] relu5 <- conv5
I0402 00:38:12.596845 8318 net.cpp:367] relu5 -> conv5 (in-place)
I0402 00:38:12.596859 8318 net.cpp:120] Setting up relu5
I0402 00:38:12.596871 8318 net.cpp:127] Top shape: 10 256 13 13 (432640)
I0402 00:38:12.596881 8318 layer_factory.hpp:74] Creating layer pool5
I0402 00:38:12.596892 8318 net.cpp:90] Creating Layer pool5
I0402 00:38:12.596902 8318 net.cpp:423] pool5 <- conv5
I0402 00:38:12.596912 8318 net.cpp:378] pool5 -> pool5
I0402 00:38:12.596925 8318 net.cpp:120] Setting up pool5
I0402 00:38:12.596945 8318 net.cpp:127] Top shape: 10 256 6 6 (92160)
I0402 00:38:12.596954 8318 layer_factory.hpp:74] Creating layer fc6
I0402 00:38:12.596966 8318 net.cpp:90] Creating Layer fc6
I0402 00:38:12.596976 8318 net.cpp:423] fc6 <- pool5
I0402 00:38:12.596985 8318 net.cpp:378] fc6 -> fc6
I0402 00:38:12.596998 8318 net.cpp:120] Setting up fc6
I0402 00:38:12.643108 8318 net.cpp:127] Top shape: 10 4096 (40960)
I0402 00:38:12.643144 8318 layer_factory.hpp:74] Creating layer relu6
I0402 00:38:12.643163 8318 net.cpp:90] Creating Layer relu6
I0402 00:38:12.643172 8318 net.cpp:423] relu6 <- fc6
I0402 00:38:12.643184 8318 net.cpp:367] relu6 -> fc6 (in-place)
I0402 00:38:12.643196 8318 net.cpp:120] Setting up relu6
I0402 00:38:12.643208 8318 net.cpp:127] Top shape: 10 4096 (40960)
I0402 00:38:12.643215 8318 layer_factory.hpp:74] Creating layer drop6
I0402 00:38:12.643235 8318 net.cpp:90] Creating Layer drop6
I0402 00:38:12.643244 8318 net.cpp:423] drop6 <- fc6
I0402 00:38:12.643254 8318 net.cpp:367] drop6 -> fc6 (in-place)
I0402 00:38:12.643265 8318 net.cpp:120] Setting up drop6
I0402 00:38:12.643287 8318 net.cpp:127] Top shape: 10 4096 (40960)
I0402 00:38:12.643296 8318 layer_factory.hpp:74] Creating layer fc7
I0402 00:38:12.643307 8318 net.cpp:90] Creating Layer fc7
I0402 00:38:12.643317 8318 net.cpp:423] fc7 <- fc6
I0402 00:38:12.643327 8318 net.cpp:378] fc7 -> fc7
I0402 00:38:12.643339 8318 net.cpp:120] Setting up fc7
I0402 00:38:12.664165 8318 net.cpp:127] Top shape: 10 4096 (40960)
I0402 00:38:12.664199 8318 layer_factory.hpp:74] Creating layer relu7
I0402 00:38:12.664214 8318 net.cpp:90] Creating Layer relu7
I0402 00:38:12.664224 8318 net.cpp:423] relu7 <- fc7
I0402 00:38:12.664237 8318 net.cpp:367] relu7 -> fc7 (in-place)
I0402 00:38:12.664257 8318 net.cpp:120] Setting up relu7
I0402 00:38:12.664266 8318 net.cpp:127] Top shape: 10 4096 (40960)
I0402 00:38:12.664275 8318 layer_factory.hpp:74] Creating layer drop7
I0402 00:38:12.664286 8318 net.cpp:90] Creating Layer drop7
I0402 00:38:12.664294 8318 net.cpp:423] drop7 <- fc7
I0402 00:38:12.664304 8318 net.cpp:367] drop7 -> fc7 (in-place)
I0402 00:38:12.664315 8318 net.cpp:120] Setting up drop7
I0402 00:38:12.664329 8318 net.cpp:127] Top shape: 10 4096 (40960)
I0402 00:38:12.664336 8318 layer_factory.hpp:74] Creating layer fc8
I0402 00:38:12.664348 8318 net.cpp:90] Creating Layer fc8
I0402 00:38:12.664360 8318 net.cpp:423] fc8 <- fc7
I0402 00:38:12.664369 8318 net.cpp:378] fc8 -> fc8
I0402 00:38:12.664381 8318 net.cpp:120] Setting up fc8
I0402 00:38:12.669795 8318 net.cpp:127] Top shape: 10 1000 (10000)
I0402 00:38:12.669828 8318 layer_factory.hpp:74] Creating layer prob
I0402 00:38:12.669843 8318 net.cpp:90] Creating Layer prob
I0402 00:38:12.669853 8318 net.cpp:423] prob <- fc8
I0402 00:38:12.669865 8318 net.cpp:378] prob -> prob
I0402 00:38:12.669879 8318 net.cpp:120] Setting up prob
I0402 00:38:12.669960 8318 net.cpp:127] Top shape: 10 1000 (10000)
I0402 00:38:12.669973 8318 net.cpp:197] prob does not need backward computation.
I0402 00:38:12.669983 8318 net.cpp:197] fc8 does not need backward computation.
I0402 00:38:12.669992 8318 net.cpp:197] drop7 does not need backward computation.
I0402 00:38:12.670001 8318 net.cpp:197] relu7 does not need backward computation.
I0402 00:38:12.670008 8318 net.cpp:197] fc7 does not need backward computation.
I0402 00:38:12.670017 8318 net.cpp:197] drop6 does not need backward computation.
I0402 00:38:12.670025 8318 net.cpp:197] relu6 does not need backward computation.
I0402 00:38:12.670033 8318 net.cpp:197] fc6 does not need backward computation.
I0402 00:38:12.670042 8318 net.cpp:197] pool5 does not need backward computation.
I0402 00:38:12.670050 8318 net.cpp:197] relu5 does not need backward computation.
I0402 00:38:12.670058 8318 net.cpp:197] conv5 does not need backward computation.
I0402 00:38:12.670066 8318 net.cpp:197] relu4 does not need backward computation.
I0402 00:38:12.670075 8318 net.cpp:197] conv4 does not need backward computation.
I0402 00:38:12.670083 8318 net.cpp:197] relu3 does not need backward computation.
I0402 00:38:12.670091 8318 net.cpp:197] conv3 does not need backward computation.
I0402 00:38:12.670100 8318 net.cpp:197] norm2 does not need backward computation.
I0402 00:38:12.670109 8318 net.cpp:197] pool2 does not need backward computation.
I0402 00:38:12.670117 8318 net.cpp:197] relu2 does not need backward computation.
I0402 00:38:12.670125 8318 net.cpp:197] conv2 does not need backward computation.
I0402 00:38:12.670135 8318 net.cpp:197] norm1 does not need backward computation.
I0402 00:38:12.670142 8318 net.cpp:197] pool1 does not need backward computation.
I0402 00:38:12.670151 8318 net.cpp:197] relu1 does not need backward computation.
I0402 00:38:12.670159 8318 net.cpp:197] conv1 does not need backward computation.
I0402 00:38:12.670167 8318 net.cpp:238] This network produces output prob
I0402 00:38:12.670188 8318 net.cpp:495] Collecting Learning Rate and Weight Decay.
I0402 00:38:12.670202 8318 net.cpp:250] Network initialization done.
I0402 00:38:12.670212 8318 net.cpp:251] Memory required for data: 62497920
F0402 00:38:12.982095 8318 upgrade_proto.cpp:956] Check failed: ReadProtoFromBinaryFile(param_file, param) Failed to parse NetParameter file: ./python/../models/bvlc_reference_caffenet/bvlc_reference_caffenet.caffemodel
*** Check failure stack trace: ***
Aborted (core dumped)
nathan@10:
/OpenCL-caffe$

How can I run caffe on intel MIC?

在clBuildProgram()的-options 参数,您使用了+x clc++,但是这个好像只能在AMD的GPU中使用,我想用intel的MIC加速,请问怎么修改?

it support opencl1.1 device?

i want to use zhe opencl caffe in android ,but only support opencl 1.1,can i use it but only chang little function?

Can not build with OpenBlas

Ok, let me open an issue myself. I heard from an internal caffe users that the code won't build correctly with OpenBlas. It keeps asking for ATLAS. It may be a caffe issue, not related to OpenCL. But we need to look into this in case some user prefers to use OpenBLAS.

system spec

I started to set up a system from a scratch and now I am having a bit of a problem setting up clBLAS like in which order should I install different dependencies, which versions are proffered over the others etc. It compiles, but then when I run test-functional or test-correctness it does not go far. So I would be grateful if somebody who has clBLAS running could run a couple of commands below and provide me with an output. It basically gives the version of drivers, system, libraries and their location.

I am trying to set it up on lubuntu 15.04 with Radeon 290. Or maybe some other system is more friendly with AMD's drivers?

uname -a

env | grep -i 'LD_\|AMD\|BLAS\|OPENCL\|LAPACK\|/CL'

dpkg -l fglrx fglrx-core fglrx-dev fglrx-amdcccle

lsmod | grep fglrx

fglrxinfo

clinfo

/usr/bin/g++ --version

/usr/bin/gcc --version

#assuming clBLAS installation path
file /opt/clBLAS/bin/test-functional | awk -F: '$2 ~ "dynamically linked" {print $1}' | xargs ldd

ldconfig -p | grep -i 'OPENCL\|amd\|blas\|lapack'  

ldconfig -p | grep -i 'OPENCL\|amd\|blas\|lapack'     | grep "=> /" | awk '{print $4}'  | xargs ls -la

ldconfig -p | grep -i 'OPENCL\|amd\|blas\|lapack'     | grep "=> /" | awk '{print $4}'  | xargs ls -la | grep " -> " | awk '{print $11}' | xargs locate

# in case one uses alternatives and not soft links
update-alternatives --display libOpenCL.so
update-alternatives --display libOpenCL.so.1

EDIT: I had OpenCL-caffe and clBLAS repos opened in two tabs and I posted this in the wrong one. My mistake, sorry for that.

`const Dtype* A, const int offA` should be wrapped as an object

Many calls in caffe like:

something(Dtype *A, ...);

have become in caffe fork:

somehting(Dtype* A, const int offA);

I reckon these should be combined into a single object you pass around:

something(DBuffer *A)

where:

class DBuffer {
public:
    Dtype *array;
    int offset;
};

(I reckon that should probably be a long long, or preferably int64_t, by the way, rather than an int, but I confess I use ints mostly too, since I havent hit buffers greater than 8GB or so. But you will... :-P)

Train on cluster

Hi, everyone
Does this version of caffe support training on a cluster? If it does, are there any examples for this kind of training?

error while using matcaffe

Hi
When I use

$ make matcaffe
I recieve the following error

MEX matlab/+caffe/private/caffe_.cpp
Warning: Legacy MEX infrastructure is provided for compatibility; it will be removed in a future version 
of MATLAB. For more information, consult the MEX release notes http://www.mathworks.com/help/matlab/release-notes.html.

/usr/bin/ld: skipping incompatible /opt/AMDAPPSDK-3.0/lib/x86/libOpenCL.so when searching for 
-lOpenCL

/usr/bin/ld: cannot find -lOpenCL

/usr/bin/ld: cannot find -lclBLAS

collect2: error: ld returned 1 exit status

mex: link of ' "matlab/+caffe/private/caffe_.mexa64"' failed.


make: *** [matlab/+caffe/private/caffe_.mexa64] Error 255

I really appreciate any help you can provide

test failded on W9100 GPU

Hi, I am using W9100 on a Ubuntu14.04.03 machine, the following tests failed after a successful make:

[----------] Global test environment tear-down
[==========] 1297 tests from 201 test cases ran. (667076 ms total)
[ PASSED ] 1293 tests.
[ FAILED ] 4 tests, listed below:
[ FAILED ] SGDSolverTest/2.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice
[ FAILED ] SGDSolverTest/3.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice
[ FAILED ] NesterovSolverTest/2.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice
[ FAILED ] NesterovSolverTest/3.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice

The driver version is 15.201, APPSDK is v2.9-1.599.381. clBLAS is the latest from github.

Any idea how to fix this issue ?

Make error

Hello, I'm trying to get the open-cl caffe version running, but I'm running into troubles while doing "make all". This is the error I get. Does anyone now what I should do?
(I am trying to install opencl-caffe in a folder at the same level of the ordinary caffe's folder; but I suppose these should not conflict, since they seem to be independent?)

Thanks,
Daniele

AR -o .build_release/lib/libcaffe.a
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cuda_dev_ptr.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(conv_layer_fft.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_conv_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_lcn_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_lrn_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_pooling_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_relu_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_sigmoid_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_softmax_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_tanh_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(ocl_dev_ptr.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(fft.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_conv_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_lcn_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_lrn_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_pooling_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_relu_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_sigmoid_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_softmax_layer.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: .build_release/lib/libcaffe.a(cudnn_tanh_layer.o) has no symbols
LD -o .build_release/lib/libcaffe.so.1.0.0-rc3
clang: warning: argument unused during compilation: '-pthread'
ld: can't map file, errno=22 file '/usr/local/cuda/lib/stubs' for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [.build_release/lib/libcaffe.so.1.0.0-rc3] Error 1
MBPdiDaniele2:caffe-opencl danieleghisi$ 

Test faild,How can I sovle this problem

[100%] Built target test.testbin
Scanning dependencies of target runtest
Current device id: 0
Err: Failed to build program
PlF�Note: Google Test filter = -GPU
Note: Randomizing tests' orders with a seed of 13292 .
[==========] Running 1297 tests from 201 test cases.
[----------] Global test environment set-up.
[----------] 2 tests from SigmoidCrossEntropyLossLayerTest/1, where TypeParam = caffe::CPUDevice
[ RUN ] SigmoidCrossEntropyLossLayerTest/1.TestSigmoidCrossEntropyLoss
Err: Failed to build program
�*** Aborted at 1456991316 (unix time) try "date -d @1456991316" if you are using GNU date ***
PC: @ 0x0 (unknown)
*** SIGSEGV (@0x0) received by PID 15511 (TID 0x2b72f8e66c00) from PID 0; stack trace: ***
@ 0x2b72f953c340 (unknown)
@ 0x0 (unknown)
Segmentation fault (core dumped)
make[3]: *** [src/caffe/test/CMakeFiles/runtest] error 139
make[2]: *** [src/caffe/test/CMakeFiles/runtest.dir/all] error 2
make[1]: *** [src/caffe/test/CMakeFiles/runtest.dir/rule] error 2
make: *** [runtest] error 2
huyanning@huyanning-PC:~/OpenCL-caffe-stable/build$

Could not create logging file: No such file or directory

After downloading and configuring the mnist example for caffe, it i'm having an issue training.

When I run

./examples/mnist/train_lenet.sh

It seems to fail to make a log file multiple times, but then after that it's off to the races and it runs the remainder of the training script to completion. This is the first part of the output:

Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165532.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165533.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165533.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165539.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165539.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165546.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165546.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165546.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165546.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165546.10424!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165546.10424!Forwarding mnist, time 2.000000 ms
Forwarding label_mnist_1_split, time 0.000000 ms
Forwarding conv1, time 270.000000 ms
Forwarding pool1, time 0.000000 ms
....

After the script runs I end up with lenet_iter_10000.caffemodel and lenet_iter_10000.solverstate, but when I use the command:

./build/tools/caffe test examples/mnist/lenet_train_test.prototxt -weights examples/mnist/lenet_iter_10000.caffemodel -gpu 3 -iterations 100

I get this output:

caffe: command line brew
usage: caffe

commands:
train train or finetune a model
test score a model
device_query show GPU diagnostic information
time benchmark model execution time

Flags from //home/nathan/OpenCL-caffe/tools/caffe.cpp:
-gpu (Run in GPU mode on given device ID.) type: int32 default: -1
currently: 3
-iterations (The number of iterations to run.) type: int32 default: 50
currently: 100
-model (The model definition protocol buffer text file..) type: string
default: ""
-snapshot (Optional; the snapshot solver state to resume training.)
type: string default: ""
-solver (The solver definition protocol buffer text file.) type: string
default: ""
-weights (Optional; the pretrained weights to initialize finetuning. Cannot
be set simultaneously with snapshot.) type: string default: ""
currently: "examples/mnist/lenet_iter_10000.caffemodel"
Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20160113-165918.10446!

So it seems like unless I fix this logging issue I won't be able to tell if caffe is actually working or not, because I can't find or see the output of the results of the testing or training anywhere.

No GPU Device

Clearly I have AMD GPU:

zhoub@zhoub:~$ lspci
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Oland [Radeon HD 8570 / R7 240 OEM]
01:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Cape Verde/Pitcairn HDMI Audio [Radeon HD 7700/7800 Series]

But it shows that:

xx@xx:~/OpenCL-caffe/build$ make runtest
[ 1%] Built target proto
[ 55%] Built target caffe
[ 55%] Built target gtest
[100%] Built target test.testbin
Current device id: 0
F1006 20:10:38.865067 11580 device.cpp:75] Err: No GPU devices
*** Check failure stack trace: ***
@ 0x2b5fc1facdaa (unknown)
@ 0x2b5fc1facce4 (unknown)
@ 0x2b5fc1fac6e6 (unknown)
@ 0x2b5fc1faf687 (unknown)
@ 0x2b5fc1941c44 caffe::Device::Init()
@ 0x6f4e48 main
@ 0x2b5fc3cc5ec5 (unknown)
@ 0x6f7d12 (unknown)
@ (nil) (unknown)
Aborted (core dumped)
make[3]: *** [src/caffe/test/CMakeFiles/runtest] Error 134
make[2]: *** [src/caffe/test/CMakeFiles/runtest.dir/all] Error 2
make[1]: *** [src/caffe/test/CMakeFiles/runtest.dir/rule] Error 2
make: *** [runtest] Error 2

make caffe project run with OpenCL

I tried to use the following project
https://github.com/kevinlin311tw/caffe-cvprw15
when i use cmake command it prompt the following error

CMake Error at /usr/share/cmake-2.8/Modules/FindCUDA.cmake:548 (message):
Specify CUDA_TOOLKIT_ROOT_DIR

I also tried to copy all files in OpenCL-caffe project into the project and build I recive the following error
‘test’ is not a member of ‘caffe::Caffe’ Caffe::set_phase(Caffe:test)

is there a way to make it run without cuda on AMD GPU?

Installing linking to clBlas

I'm trying to build OpenCL-caffe and I'm running into a problem linking clBLAS:

[ 59%] Linking CXX executable caffe
../lib/libcaffe.so: undefined reference to `cblas_sgemv'
...

I've found some people online having a similar issue with regular Caffe, but this is a bit different because I want to use clBLAS for this version and not some other BLAS correct?

Is there something I need to put in the configuration for it to find the clBLAS?

I exported the folder where I compiled clBLAS as CLBLAS_ROOT. Is there something else I need to do for it to build?

Some outputs that might be useful:

-- Build files have been written to: /home/nathan/OpenCL-caffe/build
nathan@amdRig:/OpenCL-caffe/build$ make clean
nathan@amdRig:
/OpenCL-caffe/build$ sudo cmake ..
-- Boost version: 1.46.1
-- Found the following Boost libraries:
-- system
-- thread
-- Found gflags (include: /usr/local/include, library: /usr/local/lib/libgflags.a)
-- Found glog (include: /usr/local/include, library: /usr/local/lib/libglog.so)
-- Found PROTOBUF Compiler: /usr/bin/protoc
-- Found lmdb (include: /usr/local/include, library: /usr/local/lib/liblmdb.so)
-- Found LevelDB (include: /usr/local/include, library: /usr/local/lib/libleveldb.so)
-- Found Snappy (include: /usr/include, library: /usr/lib/libsnappy.so)
-- Found OpenCL (include: /opt/AMDAPP/include, library: /usr/lib/libOpenCL.so)
-- Found clBLAS (include: /usr/local/include, library: /usr/local/lib64/libclBLAS.so)
-- OpenCV found (/usr/share/OpenCV)
-- NumPy ver. 1.7.1 found (include: /usr/local/lib/python2.7/dist-packages/numpy/core/include)
-- Boost version: 1.46.1
-- Found the following Boost libraries:
-- python

-- Detected Doxygen OUTPUT_DIRECTORY: ./doxygen/

-- ******************* Caffe Configuration Summary *******************
-- General:
-- Version : (Caffe doesn't declare its version in headers)
-- Git : aaa1c2c-dirty
-- System : Linux
-- C++ compiler : /usr/bin/c++
-- Release CXX flags : -O3 -DNDEBUG -fPIC -Wall -Wno-sign-compare -Wno-uninitialized
-- Debug CXX flags : -g -fPIC -Wall -Wno-sign-compare -Wno-uninitialized

-- Build type : Release

-- BUILD_SHARED_LIBS : ON
-- BUILD_python : ON
-- BUILD_matlab : OFF
-- BUILD_docs : ON

-- CPU_ONLY : OFF

-- Dependencies:
-- BLAS : Yes (clBLAS)
-- Boost : Yes (ver. 1.46)
-- glog : Yes
-- gflags : Yes
-- protobuf : Yes (ver. 2.4.1)
-- lmdb : Yes (ver. 0.9.70)
-- Snappy : Yes (ver. 1.0.4)
-- LevelDB : Yes (ver. 1.9)
-- OpenCV : Yes (ver. 2.3.1)
-- OpenCL : Yes

-- clBLAS : Yes

-- Python:
-- Interpreter : /usr/bin/python2.7 (ver. 2.7.3)
-- Libraries : /usr/lib/libpython2.7.so (ver 2.7.3)

-- NumPy : /usr/local/lib/python2.7/dist-packages/numpy/core/include (ver 1.7.1)

-- Documentaion:
-- Doxygen : /usr/bin/doxygen (1.7.6.1)

-- config_file : /home/nathan/OpenCL-caffe/.Doxyfile

-- Install:

-- Install path : //home/nathan/OpenCL-caffe/build/install

-- Configuring done
CMake Warning at src/caffe/CMakeLists.txt:20 (add_library):
Cannot generate a safe linker search path for target caffe because files in
some directories may conflict with libraries in implicit directories:

link library [libprotobuf.so] in /usr/lib may be hidden by files in:
  /usr/local/lib

Some of these libraries may not be found correctly.

CMake Warning at src/caffe/CMakeLists.txt:20 (add_library):
Cannot generate a safe runtime search path for target caffe because files
in some directories may conflict with libraries in implicit directories:

runtime library [libprotobuf.so.7] in /usr/lib may be hidden by files in:
  /usr/local/lib

....

....
[ 53%] Building CXX object src/caffe/CMakeFiles/caffe.dir/util/insert_splits.cpp.o
[ 55%] Building CXX object src/caffe/CMakeFiles/caffe.dir/util/upgrade_proto.cpp.o
[ 55%] Building CXX object src/caffe/CMakeFiles/caffe.dir/util/ocl_wrapper.cpp.o
[ 56%] Building CXX object src/caffe/CMakeFiles/caffe.dir/internal_thread.cpp.o
[ 56%] Linking CXX shared library ../../lib/libcaffe.so
[ 58%] Built target caffe
Scanning dependencies of target caffe.bin
[ 59%] Building CXX object tools/CMakeFiles/caffe.bin.dir/caffe.cpp.o
[ 59%] Linking CXX executable caffe
../lib/libcaffe.so: undefined reference to cblas_sgemv' ../lib/libcaffe.so: undefined reference tocblas_dgemm'
../lib/libcaffe.so: undefined reference to cblas_sscal' ../lib/libcaffe.so: undefined reference tocblas_dgemv'
../lib/libcaffe.so: undefined reference to cblas_saxpy' ../lib/libcaffe.so: undefined reference tocblas_ddot'
../lib/libcaffe.so: undefined reference to cblas_dasum' ../lib/libcaffe.so: undefined reference tocblas_sgemm'
../lib/libcaffe.so: undefined reference to cblas_dscal' ../lib/libcaffe.so: undefined reference tocblas_scopy'
../lib/libcaffe.so: undefined reference to cblas_sasum' ../lib/libcaffe.so: undefined reference tocblas_daxpy'
../lib/libcaffe.so: undefined reference to cblas_dcopy' ../lib/libcaffe.so: undefined reference tocblas_sdot'
collect2: ld returned 1 exit status

multiarray import error

It seems that it can not import multiarray for numpy with me. However, importing numpy in a regular python script throws no error.
That's what I get when running cmake ..

-- Boost version: 1.60.0
-- Found the following Boost libraries:
--   system
--   thread
--   chrono
--   date_time
--   atomic
-- Found gflags  (include: /usr/include, library: /usr/lib64/libgflags.so)
-- Found glog    (include: /usr/include, library: /usr/lib64/libglog.so)
-- Found PROTOBUF Compiler: /usr/bin/protoc
-- Found lmdb    (include: /usr/include, library: /usr/lib64/liblmdb.so)
-- Found LevelDB (include: /usr/include, library: /usr/lib64/libleveldb.so)
-- Found Snappy  (include: /usr/include, library: /usr/lib64/libsnappy.so)
-- Found OpenCL  (include: /usr/include, library: /lib64/libOpenCL.so)
-- Found clBLAS  (include: /opt/clBLAS/include, library: /usr/lib64/libclBLAS.so)
-- OpenCV found (/usr/local/share/OpenCV)
-- Found OpenBLAS libraries: /opt/OpenBLAS/lib/libopenblas.so
-- Found OpenBLAS include: /usr/include
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/lib/python3.5/site-packages/numpy/__init__.py", line 180, in <module>
    from . import add_newdocs
  File "/usr/lib/python3.5/site-packages/numpy/add_newdocs.py", line 13, in <module>
    from numpy.lib import add_newdoc
  File "/usr/lib/python3.5/site-packages/numpy/lib/__init__.py", line 8, in <module>
    from .type_check import *
  File "/usr/lib/python3.5/site-packages/numpy/lib/type_check.py", line 11, in <module>
    import numpy.core.numeric as _nx
  File "/usr/lib/python3.5/site-packages/numpy/core/__init__.py", line 14, in <module>
    from . import multiarray
ImportError: cannot import name multiarray
-- Could NOT find NumPy (missing:  NUMPY_INCLUDE_DIR NUMPY_VERSION) (Required is at least version "1.7.1")
-- Boost version: 1.60.0
-- Found the following Boost libraries:
--   python
-- Could NOT find Doxygen (missing:  DOXYGEN_EXECUTABLE) 
-- Python interface is disabled or not all required dependecies found. Building without it...
-- 
-- ******************* Caffe Configuration Summary *******************
-- General:
--   Version           :   <TODO> (Caffe doesn't declare its version in headers)
--   Git               :   aaa1c2c
--   System            :   Linux
--   C++ compiler      :   /usr/bin/c++
--   Release CXX flags :   -O3 -DNDEBUG -fPIC -Wall -Wno-sign-compare -Wno-uninitialized
--   Debug CXX flags   :   -g -fPIC -Wall -Wno-sign-compare -Wno-uninitialized
--   Build type        :   Release
-- 
--   BUILD_SHARED_LIBS :   ON
--   BUILD_python      :   ON
--   BUILD_matlab      :   OFF
--   BUILD_docs        :   ON
--   CPU_ONLY          :   OFF
-- 
-- Dependencies:
--   BLAS              :   Yes (open)
--   Boost             :   Yes (ver. 1.60)
--   glog              :   Yes
--   gflags            :   Yes
--   protobuf          :   Yes (ver. 2.6.1)
--   lmdb              :   Yes (ver. 0.9.18)
--   Snappy            :   Yes (ver. 1.1.3)
--   LevelDB           :   Yes (ver. 1.18)
--   OpenCV            :   Yes (ver. 3.1.0)
--   OpenCL            :   Yes
--   clBLAS            :   Yes
-- 
-- Documentaion:
--   Doxygen           :   No
--   config_file       :   
-- 
-- Install:
--   Install path      :   /home/ebadawy/git/OpenCL-caffe/build/install
-- 
-- Configuring done
CMake Warning (dev) at CMakeLists.txt:67 (add_dependencies):
  Policy CMP0046 is not set: Error on non-existent dependency in
  add_dependencies.  Run "cmake --help-policy CMP0046" for policy details.
  Use the cmake_policy command to set the policy and suppress this warning.

  The dependency target "pycaffe" of target "pytest" does not exist.
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Generating done
-- Build files have been written to: /home/ebadawy/git/OpenCL-caffe/build

Variable casing inconsistent with caffe

Please ensure that you use the same coding standards as caffe, unless there is a really good reason. You are working on someone else's project (ie caffe), so I reckon you should follow hteir standards, and not amd internal standards. Example, the case of X in the following method delcaration has changed:

caffe:

void caffe_gpu_add_scalar(const int N, const Dtype alpha, Dtype *X);

amd fork:

void caffe_cpu_scale(const int n, const Dtype alpha, const Dtype *x, Dtype* y);

(I admit these functions have two differnet names, and I'm not quite sure why that is, might be an inconsistency in itself, but you can see that caffe uses X whereas the amd fork is using x, in lowercase)

[HS] how to boost the HSA use.

Hi AMD developers, I am a fan of you and I want to share to you an idea for boost the HSA use and de facto the apus sell.

I think that as you do with openCL, you should implement full HSA support and use on the mainstream free softwares like Firefox, chromium, libreoffice, blender, Servo (the layout engine of the future), steamOS, gimp,VLC, etc :)

test_gradient_based_solver fails

I have a problem with make runtest failing on SGDSolver and NesterovSolver. I looked at the git repository of BVLC/caffe (BVLC/caffe#3109) and there somebody was referring to a problem coming from the same file test_gradient_based_solver.cpp. In the comments people were writing that it was caused by multiple GPUs present in the system or the fact that Intel MKL's float point operations (such as matrix multiplication) are non-deterministic by default.

Regarding my system, I am running Caffe cloned from github on 22nd of December 2015 on Ubuntu 15.10 with Radeon R9 290 (4GB) and i7-4770K CPU @ 3.50GHz, AMDAPPSDK-3.0. Four tests failed.

If anybody knows how to make them pass or what causes the problem it would be great.

$ fglrxinfo
display: :0  screen: 0
OpenGL vendor string: Advanced Micro Devices, Inc.
OpenGL renderer string: AMD Radeon R9 200 Series
OpenGL version string: 4.5.13399 Compatibility Profile Context 15.201.1151
/OpenCL-caffe/build$ make runtest
[  1%] Built target proto
[ 55%] Built target caffe
[ 55%] Built target gtest
[100%] Built target test.testbin
Current device id: 0
Note: Google Test filter = -*GPU*
Note: Randomizing tests' orders with a seed of 3162 .
...................
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00015804916620254517, which exceeds error_margin, where
expected_param evaluates to 0.013755172491073608,
accum_param evaluates to 0.013913221657276154, and
error_margin evaluates to 0.00013755173131357878.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00015809759497642517, which exceeds error_margin, where
expected_param evaluates to 0.00093255564570426941,
accum_param evaluates to 0.0010906532406806946, and
error_margin evaluates to 9.3255566753214225e-06.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00015811249613761902, which exceeds error_margin, where
expected_param evaluates to -0.010214578360319138,
accum_param evaluates to -0.010056465864181519, and
error_margin evaluates to 0.00010056465544039384.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00015810877084732056, which exceeds error_margin, where
expected_param evaluates to -0.0109538733959198,
accum_param evaluates to -0.010795764625072479, and
error_margin evaluates to 0.0001079576468328014.
src/caffe/test/test_gradient_based_solver.cpp:315: Failure
The difference between expected_bias and accum_bias is 0.020383119583129883, which exceeds error_margin, where
expected_bias evaluates to -1.2308368682861328,
accum_bias evaluates to -1.2512199878692627, and
error_margin evaluates to 0.01230836845934391.
[  FAILED  ] SGDSolverTest/2.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<float> (72 ms)
.....................
src/caffe/test/test_gradient_based_solver.cpp:315: Failure
The difference between expected_bias and accum_bias is 16.290860759216979, which exceeds error_margin, where
expected_bias evaluates to 30.680854565170151,
accum_bias evaluates to 14.389993805953171, and
error_margin evaluates to 0.14389993805953172.
[  FAILED  ] NesterovSolverTest/3.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<double> (12 ms)
.....................
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.0009438430034522105, which exceeds error_margin, where
expected_param evaluates to -0.0075809667410185466,
accum_param evaluates to -0.0085248097444707571, and
error_margin evaluates to 7.5809667410185473e-05.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345218275, which exceeds error_margin, where
expected_param evaluates to 0.073903926620193378,
accum_param evaluates to 0.072960083616741195, and
error_margin evaluates to 0.00072960083616741196.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345218275, which exceeds error_margin, where
expected_param evaluates to 0.057955563277547251,
accum_param evaluates to 0.057011720274095068, and
error_margin evaluates to 0.00057011720274095074.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345218275, which exceeds error_margin, where
expected_param evaluates to -0.040239520053002617,
accum_param evaluates to -0.0411833630564548, and
error_margin evaluates to 0.00040239520053002618.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345230765, which exceeds error_margin, where
expected_param evaluates to -0.054015869066066119,
accum_param evaluates to -0.054959712069518427, and
error_margin evaluates to 0.00054015869066066115.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345244643, which exceeds error_margin, where
expected_param evaluates to -0.035164120485524253,
accum_param evaluates to -0.036107963488976699, and
error_margin evaluates to 0.00035164120485524255.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345243255, which exceeds error_margin, where
expected_param evaluates to 0.023867411055095877,
accum_param evaluates to 0.022923568051643445, and
error_margin evaluates to 0.00022923568051643446.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345229377, which exceeds error_margin, where
expected_param evaluates to -0.023262755953808445,
accum_param evaluates to -0.024206598957260739, and
error_margin evaluates to 0.00023262755953808447.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.0009438430034522105, which exceeds error_margin, where
expected_param evaluates to 0.022473440985742582,
accum_param evaluates to 0.021529597982290372, and
error_margin evaluates to 0.00021529597982290373.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345204397, which exceeds error_margin, where
expected_param evaluates to -0.094111263940639428,
accum_param evaluates to -0.095055106944091472, and
error_margin evaluates to 0.00094111263940639428.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345215499, which exceeds error_margin, where
expected_param evaluates to -0.052540014489286579,
accum_param evaluates to -0.053483857492738734, and
error_margin evaluates to 0.0005254001448928658.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.0009438430034522105, which exceeds error_margin, where
expected_param evaluates to -0.074735299450877965,
accum_param evaluates to -0.075679142454330176, and
error_margin evaluates to 0.00074735299450877965.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.0009438430034522105, which exceeds error_margin, where
expected_param evaluates to -0.032339898640959791,
accum_param evaluates to -0.033283741644412002, and
error_margin evaluates to 0.00032339898640959791.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345218275, which exceeds error_margin, where
expected_param evaluates to 0.089805274972429433,
accum_param evaluates to 0.08886143196897725, and
error_margin evaluates to 0.00088861431968977251.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345243255, which exceeds error_margin, where
expected_param evaluates to 0.079982388023672302,
accum_param evaluates to 0.079038545020219869, and
error_margin evaluates to 0.00079038545020219866.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345229377, which exceeds error_margin, where
expected_param evaluates to -0.046441101129402113,
accum_param evaluates to -0.047384944132854406, and
error_margin evaluates to 0.00046441101129402113.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345215499, which exceeds error_margin, where
expected_param evaluates to 0.073243776031034963,
accum_param evaluates to 0.072299933027582808, and
error_margin evaluates to 0.00072299933027582806.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345218275, which exceeds error_margin, where
expected_param evaluates to 0.036783959999803301,
accum_param evaluates to 0.035840116996351118, and
error_margin evaluates to 0.0003584011699635112.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345218275, which exceeds error_margin, where
expected_param evaluates to 0.074800868345276994,
accum_param evaluates to 0.073857025341824811, and
error_margin evaluates to 0.00073857025341824811.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345229377, which exceeds error_margin, where
expected_param evaluates to -0.087903557731515064,
accum_param evaluates to -0.088847400734967358, and
error_margin evaluates to 0.00087903557731515067.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.0009438430034522105, which exceeds error_margin, where
expected_param evaluates to -0.09313550033631654,
accum_param evaluates to -0.094079343339768751, and
error_margin evaluates to 0.00093135500336316546.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345232153, which exceeds error_margin, where
expected_param evaluates to 0.0023059492350265554,
accum_param evaluates to 0.0013621062315742338, and
error_margin evaluates to 1.3621062315742339e-05.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.0009438430034522105, which exceeds error_margin, where
expected_param evaluates to 0.018183528710792568,
accum_param evaluates to 0.017239685707340358, and
error_margin evaluates to 0.00017239685707340358.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345237704, which exceeds error_margin, where
expected_param evaluates to 0.040265922015119665,
accum_param evaluates to 0.039322079011667288, and
error_margin evaluates to 0.00039322079011667289.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.00094384300345218275, which exceeds error_margin, where
expected_param evaluates to 0.091959157638004163,
accum_param evaluates to 0.09101531463455198, and
error_margin evaluates to 0.00091015314634551982.
src/caffe/test/test_gradient_based_solver.cpp:315: Failure
The difference between expected_bias and accum_bias is 0.11647201251983841, which exceeds error_margin, where
expected_bias evaluates to -1.9010368863451557,
accum_bias evaluates to -1.7845648738253173, and
error_margin evaluates to 0.017845648738253173.
[  FAILED  ] SGDSolverTest/3.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<double> (16 ms)
.....................
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.057497024536132812, which exceeds error_margin, where
expected_param evaluates to -5.7565555572509766,
accum_param evaluates to -5.6990585327148438, and
error_margin evaluates to 0.056990586221218109.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.057497501373291016, which exceeds error_margin, where
expected_param evaluates to -5.6071248054504395,
accum_param evaluates to -5.5496273040771484, and
error_margin evaluates to 0.055496271699666977.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.057498931884765625, which exceeds error_margin, where
expected_param evaluates to -5.7071495056152344,
accum_param evaluates to -5.6496505737304688, and
error_margin evaluates to 0.056496504694223404.
src/caffe/test/test_gradient_based_solver.cpp:308: Failure
The difference between expected_param and accum_param is 0.057498931884765625, which exceeds error_margin, where
expected_param evaluates to -5.3606395721435547,
accum_param evaluates to -5.3031406402587891, and
error_margin evaluates to 0.053031407296657562.
src/caffe/test/test_gradient_based_solver.cpp:315: Failure
The difference between expected_bias and accum_bias is 4.0414938926696777, which exceeds error_margin, where
expected_bias evaluates to -9.2879724502563477,
accum_bias evaluates to -5.2464785575866699, and
error_margin evaluates to 0.052464786916971207.
[  FAILED  ] NesterovSolverTest/2.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<float> (19 ms)
....................
[  FAILED  ] 4 tests, listed below:
[  FAILED  ] SGDSolverTest/2.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<float>
[  FAILED  ] SGDSolverTest/3.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<double>
[  FAILED  ] NesterovSolverTest/2.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<float>
[  FAILED  ] NesterovSolverTest/3.TestLeastSquaresUpdateWithEverythingAccum, where TypeParam = caffe::GPUDevice<double>

Test failed on Macmini (Late 2014)

Hi,
I test the stable version on Macmini (Late 2014) which has an intel card.
The compile goes well except I have to change Cl/cl.h to OpenCl/cl.h.
But there is an error when I run: make runtest
F0121 12:01:47.191191 2019336960 device.cpp:95] Cannot find any dGPU!
*** Check failure stack trace: ***
@ 0x101cd60e2 google::LogMessage::Fail()
@ 0x101cd57e4 google::LogMessage::SendToLog()
@ 0x101cd5d3b google::LogMessage::Flush()
@ 0x101cd9089 google::LogMessageFatal::~LogMessageFatal()
@ 0x101cd63cf google::LogMessageFatal::~LogMessageFatal()
@ 0x1019e34ad caffe::Device::Init()
@ 0x10109dee1 main
@ 0x7fff8b7595c9 start
@ 0x3 (unknown)
/bin/sh: line 1: 62711 Abort trap: 6 /Users/jimmy/Code/Caffe/OpenCL-caffe-stable/build/test/test.testbin --gtest_shuffle --gtest_filter="-GPU"
make[3]: *** [src/caffe/test/CMakeFiles/runtest] Error 134
make[2]: *** [src/caffe/test/CMakeFiles/runtest.dir/all] Error 2
make[1]: *** [src/caffe/test/CMakeFiles/runtest.dir/rule] Error 2
make: *** [runtest] Error 2
I am not familiar with OpenCL so anyone can give me some suggestions?
Thanks very much.

Jimmy

Error running tests: "Don't understand command line argument "-x""

When running make runtest, get error Don't understand command line argument "-x":

[  1%] Built target proto
[ 80%] Built target caffe
[ 80%] Built target caffe.bin
[ 81%] [ 81%] Built target compute_image_mean
Built target device_query
[ 81%] Built target convert_imageset
[ 83%] Built target net_speed_benchmark
[ 85%] [ 85%] [ 86%] Built target extract_features
Built target test_net
Built target finetune_net
[ 88%] Built target train_net
[ 90%] [ 91%] Built target upgrade_net_proto_binary
Built target upgrade_net_proto_text
[ 93%] Built target classification
[ 96%] Built target convert_cifar_data
[ 98%] Built target convert_mnist_data
[100%] [100%] Built target pycaffe
Built target convert_mnist_siamese_data
[  1%] Built target proto
[  1%] Built target gtest
[ 55%] Built target caffe
[100%] Built target test.testbin
libdc1394 error: Failed to initialize libdc1394
Current device id: 0
Err: Failed to build program
Error in processing command line: Don't understand command line argument "-x"!Note: Google Test filter = -*GPU*
Note: Randomizing tests' orders with a seed of 3572 .
[==========] Running 1297 tests from 201 test cases.
[----------] Global test environment set-up.
[----------] 1 test from ProtoTest
[ RUN      ] ProtoTest.TestSerialization
Printing in binary format.

testTest
Printing in text format.
name: "test"
type: "Test"

[       OK ] ProtoTest.TestSerialization (2 ms)
[----------] 1 test from ProtoTest (2 ms total)

[----------] 8 tests from CPUMathFunctionsTest/0, where TypeParam = float
[ RUN      ] CPUMathFunctionsTest/0.TestSgnbit
Err: Failed to build program
Error in processing command line: Don't understand command line argument "-x"!*** Aborted at 1444114004 (unix time) try "date -d @1444114004" if you are using GNU date ***
PC: @                0x0 (unknown)
*** SIGSEGV (@0x0) received by PID 12722 (TID 0x2b6f33170840) from PID 0; stack trace: ***
    @     0x2b6f3384a340 (unknown)
    @                0x0 (unknown)
Segmentation fault (core dumped)

Platform:

  • Ubuntu 14.04 64-bit
  • Amazon EC2 g2.2xlarge instance (NVIDIA K520 GPU)

Build method:

sudo apt-get install -y libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libhdf5-serial-dev protobuf-compiler
sudo apt-get install -y libgflags-dev libgoogle-glog-dev liblmdb-dev
sudo apt-get install -y --no-install-recommends libboost-all-dev
sudo apt-get install -y libatlas-base-dev

git clone https://github.com/amd/OpenCL-caffe.git
cd OpenCL-caffe

export CLBLAS_ROOT=$HOME/torch/install
mkdir build
cd build
cmake .. -DCLBLAS_LIBRARIES=/home/ubuntu/torch/install/lib/libclBLAS.so
make -j 8

Test method:

(
cd build
make runtest
)

Segfault in libamdocl12cl64.so when running tests on R9 270X

Linux Mint 17.3
ASUS R9 270X
fglrx 2:15.200-0ubuntu0.5
AMDAPPSDK-3.0

(gdb) run

Starting program: /home/mint/new/caffe/build/test/test.testbin 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Traceback (most recent call last):
File "/usr/share/gdb/auto-load/usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.19-gdb.py", line 63, in <module>
from libstdcxx.v6.printers import register_libstdcxx_printers
ImportError: No module named 'libstdcxx'
[New Thread 0x7fffe1808700 (LWP 20356)]
Current device id: 0
Program received signal SIGSEGV, Segmentation fault.
0x00007fffd9e7defa in ?? () from /usr/lib/libamdocl12cl64.so

(gdb) bt full

#0 0x00007fffd9e7defa in ?? () from /usr/lib/libamdocl12cl64.so
No symbol table info available.
#1 0x00007fffd9e7e6e8 in ?? () from /usr/lib/libamdocl12cl64.so
No symbol table info available.
#2 0x00007ffff56145ea in __cxa_finalize (d=0x7fffdd006c40) at cxa_finalize.c:56
check = 1314
cxafn = <optimized out>
cxaarg = <optimized out>
f = 0xf07800
funcs = 0xf077d0
#3 0x00007fffd9e52e16 in ?? () from /usr/lib/libamdocl12cl64.so
No symbol table info available.
#4 0x000000000000008a in ?? ()
No symbol table info available.
#5 0x0000000000000000 in ?? ()
No symbol table info available.

Please create a branch pointing to last caffe commit, and create PR onto this

Please create a branch pointing to last caffe commit, and create a PR onto this, ie:

Create branch pointing to last caffe comit:

git checkout ad8d129                   # ad8d129 is last pre-amd caffe commit
git checkout -b master                 # creates a branch called `master` from this commit
git push --set-upstream origin master  # pushes the new master branch to the repository
git checkout dev                       # this last line isnt strictly necessary, but switches back to where you were before

Create pull request from dev onto master:

  • in github, click on 'Pull Requests'
  • click on 'New Pull Request'
  • there are two dropdowns in top left:
    • in left hand dropdown select 'master'
    • in right hand dropdown select 'dev'
  • click on 'create pull request' button

This way, it is easy for us to see the differences.

Wiki page typo

cmake -DCMAKE_INSTALL_PATHATH=/opt/clBLAS2.7 -DOCL_VERSION TRING=2.0 -DCMAKE_BUILD_TYPE=Release -DPRECOMPILE_GEMM_PRECISION_SGEMM:BOOL=ON-DPRECOMPILE_GEMM_TRANS_NN:BOOL=ON -DPRECOMPILE_GEMM_TRANS_NT:BOOL=ON-DPRECOMPILE_GEMM_TRANS_TN:BOOL=ON -DPRECOMPILE_GEMM_TRANS_TT:BOOL=ON ..

should be

cmake -DCMAKE_INSTALL_PATHATH=/opt/clBLAS2.7 -DOCL_VERSIONSTRING=2.0 -DCMAKE_BUILD_TYPE=Release -DPRECOMPILE_GEMM_PRECISION_SGEMM:BOOL=ON-DPRECOMPILE_GEMM_TRANS_NN:BOOL=ON -DPRECOMPILE_GEMM_TRANS_NT:BOOL=ON-DPRECOMPILE_GEMM_TRANS_TN:BOOL=ON -DPRECOMPILE_GEMM_TRANS_TT:BOOL=ON ..

OSX 10.10.5 MacPro 2013 AMD Radeon - FirePro d300 x2

Hello
I want to run Caffe on OSX to use their GPUs. I could build the binaries but these fail when I try to run it. I change the the references to AMDAPPSDK for OpenCL.Framework that come with Yosemite. Exactly when I run caffe I got:
❯ ./caffe device_query
Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20151218-011633.31490!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20151218-011633.31490!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20151218-011633.31490!Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20151218-011633.31490!F1218 01:16:33.235122 1889116928 caffe.cpp:75] Check failed: FLAGS_gpu > -1 (-1 vs. -1) Need a device ID to query.
*** Check failure stack trace: ***
@ 0x109cc920a google::LogMessage::Fail()
@ 0x109cc88eb google::LogMessage::SendToLog()
@ 0x109cc8e59 google::LogMessage::Flush()
@ 0x109ccc1af google::LogMessageFatal::~LogMessageFatal()
@ 0x109cc94f7 google::LogMessageFatal::~LogMessageFatal()
@ 0x1094d180e device_query()
@ 0x1094d6aab main
@ 0x7fff827175c9 start
[1] 31490 abort ./caffe device_query

also I run:
❯ ./caffe device_query 0 ⏎
caffe: command line brew
usage: caffe

commands:
train train or finetune a model
test score a model
device_query show GPU diagnostic information
time benchmark model execution time

Flags from tools/caffe.cpp:
-gpu (Run in GPU mode on given device ID.) type: int32 default: -1
-iterations (The number of iterations to run.) type: int32 default: 50
-model (The model definition protocol buffer text file..) type: string
default: ""
-snapshot (Optional; the snapshot solver state to resume training.)
type: string default: ""
-solver (The solver definition protocol buffer text file.) type: string
default: ""
-weights (Optional; the pretrained weights to initialize finetuning. Cannot
be set simultaneously with snapshot.) type: string default: ""
Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20151218-011644.31508!%

And when I try to run
❯ make runtest
.build_debug/tools/caffe
caffe: command line brew
usage: caffe

commands:
train train or finetune a model
test score a model
device_query show GPU diagnostic information
time benchmark model execution time

Flags from tools/caffe.cpp:
-gpu (Run in GPU mode on given device ID.) type: int32 default: -1
-iterations (The number of iterations to run.) type: int32 default: 50
-model (The model definition protocol buffer text file..) type: string
default: ""
-snapshot (Optional; the snapshot solver state to resume training.)
type: string default: ""
-solver (The solver definition protocol buffer text file.) type: string
default: ""
-weights (Optional; the pretrained weights to initialize finetuning. Cannot
be set simultaneously with snapshot.) type: string default: ""
Could not create logging file: No such file or directory
COULD NOT CREATE A LOGGINGFILE 20151218-011901.31805!.build_debug/test/test_all.testbin 0 --gtest_shuffle
Err: Failed to build program

���Setting to use device 0
Current device id: 0
Err: Failed to build program

���Note: Randomizing tests' orders with a seed of 93179 .
[==========] Running 1339 tests from 207 test cases.
[----------] Global test environment set-up.
[----------] 7 tests from SGDSolverTest/3, where TypeParam = N5caffe9GPUDeviceIdEE
[ RUN ] SGDSolverTest/3.TestLeastSquaresUpdateLROneTenth
Err: Failed to build program
`G�T��*** Aborted at 1450415941 (unix time) try "date -d @1450415941" if you are using GNU date ***
PC: @ 0x7fff8ca34b7f __dynamic_cast
*** SIGSEGV (@0x0) received by PID 31806 (TID 0x7fff7099a300) stack trace: ***
@ 0x7fff8fc76f1a _sigtramp
@ 0x7fff54a9eff0 (unknown)
@ 0x7fff8b266d5a clLogMessagesToStderrAPPLE
@ 0x7fff8b275b0f clCreateKernel
@ 0x111432d3f caffe::SyncedMemory::ocl_setup()
@ 0x11127d313 caffe::SyncedMemory::SyncedMemory()
@ 0x11125fe8d caffe::SyncedMemory::SyncedMemory()
@ 0x111266773 caffe::Blob<>::Reshape()
@ 0x111265fa3 caffe::Blob<>::Reshape()
@ 0x11130229f caffe::DummyDataLayer<>::LayerSetUp()
@ 0x111350131 caffe::Layer<>::SetUp()
@ 0x1113e70f1 caffe::Net<>::Init()
@ 0x1113e56ec caffe::Net<>::Net()
@ 0x1113eb1ad caffe::Net<>::Net()
@ 0x11141c22a caffe::Solver<>::InitTrainNet()
@ 0x11141b483 caffe::Solver<>::Init()
@ 0x11141b14e caffe::Solver<>::Solver()
@ 0x10b2df4cc caffe::SGDSolver<>::SGDSolver()
@ 0x10b30b19d caffe::SGDSolver<>::SGDSolver()
@ 0x10b30b065 caffe::SGDSolverTest<>::InitSolver()
@ 0x10b2df13b caffe::GradientBasedSolverTest<>::InitSolverFromProtoString()
@ 0x10b2e1ffa caffe::GradientBasedSolverTest<>::RunLeastSquaresSolver()
@ 0x10b2eb090 caffe::GradientBasedSolverTest<>::TestLeastSquaresUpdate()
@ 0x10b3117e1 caffe::SGDSolverTest_TestLeastSquaresUpdateLROneTenth_Test<>::TestBody()
@ 0x10b6ba173 testing::internal::HandleSehExceptionsInMethodIfSupported<>()
@ 0x10b6a6007 testing::internal::HandleExceptionsInMethodIfSupported<>()
@ 0x10b68bc85 testing::Test::Run()
@ 0x10b68cdab testing::TestInfo::Run()
@ 0x10b68db77 testing::TestCase::Run()
@ 0x10b694f69 testing::internal::UnitTestImpl::RunAllTests()
@ 0x10b6b6a33 testing::internal::HandleSehExceptionsInMethodIfSupported<>()
@ 0x10b6a8137 testing::internal::HandleExceptionsInMethodIfSupported<>()
make: *** [runtest] Segmentation fault: 11

I apreciate very much if someone can giveme some tip to make Caffe can use my AMD cards,
thanks in advance.
P.D. The config and makefile that I modified are attached.
Archive.zip

libclBLAS.so.2 cannot open

please answer me. When I run the mnist examples, I start this command:
sh examples/mnist/create_mnist.sh, while it failed. The error is: libclBLAS.so.2: cannot open shated object file: No such file or directory. What I should do?
Thanks.

cblas missing, cannot build using make or cmake OSX 10.10

I get 3% of the way into building after cmake fires off correctly from a build directory using $ cmake ... Using make manually from Caffe just results in there being the same error:

fatal error:
  'cblas.h' file not found
#include <cblas.h>
make[2]: *** [src/caffe/CMakeFiles/caffe.dir/blob.cpp.o] Error 1
make[1]: *** [src/caffe/CMakeFiles/caffe.dir/all] Error 2
make: *** [all] Error 2

I've looked around and most of the results I've found talk about using CUDA and that's clearly not an option. I have tried reinstalling all of my dependencies via homebrew, I've tried using standard make passing in compile params like $ make all -L /usr/local/Cellar/openblas/0.2.15/lib -I /usr/local/Cellar/openblas/0.2.15/include and followed this suggestion:

The only changes I needed to make to the source code were to replace #include <CL/...> with #include <OpenCL/...> in these files:

include/caffe/common.hpp
include/caffe/util/math_functions.hpp
and to remove #include <malloc.h> from src/caffe/device.cpp

I haven't seen anyone else having these same issues but I'm assuming I'm just doing something stupid and failing to actually link correctly somewhere.

Help?

Convolution layer refactoring (memory allocation)

The current convolution layer needs to be cleaned up:

#ifndef CPU_ONLY
#ifdef use_packing_scheme
template <typename Dtype> size_t BaseConvolutionLayer<Dtype>::subtop_mem_size = sizeof(Dtype);
template <typename Dtype> size_t BaseConvolutionLayer<Dtype>::trans_mem_size = sizeof(Dtype);
template <typename Dtype> cl_mem BaseConvolutionLayer<Dtype>::subTopMem = clCreateBuffer(amdDevice.Context, CL_MEM_READ_WRITE, BaseConvolutionLayer<Dtype>::subtop_mem_size, NULL, NULL);
template <typename Dtype> cl_mem BaseConvolutionLayer<Dtype>::transMem = clCreateBuffer(amdDevice.Context, CL_MEM_READ_WRITE, BaseConvolutionLayer<Dtype>::trans_mem_size, NULL, NULL);
#endif

is not conform to Caffe in instantiation and memory allocation, where device memory should be allocated through a SyncedMem object.

What can I do for this problem

$sudo ./examples/mnist/train_lenet.sh
F0321 18:34:47.668484 9422 device.cpp:95] Cannot find any dGPU!
*** Check failure stack trace: ***
@ 0x7f7880f08ea4 (unknown)
@ 0x7f7880f08deb (unknown)
@ 0x7f7880f087bf (unknown)
@ 0x7f7880f0ba35 (unknown)
@ 0x7f7881211a77 caffe::Device::Init()
@ 0x7f7881212edd caffe::Caffe::Caffe()
@ 0x409865 train()
@ 0x4069d1 main
@ 0x7f78801e8a40 (unknown)
@ 0x407019 _start
@ (nil) (unknown)
Aborted (core dumped)

Could the test running on the AMD server card

I know one of the newest server card -- AMD FirePro™ S9170 Server GPU. Its spec is comparable with nvidia k40. Could the speed test run on this card. So I can see the difference between these two series.

VecLib issue on El Capitan

Hi everyone,

When trying to build caffe on OSX, I encountered this error:

[ 69%] Linking CXX shared library ../../lib/libcaffe.dylib
ld: framework not found vecLib
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [lib/libcaffe.dylib] Error 1
make[1]: *** [src/caffe/CMakeFiles/caffe.dir/all] Error 2
make: *** [all] Error 2

Has anyone encountered this error, I tried to search for it on Google but I can't manage to resolve it.

Thanks.

Fury X make runtest fail

Scanning dependencies of target runtest
Current device id: 0
*** Aborted at 1456711725 (unix time) try "date -d @1456711725" if you are using GNU date ***
PC: @ 0x7fd6c749fb3a __GI_strlen
*** SIGSEGV (@0x0) received by PID 28734 (TID 0x7fd6bb02a9c0) from PID 0; stack trace: ***
@ 0x7fd6ce5889f0 (unknown)
@ 0x7fd6c749fb3a __GI_strlen
@ 0x7fd6acbd1df1 (unknown)
@ 0x7fd6acf4dc70 (unknown)
@ 0x7fd6acf4e3ce (unknown)
@ 0x7fd6acf5520e (unknown)
@ 0x7fd6acf5797e (unknown)
@ 0x7fd6b0061589 (unknown)
@ 0x7fd6af722198 (unknown)
@ 0x7fd6af6f0116 (unknown)
@ 0x7fd6af6ff8ec (unknown)
@ 0x7fd6af6e09d0 (unknown)
@ 0x7fd6cece249a caffe::Device::BuildProgram()
@ 0x7fd6cece3bfa caffe::Device::Init()
@ 0x6ee0a2 main
@ 0x7fd6c7435580 __libc_start_main
@ 0x6f3429 _start
/bin/sh: line 1: 28734 Segmentation fault (core dumped) /home/jimmy/Workspace/OpenCL-caffe/build/test/test.testbin --gtest_shuffle --gtest_filter="-GPU"
src/caffe/test/CMakeFiles/runtest.dir/build.make:57: recipe for target 'src/caffe/test/CMakeFiles/runtest' failed
make[3]: *** [src/caffe/test/CMakeFiles/runtest] Error 139
CMakeFiles/Makefile2:328: recipe for target 'src/caffe/test/CMakeFiles/runtest.dir/all' failed
make[2]: *** [src/caffe/test/CMakeFiles/runtest.dir/all] Error 2
CMakeFiles/Makefile2:335: recipe for target 'src/caffe/test/CMakeFiles/runtest.dir/rule' failed
make[1]: *** [src/caffe/test/CMakeFiles/runtest.dir/rule] Error 2
Makefile:240: recipe for target 'runtest' failed
make: *** [runtest] Error 2

By the way, I used OpenBlsa to compile caffine. Is that gonna be a problem?

What can I do for this problem

[----------] 5 tests from DBTest/1, where TypeParam = caffe::TypeLMDB
[ RUN ] DBTest/1.TestSeekToFirst
[ OK ] DBTest/1.TestSeekToFirst (110 ms)
[ RUN ] DBTest/1.TestKeyValue
[ OK ] DBTest/1.TestKeyValue (100 ms)
[ RUN ] DBTest/1.TestNext
[ OK ] DBTest/1.TestNext (101 ms)
[ RUN ] DBTest/1.TestWrite
F1112 10:42:15.701217 4211 db_lmdb.hpp:13] Check failed: mdb_status == 0 (-30792 vs. 0) MDB_MAP_FULL: Environment mapsize limit reached
*** Check failure stack trace: ***
@ 0x402fd61c google::LogMessage::Fail()
@ 0x402fd545 google::LogMessage::SendToLog()
@ 0x402fcf91 google::LogMessage::Flush()
@ 0x402fffde google::LogMessageFatal::~LogMessageFatal()
@ 0x401b1aee caffe::db::LMDBTransaction::Put()
Aborted (core dumped)
make[3]: *** [src/caffe/test/CMakeFiles/runtest] 错误 134
make[2]: *** [src/caffe/test/CMakeFiles/runtest.dir/all] 错误 2
make[1]: *** [src/caffe/test/CMakeFiles/runtest.dir/rule] 错误 2
make: *** [runtest] 错误 2

Error when make runtest

Linking CXX executable ../../../test/test.testbin
[100%] Built target test.testbin
Scanning dependencies of target runtest
Current device id: 0
Err: Failed to build program
�ց�Note: Google Test filter = -GPU
Note: Randomizing tests' orders with a seed of 58344 .
[==========] Running 1297 tests from 201 test cases.
[----------] Global test environment set-up.
[----------] 3 tests from ThresholdLayerTest/1, where TypeParam = caffe::CPUDevice
[ RUN ] ThresholdLayerTest/1.Test
Err: Failed to build program
�F0210 10:46:10.775442 26667 syncedmem.cpp:62] Check failed: error == 0 (-46 vs. 0) -46
*** Check failure stack trace: ***
@ 0x2b1e80fb9daa (unknown)
@ 0x2b1e80fb9ce4 (unknown)
@ 0x2b1e80fb96e6 (unknown)
@ 0x2b1e80fbc687 (unknown)
@ 0x2b1e80ab7781 caffe::SyncedMemory::ocl_setup()
@ 0x2b1e80ab4383 caffe::Blob<>::Reshape()
@ 0x2b1e80ab4659 caffe::Blob<>::Reshape()
@ 0x2b1e80ab46dc caffe::Blob<>::Blob()
@ 0x7037ba caffe::ThresholdLayerTest<>::ThresholdLayerTest()
@ 0x703b3b testing::internal::TestFactoryImpl<>::CreateTest()
@ 0xa3f1a3 testing::internal::HandleExceptionsInMethodIfSupported<>()
@ 0xa358e5 testing::TestInfo::Run()
@ 0xa35a05 testing::TestCase::Run()
@ 0xa38758 testing::internal::UnitTestImpl::RunAllTests()
@ 0xa389f7 testing::UnitTest::Run()
@ 0x6f79c5 main
@ 0x2b1e82f82ec5 (unknown)
@ 0x6f7d32 (unknown)
@ (nil) (unknown)
Aborted (core dumped)
make[3]: *** [src/caffe/test/CMakeFiles/runtest] 错误 134
make[2]: *** [src/caffe/test/CMakeFiles/runtest.dir/all] 错误 2
make[1]: *** [src/caffe/test/CMakeFiles/runtest.dir/rule] 错误 2
make: *** [runtest] 错误 2

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.