face_recognition icon indicating copy to clipboard operation
face_recognition copied to clipboard

Model Building Incremental way

Open akhilgupta0221 opened this issue 7 years ago • 8 comments
trafficstars

Description

Instead of building the Model for all the images every time is that possible to build the Model in the incremental way.

for ex: If we have 100 images first day and we have built the Model for 100 images for the same day then next day the model will be built only for the new images on the top of the previous day model and that will give the model of all the images present till that day.

No need to retrain all the images every time it should only be for the new images on top of previous day model.

akhilgupta0221 avatar Nov 24 '18 13:11 akhilgupta0221

What kind of model are you training exactly? If you are just encoding images, you could save the encodings from the previous days so you don't have to recalculate them.

ageitgey avatar Nov 24 '18 20:11 ageitgey

@ageitgey : It's an encodings of images. In layman terms I want to merge the previous day and the current day model without building the previous day model.

akhilgupta0221 avatar Nov 25 '18 01:11 akhilgupta0221

@ageitgey can u suggest a way to reduce model building time eg: Suppose on any day we have 100 images and we are building a model on it, on next day we get 10 new more images now we need to build a model of 110 images (which will take more time). Is there any way by which we can only include these new 10 images and merge it with 100 images model so that it can reduce model building time :)

nitishxp avatar Nov 26 '18 05:11 nitishxp

@nitishxp you can save the model by pickle When you need to add more faces, you can load from the model and add new face encodings to it

donaldxu avatar Nov 26 '18 12:11 donaldxu

is this a good way to do in the production environment?

nitishxp avatar Nov 26 '18 16:11 nitishxp

is this a good way to do in the production environment?

in a production environment, i think you can save face encodings in database or redis

donaldxu avatar Nov 29 '18 01:11 donaldxu

Hi can you give a documentation to save model in redis and read from it?

Thanks

On Thu 29 Nov, 2018, 6:46 AM donaldxu <[email protected] wrote:

is this a good way to do in the production environment?

in a production environment, i think you can save face encodings in database or redis

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ageitgey/face_recognition/issues/685#issuecomment-442668227, or mute the thread https://github.com/notifications/unsubscribe-auth/AX2B-ipaVIErHbFvfeO8YZuxf7qikkqbks5uzzVdgaJpZM4Yxb89 .

nitishxp avatar Nov 29 '18 01:11 nitishxp

Hi can you give a documentation to save model in redis and read from it? Thanks On Thu 29 Nov, 2018, 6:46 AM donaldxu @.*** wrote: is this a good way to do in the production environment? in a production environment, i think you can save face encodings in database or redis — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#685 (comment)>, or mute the thread https://github.com/notifications/unsubscribe-auth/AX2B-ipaVIErHbFvfeO8YZuxf7qikkqbks5uzzVdgaJpZM4Yxb89 .

    1. Many thanks!

fishfree avatar Apr 17 '23 21:04 fishfree