patrikhuber / superviseddescent

C++11 implementation of the supervised descent optimisation method
http://patrikhuber.github.io/superviseddescent/
Apache License 2.0
404 stars 188 forks source link

How can I convert code to client web based code #26

Closed Sun1718 closed 8 years ago

Sun1718 commented 8 years ago

Dear Patrik

I want to use facial landmark detection in web based application. How can I convert code to client side web based code. face_landmarks_model_rcr_68.bin is about 85M and it is heavy to load in web applications. How can I use it?

Regards. Morteza

patrikhuber commented 8 years ago

Hi Morteza,

That's a good question. You could decrease the size to around half or a bit less by using 1-2 fewer cascades, which would decrease performance just a little bit. Maybe you can keep the regressor server-side? Probably not an option though.

Another idea would be to compress the file using LZMA compression or something similar which is fast. You could try how small it gets.

I don't have another idea right now from the top of my head, I'd need to think about it.

Sun1718 commented 8 years ago

Thanks for your quick reply,

I've compressed it with LZMA and size decreased to about 75M. but it is heavy still.

About using 1-2 less cascades, 40M is also heavy for us.

About keeping regressor in server-side, I think it is not feasible. because we must move each frame to server for processing and it is not real time.

About convert code to web based code, I study about Emscripten. It can convert c++ to javascript, but I don't try it. do you know about it?

thanks again.

ghost commented 8 years ago

maybe you can try other face landmark detection method, and you can try '3000fps' code in github

Sun1718 commented 8 years ago

Thanks for your reply.

Regards, Morteza

On Wed, Jun 1, 2016 at 9:27 AM, Boyang Pan notifications@github.com wrote:

maybe you can try other face landmark detection method, and you can try '3000fps' code in github

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/patrikhuber/superviseddescent/issues/26#issuecomment-222900034, or mute the thread https://github.com/notifications/unsubscribe/AIYoD3OyD6xqN5W4PkRGMiahS6Qt-ri-ks5qHR8ugaJpZM4IqaWn .