Skip to content

Commit

Permalink
* Fix Caffe crashing in GPU mode: Do not define CPU_ONLY (issue #147)
Browse files Browse the repository at this point in the history
 * Make OpenBLAS build for Caffe more generic (issue #154)
  • Loading branch information
saudet committed Mar 4, 2016
1 parent 8434cfb commit 0d0b152
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@

* Fix Caffe crashing in GPU mode: Do not define `CPU_ONLY` ([issue #147](https://github.com/bytedeco/javacpp-presets/issues/147))
* Make OpenBLAS build for Caffe more generic ([issue #154](https://github.com/bytedeco/javacpp-presets/issues/154))
* Include missing `graph_constructor.h` header file from the `tensorflow` module ([issue #165](https://github.com/bytedeco/javacpp-presets/issues/165))
* Add missing `GraphDefBuilder.Options.WithAttr()` methods from the `tensorflow` module ([issue #160](https://github.com/bytedeco/javacpp-presets/issues/160))
* Add `linux-armhf` platform to the `cppbuild.sh` scripts of OpenCV and FFmpeg
Expand Down
4 changes: 2 additions & 2 deletions caffe/cppbuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -136,10 +136,10 @@ make install
cd ..

# OSX has Accelerate
if [[ $PLATFORM != macosx-* ]]; then
if [[ $BLAS == "open" ]]; then
# blas (requires fortran, e.g. sudo yum install gcc-gfortran)
cd OpenBLAS-$OPENBLAS
make -j $MAKEJ "CC=$CC" "FC=$FC" BINARY=$BINARY NO_SHARED=1
make -j $MAKEJ "CC=$CC" "FC=$FC" BINARY=$BINARY NO_SHARED=1 TARGET=GENERIC
make install "PREFIX=$INSTALL_PATH" NO_SHARED=1
cd ..
fi
Expand Down
3 changes: 2 additions & 1 deletion caffe/src/main/java/org/bytedeco/javacpp/presets/caffe.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@
"caffe/layers/pooling_layer.hpp", "caffe/layers/cudnn_pooling_layer.hpp", "caffe/layers/spp_layer.hpp", "caffe/util/benchmark.hpp", "caffe/util/db.hpp", "caffe/util/db_leveldb.hpp",
"caffe/util/db_lmdb.hpp", "caffe/util/io.hpp", "caffe/util/rng.hpp", "caffe/util/im2col.hpp", "caffe/util/insert_splits.hpp", "caffe/util/mkl_alternate.hpp",
"caffe/util/upgrade_proto.hpp", "caffe/util/cudnn.hpp"}, link = "caffe@.1.0.0-rc3", includepath = {"/usr/local/cuda/include/",
"/System/Library/Frameworks/vecLib.framework/", "/System/Library/Frameworks/Accelerate.framework/"}, linkpath = "/usr/local/cuda/lib/") })
"/System/Library/Frameworks/vecLib.framework/", "/System/Library/Frameworks/Accelerate.framework/"}, linkpath = "/usr/local/cuda/lib/"),
@Platform(value = {"linux-x86_64", "macosx-x86_64"}, define = {"SHARED_PTR_NAMESPACE boost", "USE_LEVELDB", "USE_LMDB", "USE_OPENCV"}) })
public class caffe implements InfoMapper {
public void map(InfoMap infoMap) {
infoMap.put(new Info("NOT_IMPLEMENTED", "NO_GPU", "CUDA_POST_KERNEL_CHECK").cppTypes().annotations())
Expand Down

5 comments on commit 0d0b152

@nhe150
Copy link

@nhe150 nhe150 commented on 0d0b152 Mar 24, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Samuel, Would you please publish the artifact to maven as preset-caffe 1.2?

@saudet
Copy link
Member Author

@saudet saudet commented on 0d0b152 Mar 24, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should have the time before long, I hope, but can't make any promises...

@nhe150
Copy link

@nhe150 nhe150 commented on 0d0b152 Mar 24, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Patience is a virtue. Thank you for the great effort in providing java for all the vision/deeplearning library. I finally got a couple of machines with Tesla 80 GPUs. I am waiting to try out javacpp caffe/opencv on GPUs.

@saudet
Copy link
Member Author

@saudet saudet commented on 0d0b152 Mar 25, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW, please try to build from source code:
https://github.com/bytedeco/javacpp-presets/wiki/Build-Environments
It would help me a lot to have more people testing things this way...

@nhe150
Copy link

@nhe150 nhe150 commented on 0d0b152 Mar 28, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will do. Thank you again.

Please sign in to comment.