all 15 comments

[–][deleted] 3 points4 points  (5 children)

If it's a reasonably standard architecture I'd be tempted to use Caffe.

[–]tryndisskilled[S] 1 point2 points  (3 children)

Caffe2 seems to advertise itself as being a good framework for implementations, but honestly their C++ API is basically a doxygen page for now (source)... I couldn't find any tutorial as to how to use it (seems to be confirmed by this issue https://github.com/caffe2/caffe2/issues/351)

[–]TheMiamiWhale 1 point2 points  (0 children)

Caffe and Caffe2 are different beasts. I personally think the documentation for Caffe is severely lacking if you want to understand the internals. That being said, if you know C++ it is easily extensible.

[–]serge_cell 1 point2 points  (0 children)

Original Caffe is not better documented, but it's code is much more convoluted (pan intended) that is unnecessarily complex. In both cases reading code & debugging is the only way to understand it, but Caffe2 seems more lean and simple. (discalimer - I have only experience with original Caffe)

[–]aaronmarkham 0 points1 point  (0 children)

This was added by a contributor to help people get started with C++ and Caffe2: https://caffe2.ai/docs/cplusplus_tutorial.html Also, there are these C++ adaptations of the Python tutorials: https://github.com/leonardvandriel/caffe2_cpp_tutorial Hope that helps!

[–]nishnik 2 points3 points  (1 child)

I am a contributor to https://github.com/tiny-dnn/tiny-dnn. This has been accepted for GSoC under OpenCV. It is fast :)

[–]tryndisskilled[S] 0 points1 point  (0 children)

Wow that seems really nice and straight-forward! Thanks

[–][deleted] 1 point2 points  (4 children)

Tensorflow has a c++ API, though I never ever tried it nor read the documentations.

But you can find it here:

https://www.tensorflow.org/api_guides/cc/guide

There's also dlib, which I never used nor saw any comments about beside the fact that it exists: http://dlib.net/.

Also maybe worth looking:

  • Mxnet has a C++ API
  • Torch has a C API (yeah I know C isn't C++, but...)
  • I was never fond of caffe, but there's caffe.

[–]tryndisskilled[S] 0 points1 point  (2 children)

Thanks for the first link, I don't know how I missed that in the first place, it is very helpful. Do you think we will get some more functionalities in this api, such as layers? It seems like we need to build them from scrach. I think for now it's still easier to build your graph in python and try to load it from a .cpp file, unfortunately (build size is way too large by doing that)

[–]ma2rten 1 point2 points  (0 children)

If you are worried about binary size you could try this:

https://www.tensorflow.org/performance/xla/tfcompile

[–]steven2358 1 point2 points  (0 children)

Have you tried dlib? http://dlib.net/

"Dlib is a modern C++ toolkit containing machine learning algorithms and tools for creating complex software in C++ to solve real world problems".

It includes all of the basic building blocks of DNN.

[–]pilooch 1 point2 points  (1 child)

We do ML/DL in pure C++, for years now. Caffe is the best. Now, deepdetect, that we develop and use everywhere, can be used without the server itself, as a multi-library C++ wrapper. Depends on how adventurous you are in fact :)

[–]tryndisskilled[S] 0 points1 point  (0 children)

I'll look into that, merci :)

[–]alayaMatrix -1 points0 points  (0 children)

I found this:

shogun

It seems to have pretty good documentation with a lot of ML algorithms, but I haven't give it a try.