I'm working on a project to identify a person in a specimen jpg photo by comparing it to a gallery of about 500,000 images.
My photo collection is in a Microsoft SQL database and I prefer to not keep photos as individual files.
Current Design:
A batch process codes each photo shortly after it is added to the database using this command:
--> br -algorithm FaceRecognition -enroll /tmp/image.jpg '/tmp/srims_gal.csv'
The output of this command is stored in the database record for the given photo. Typical metadata looks like this:
SSFXX-26-1.jpg,235,325,373,333,145924,false,0,116,190,382,382,373,333,235,325
Another batch process builds a CSV gallery. Is this a valid gallery? It looks like this:
File,Affine_0_X,Affine_0_Y,Affine_1_X,Affine_1_Y,Confidence,FTE,FrameNumber,FrontalFace_X,FrontalFace_Y,FrontalFace_Width,FrontalFace_Height,StasmLeftEye_X,StasmLeftEye_Y,StasmRightEye_X,StasmRightEye_Y
SSFXX-26-1.jpg,235,325,373,333,145924,false,0,116,190,382,382,373,333,235,325
SSFXX-76-1.jpg,107,125,169,144,26569,false,0,54,66,163,163,169,144,107,125
SSFXX-103-2.jpg,555,577,790,585,363609,false,0,352,387,603,603,790,585,555,577
SSFXX-103-3.jpg,343,157,751,212,-3.40282347e+38,false,0,0,0,1024,768,751,212,343,157
I'm attempting to find matches for the specimen photo with the command.
-> br -algorithm FaceRecognition -compare ssfxx_gallery.csv specimen.jpg
This results in errors because the .jpg photos exist only in the database, which br cannot access directly.
Questions and Issues:
1) How can I have OpenBR match a specimen photo to metadata in a CSV gallery file, without needing to direct access to the .jpg file.
2) Is my overall architecture practical? (I'm working with C# on Mono.)
//