davidsandberg / facenet

Face recognition using Tensorflow
MIT License
13.63k stars 4.8k forks source link

Tensorflow Java Working Example #664

Open mhashem opened 6 years ago

mhashem commented 6 years ago

Hello I am new to deep learning and tensroflow in general, I am writing a basic server app for my thesis where I need to accept calls in real time to classify a face image, for the current moment I was able to load the facenet trained model (graph) in Java and generate embeddings vector to use it later in classification using SVM, but the point is how accurate is these generated features? and does it need more training before it is used in classification ?

below is a snippet of how I generate the embeddings vector in Java

Tensor<Float> result = session.runner()
    .feed("input:0", image)
    .feed("phase_train:0", Tensors.create(false))
    .fetch("embeddings:0").run().get(0)
    .expect(Float.class);
result.writeTo(FloatBuffer.wrap(embeddings));

can someone guide me for how can I train the model for more accurate results the same way that was done in python but in Java ?

447021667 commented 5 years ago

Have you solved it?