Code Monkey home page Code Monkey logo

Comments (15)

heagoo avatar heagoo commented on August 27, 2024 1

from caffe.

nickltj86 avatar nickltj86 commented on August 27, 2024

hi @heagoo would you be willing to share your work on the merge with only MKL? would be interesting to see the results and performance with intelcaffe. do you have rough performance numbers per frame?

from caffe.

heagoo avatar heagoo commented on August 27, 2024

@nickltj86 The performance is not so good (262ms per frame with 32 cores), I think it could be much better after enable MKL2017_AS_DEFAULT_ENGINE, but unfortunately, the result is not correct yet.

from caffe.

nickltj86 avatar nickltj86 commented on August 27, 2024

Thanks. Good to know the performance. I think even after enabling MKL2017, the performance may not increase too much. From the benchmark, the new layers which are not optimized with MKL or MKL2017 such as the mbox layer will cause the most delays. The performance of the common cnn layers are very optimized and seems like as fast as those running on CUDA. the other non-optimized layers are a different story.

Do you have a fork with the merge? I think the Intel folks will need that to evaluate it as well.

from caffe.

heagoo avatar heagoo commented on August 27, 2024

Shared to:
https://github.com/heagoo/intel_caffe_ssd/

from caffe.

jdukat avatar jdukat commented on August 27, 2024

Could you please try with MKL2017 engine enabled, but for layers that cause problems explicitly select engine CAFFE?
For reference, you can see here how to select different engine is selected layer:
https://github.com/intel/caffe/blob/master/models/mkl2017_googlenet_v1_knl/train_val.prototxt

We are working on fixes to simplify this process and avoid manual engine selection.

from caffe.

heagoo avatar heagoo commented on August 27, 2024

@jdukat Yes, I've already do this, but the result is different from just using MKL, much different, and totally not correct. I tried:

  1. only add MKL2017 engine to the first conv layer, works. (but seems still call the im2col implementation)
  2. add MKL2017 to any other conv layers, NOT work.
    It may be related with the DNN function. Is there any detail description for the MKL DNN functions?
    And, the strange thing is that VGG16 works, do you think the input size matters? (VGG16 is 224x224, and SSD is 300x300 or 500x500)

from caffe.

jdukat avatar jdukat commented on August 27, 2024

Input size matters for performance with MKL2017 for sure. It should not matter for correctness and it seems to be a bug. We should take a closer look at this, but at the moment I am not able to put this on top of my priorities.

I'll see what I can do about documentation for MKL DNN functions.

from caffe.

jdukat avatar jdukat commented on August 27, 2024

MKL DNN API documentation

from caffe.

heagoo avatar heagoo commented on August 27, 2024

Thanks!
Confirmed, it's a bug of MKL, we can solve the issue by downloading https://github.com/intel-mxnet/mkl-release/releases/download/self_containted_MKLGOLD/mklml_lnx_2017.0.1.20161005.tgz
And now, performance boost to 88ms under the same setting, great!

from caffe.

jdukat avatar jdukat commented on August 27, 2024

Great, the same MKL version will be released for Caffe within next few days.
@heagoo do you plan to issue a pull request with your changes for Intel Caffe?

from caffe.

heagoo avatar heagoo commented on August 27, 2024

Sure, will do it. @jdukat

from caffe.

ngaloppo avatar ngaloppo commented on August 27, 2024

Is it confirmed that this bug exists in current master? If so, can we open this issue again to track the bug until it is fixed?

from caffe.

heagoo avatar heagoo commented on August 27, 2024

This bug does not exist any more in the latest update with MKL 2017 update 1.

from caffe.

amoussawi avatar amoussawi commented on August 27, 2024

Hey @heagoo
Could you please tell me what intel processor are you using if you don't mind? Thanks :)

from caffe.

Related Issues (20)

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.