Explanation for bob.pad.face

98 views
Skip to first unread message

Mohameed Chaouche

unread,
Aug 9, 2018, 9:24:54 AM8/9/18
to bob-devel
I see that running :

$ ./bin/spoof.py --database <database-name> --preprocessor <preprocessor> --extractor <extractor> --algorithm <algorithm> --sub-directory <folder_name> -vv

1-for face spoofing , can you explain how does it work (i have read the repo info but i still don't get it)? ( what file is the generated dataset, and trained model ?
 as i see it's an .HDF5 file (what data does it contain as features to make difference between two frames ?)) and how to test the model on a local dataset.

2-is there optimal options for (preprocessor,extractor,algorithm) to be used ? or a working example

3-after the Model is trained, how should i use the trained model to test it for a real-time face detection or recognition, to secure the face-recognition ?

I have made some progress, but i see that there is too much information on the gitlab/github repo, and little examples or labs for beginners like myself.

Thank you for your help.

Mohameed Chaouche

unread,
Aug 9, 2018, 9:37:41 AM8/9/18
to bob-devel

When i run it i am having an error, maybe someone can help ? you can see on the photos below
one.JPG
three.JPG
two.JPG

Mohameed Chaouche

unread,
Aug 9, 2018, 9:40:38 AM8/9/18
to bob-devel

the verify command did work, but i have no idea what to do with the results ?
verify 3.JPG
verify.JPG
verify2.JPG

Mohameed Chaouche

unread,
Aug 9, 2018, 9:43:48 AM8/9/18
to bob-devel
i ran this one :

spoof.py replay-attack lbp-svm --sub-directory /abc --parallel 400 , i am using 20 virtual cpus but it's using only 1% is that normal ? 
spoof.JPG

Mohameed Chaouche

unread,
Aug 9, 2018, 10:10:58 AM8/9/18
to bob-devel
what do the numbers in the HDF5 file represent ? i found the data in .results/extracted/test/real/ .

Thank you for your help..

i excuse myself in advance for the beginner questions ..
HDF5.JPG

André Anjos

unread,
Aug 9, 2018, 10:33:49 AM8/9/18
to bob-...@googlegroups.com
Hello,

Some answers:

1) bob.pad.face is based on bob.pad.base (a presentation-attack detection framework), which itself is inspired in bob.bio.base (a biometric recognition framework). In order to understand the architecture of bob.pad.face, start by reading the manual of bob.bio.base and understand how it is setup and biometric experimentation is conducted. Once you understand that, transposing that knowledge to bob.pad.base/bob.pad.face is easy.

2) The values available in the baselines are to be considered as such (ie, baseline values). For particular settings that work best for a given database, you'll have to try to for yourself. Did you get to this: https://www.idiap.ch/software/bob/docs/bob/bob.pad.face/stable/baselines.html ?

3) These packages are made for research on protocolled databases. They make it easy to run reproducible experiments that we publish. If you want to re-use its components to do something else you'll have to, by yourself, extract the pieces you're interested in and create your own framework based on those. This is typically done on a case-by-case basis and is very specific to each project therefore difficult to provide in a generic format. In short, there is no "single-shot" execution mode currently possible with the components as they are.

We don't currently have labs or beginner's material associated with these packages. To use them efficiently, you must have some programming background and understanding of how biometric / PAD experimentation works.

That said, we happily accept patches to our documentation if that is something you'd be willing to contribute to.

Best, A

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/
---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
Dr. André Anjos
Idiap Research Institute
Centre du Parc - rue Marconi 19
CH-1920 Martigny, Suisse
Phone: +41277217763
http://andreanjos.org

Mohameeed Chaouche

unread,
Aug 9, 2018, 10:56:19 AM8/9/18
to bob-...@googlegroups.com
Hello André,

Thank you for the fast replay, and i understand the fact that the framework is a bit complex thats why i seem to be lost for now.

And yes i gave git to part 2 i tried the spoof.py command with some parameters i loaded the database and put ut in .bob_bio_databases.txt as explained . And i ran spoof.py replay-attack lbp-svm --sub-directory .results . I have a server with 80 logical CPU's but the code seems to be using only one CPU , i see the generated files as i understand each .mov video has a hdf5 file and inside for each frame there is numbers like 0.001 0.0049...but i dont know where they come from.

And yes i will be more that happy to contribute in helping to provide labs and examples for the documentation.

Thank you for your help,

Mohamed.

On Aug 9, 2018 16:33, "André Anjos" <andre...@idiap.ch> wrote:
Hello,

Some answers:

1) bob.pad.face is based on bob.pad.base (a presentation-attack detection framework), which itself is inspired in bob.bio.base (a biometric recognition framework). In order to understand the architecture of bob.pad.face, start by reading the manual of bob.bio.base and understand how it is setup and biometric experimentation is conducted. Once you understand that, transposing that knowledge to bob.pad.base/bob.pad.face is easy.

2) The values available in the baselines are to be considered as such (ie, baseline values). For particular settings that work best for a given database, you'll have to try to for yourself. Did you get to this: https://www.idiap.ch/software/bob/docs/bob/bob.pad.face/stable/baselines.html ?

3) These packages are made for research on protocolled databases. They make it easy to run reproducible experiments that we publish. If you want to re-use its components to do something else you'll have to, by yourself, extract the pieces you're interested in and create your own framework based on those. This is typically done on a case-by-case basis and is very specific to each project therefore difficult to provide in a generic format. In short, there is no "single-shot" execution mode currently possible with the components as they are.

We don't currently have labs or beginner's material associated with these packages. To use them efficiently, you must have some programming background and understanding of how biometric / PAD experimentation works.

That said, we happily accept patches to our documentation if that is something you'd be willing to contribute to.

Best, A

On Thu, Aug 9, 2018 at 3:24 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
I see that running :

$ ./bin/spoof.py --database <database-name> --preprocessor <preprocessor> --extractor <extractor> --algorithm <algorithm> --sub-directory <folder_name> -vv

1-for face spoofing , can you explain how does it work (i have read the repo info but i still don't get it)? ( what file is the generated dataset, and trained model ?
 as i see it's an .HDF5 file (what data does it contain as features to make difference between two frames ?)) and how to test the model on a local dataset.

2-is there optimal options for (preprocessor,extractor,algorithm) to be used ? or a working example

3-after the Model is trained, how should i use the trained model to test it for a real-time face detection or recognition, to secure the face-recognition ?

I have made some progress, but i see that there is too much information on the gitlab/github repo, and little examples or labs for beginners like myself.

Thank you for your help.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


--
Dr. André Anjos
Idiap Research Institute
Centre du Parc - rue Marconi 19
CH-1920 Martigny, Suisse
Phone: +41277217763
http://andreanjos.org

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

André Anjos

unread,
Aug 9, 2018, 11:04:52 AM8/9/18
to bob-...@googlegroups.com
The issue with your current speed-up may be related to poor disk performance. Note that, parallelisation tunning is an art by itself. It makes no sense to run "400" things in parallel, unless you do have 400 processors and a **super** fast disk that can feed those so they don't block waiting. I'd start humbly with 2, see a double performance speed up, then increase to 4, until you start seeing that increasing this number does not increase throughput. Best, A 

-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


--
Dr. André Anjos
Idiap Research Institute
Centre du Parc - rue Marconi 19
CH-1920 Martigny, Suisse
Phone: +41277217763
http://andreanjos.org

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Pavel Korshunov

unread,
Aug 9, 2018, 11:25:40 AM8/9/18
to bob-...@googlegroups.com
Hi Mohamed,

To add to and emphasize some of the points that André mentioned, the anti-spoofing (or presentation attack detection) experiments consist of several interlinked and sometimes complex stages (e.g., preprocessing, extraction, training, scoring, etc). Most of these stages are based on biometric experiments, for which you can find a summary overview here (with some nice diagrams): https://www.idiap.ch/software/bob/docs/bob/bob.bio.base/stable/struct_bio_rec_sys.html

So, each stage of the experiment you are running saves the intermediate results into hdf5 files. What is inside those files depends on what algorithms are used for a given stage. If you want to know exactly what those numbers mean, you'd need to figure out what those algorithms are doing. To help with this, you can read docs and may be papers, for instance, you can check this paper on biometric experiments and reproducibility: http://publications.idiap.ch/downloads/papers/2017/Anjos_ICML2017-2_2017.pdf). But the most reliable way to do so is, ultimately, to study the source code. 

Best,
Pavel

On Thu, Aug 9, 2018 at 4:56 PM Mohameeed Chaouche <mohamed.c...@gmail.com> wrote:
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


--
Dr. André Anjos
Idiap Research Institute
Centre du Parc - rue Marconi 19
CH-1920 Martigny, Suisse
Phone: +41277217763
http://andreanjos.org

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameed Chaouche

unread,
Aug 9, 2018, 12:28:16 PM8/9/18
to bob-devel
The .HDF5 file contains data after i typed this command (spoof.py replay-attack lbp-svm --sub-directory ./results --parallel 4) , as i understand each frame of the .mov video contains an array and in each array there is 58 rows,
but i dunno what the floats in each array represent , the numbers (0.00208117 , 0.10041623 ....) ? and how can i make use of the .HDF5 files. (hdf5_2.JPG image )

i will read the pdf Pavel, Thank you.

i haven't succeeded yet to use the (spoof.py --database replay-attack, apparently it doesnt recognize the dataset that i have configured previously in the ~/.bob_bio_databases.txt file as you can see (two.JPG image))

Thank you ,
hdf5_2.JPG
two.JPG

Amir Mohammadi

unread,
Aug 10, 2018, 5:00:07 AM8/10/18
to bob-...@googlegroups.com
Dear Mohamed,

Your questions are a bit confusing. I still do not understand what is your goal here.
What are you trying to do? Are you reproducing a particular paper?
Thank you for letting us know what are your goals here so that we can help you better.

Thanks,
Amir

--

Mohameeed Chaouche

unread,
Aug 10, 2018, 5:06:17 AM8/10/18
to bob-...@googlegroups.com
Hello, 

My main goal is to impelement your technique for antispoofing (i see that you are using multiple ,algorithms,extractors , preprocessors) for a secure real-time facial recognition.

I understand that i have to train a Model on the Replay-Attack video spoofing dataset, and then i am willing to use the trained model on the real time face recognition using a webcam to authenticate only a live person and detect (image , video , printed image ) of the to be authenticated user as spoof.

Thank you for your valuable help, its actually for my Masters thesis that i am working on .


On Aug 10, 2018 11:00 AM, "Amir Mohammadi" <183....@gmail.com> wrote:
Dear Mohamed,

Your questions are a bit confusing. I still do not understand what is your goal here.
What are you trying to do? Are you reproducing a particular paper?
Thank you for letting us know what are your goals here so that we can help you better.

Thanks,
Amir

On Thu, Aug 9, 2018 at 6:28 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
The .HDF5 file contains data after i typed this command (spoof.py replay-attack lbp-svm --sub-directory ./results --parallel 4) , as i understand each frame of the .mov video contains an array and in each array there is 58 rows,
but i dunno what the floats in each array represent , the numbers (0.00208117 , 0.10041623 ....) ? and how can i make use of the .HDF5 files. (hdf5_2.JPG image )

i will read the pdf Pavel, Thank you.

i haven't succeeded yet to use the (spoof.py --database replay-attack, apparently it doesnt recognize the dataset that i have configured previously in the ~/.bob_bio_databases.txt file as you can see (two.JPG image))

Thank you ,

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

Amir Mohammadi

unread,
Aug 10, 2018, 5:08:29 AM8/10/18
to bob-...@googlegroups.com
There are many ways to do face PAD (aka anti-spoofing). To which technique are you referring to?

On Fri, Aug 10, 2018 at 11:06 AM Mohameeed Chaouche <mohamed.c...@gmail.com> wrote:
Hello, 

My main goal is to impelement your technique for antispoofing (i see that you are using multiple ,algorithms,extractors , preprocessors) for a secure real-time facial recognition.

I understand that i have to train a Model on the Replay-Attack video spoofing dataset, and then i am willing to use the trained model on the real time face recognition using a webcam to authenticate only a live person and detect (image , video , printed image ) of the to be authenticated user as spoof.

Thank you for your valuable help, its actually for my Masters thesis that i am working on .

On Aug 10, 2018 11:00 AM, "Amir Mohammadi" <183....@gmail.com> wrote:
Dear Mohamed,

Your questions are a bit confusing. I still do not understand what is your goal here.
What are you trying to do? Are you reproducing a particular paper?
Thank you for letting us know what are your goals here so that we can help you better.

Thanks,
Amir

On Thu, Aug 9, 2018 at 6:28 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
The .HDF5 file contains data after i typed this command (spoof.py replay-attack lbp-svm --sub-directory ./results --parallel 4) , as i understand each frame of the .mov video contains an array and in each array there is 58 rows,
but i dunno what the floats in each array represent , the numbers (0.00208117 , 0.10041623 ....) ? and how can i make use of the .HDF5 files. (hdf5_2.JPG image )

i will read the pdf Pavel, Thank you.

i haven't succeeded yet to use the (spoof.py --database replay-attack, apparently it doesnt recognize the dataset that i have configured previously in the ~/.bob_bio_databases.txt file as you can see (two.JPG image))

Thank you ,

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameeed Chaouche

unread,
Aug 10, 2018, 5:17:14 AM8/10/18
to bob-...@googlegroups.com
I want to start with Linear Binary patterns ti start with but i am a bit lost in the package because there is many buttons and i am trying to figure out the right ones to push ...i have read the code for antispoofing.lbp v2.0.4 which is a bit simpler but i am having error in the python code  the line (database = args.cls(args) . The argparee package wont recognize the cls() method.

For the bob package , i am still trying to figure out which are the right parameters to use to spoof.py (preprocessor, extractor , algorithme ) , and then i dont know how to use the sub-directory folder to accomplish the realtime antispoofing detection for face recognition .

Thank you Amir,

On Aug 10, 2018 11:08 AM, "Amir Mohammadi" <183....@gmail.com> wrote:
There are many ways to do face PAD (aka anti-spoofing). To which technique are you referring to?

On Fri, Aug 10, 2018 at 11:06 AM Mohameeed Chaouche <mohamed.c...@gmail.com> wrote:
Hello, 

My main goal is to impelement your technique for antispoofing (i see that you are using multiple ,algorithms,extractors , preprocessors) for a secure real-time facial recognition.

I understand that i have to train a Model on the Replay-Attack video spoofing dataset, and then i am willing to use the trained model on the real time face recognition using a webcam to authenticate only a live person and detect (image , video , printed image ) of the to be authenticated user as spoof.

Thank you for your valuable help, its actually for my Masters thesis that i am working on .

On Aug 10, 2018 11:00 AM, "Amir Mohammadi" <183....@gmail.com> wrote:
Dear Mohamed,

Your questions are a bit confusing. I still do not understand what is your goal here.
What are you trying to do? Are you reproducing a particular paper?
Thank you for letting us know what are your goals here so that we can help you better.

Thanks,
Amir

On Thu, Aug 9, 2018 at 6:28 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
The .HDF5 file contains data after i typed this command (spoof.py replay-attack lbp-svm --sub-directory ./results --parallel 4) , as i understand each frame of the .mov video contains an array and in each array there is 58 rows,
but i dunno what the floats in each array represent , the numbers (0.00208117 , 0.10041623 ....) ? and how can i make use of the .HDF5 files. (hdf5_2.JPG image )

i will read the pdf Pavel, Thank you.

i haven't succeeded yet to use the (spoof.py --database replay-attack, apparently it doesnt recognize the dataset that i have configured previously in the ~/.bob_bio_databases.txt file as you can see (two.JPG image))

Thank you ,

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

Amir Mohammadi

unread,
Aug 10, 2018, 5:23:33 AM8/10/18
to bob-...@googlegroups.com
Could you please confirm that
you have read the paper:

and looked at the code (which is deprecated and does not work but anyways have you looked at it?):

These are **local** binary patterns not linear binary patterns.

Best,
Amir

-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameeed Chaouche

unread,
Aug 10, 2018, 5:38:37 AM8/10/18
to bob-...@googlegroups.com
Yes i have read those, and yes sorry it is LBP (the one that compares pixels and generates numbers from 0-256, in dicimal from that we can tell the diffrence between a real and printed or screen-image but i dont know yet how to impliment it using the (antispoofing.lbp package 


-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

Mohameed Chaouche

unread,
Aug 10, 2018, 5:41:10 AM8/10/18
to bob-devel
there is the issue where i am stuck for the lantispoofing.lbp as you can see the picture below
lbp1.JPG
lbp2..JPG

Amir Mohammadi

unread,
Aug 10, 2018, 5:48:53 AM8/10/18
to bob-...@googlegroups.com
Thank you for confirming. I cannot help you make the antispoofing.lbp package work. This is an old package and archived.
The code inside is moved to bob.pad.face which we can help you with.

The code in antispoofing.lbp is established as a replay attack database baseline in

You just need to execute one command to reproduce that paper which is:
$ spoof.py replay-attack lbp-svm --sub-directory <PATH_TO_STORE_THE_RESULTS>


You should have a line like:
[YOUR_REPLAY_ATTACK_DIRECTORY] = /path/to/replayattack/dataset/
in your `~/.bob_bio_databases.txt`

So when you run the spoof.py command above, does it run without any errors?

-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameed Chaouche

unread,
Aug 10, 2018, 5:54:49 AM8/10/18
to bob-devel
i put it to run, isn't there a way to use parallelization to speed up the process? ( i have resources on this machine(80 virtual CPUs and 40Gb of Ram)
lbp-svm-test.JPG

Amir Mohammadi

unread,
Aug 10, 2018, 5:59:29 AM8/10/18
to bob-...@googlegroups.com
Yes there is. Add the --parallel option to the spoof.py command. Start with --parallel 2 and see what happens.

Here is what Andre said about this earlier:
The issue with your current speed-up may be related to poor disk performance. Note that, parallelisation tunning is an art by itself. It makes no sense to run "400" things in parallel, unless you do have 400 processors and a **super** fast disk that can feed those so they don't block waiting. I'd start humbly with 2, see a double performance speed up, then increase to 4, until you start seeing that increasing this number does not increase throughput. Best, A

On Fri, Aug 10, 2018 at 11:54 AM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
i put it to run, isn't there a way to use parallelization to speed up the process? ( i have resources on this machine(80 virtual CPUs and 40Gb of Ram)

--

Mohameed Chaouche

unread,
Aug 10, 2018, 6:16:28 AM8/10/18
to bob-devel
Allright, i remember that one, Thank you !

Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

1-what those numbers represent ?
2-how can i implement the output files in a facial recognition system ? (i see that bob.bio.face does that)
3-is it possible to use other feature extraction methods i see that in (antispoofing.lbp) there is HOG method as well , what other methods can i test as well, for example (GLCM) ?


Thank you very much !
folders.JPG
hdf5_2.JPG

Amir Mohammadi

unread,
Aug 10, 2018, 6:30:18 AM8/10/18
to bob-...@googlegroups.com
> Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

No you don't get an .hdf5 file for each video. You get several. Each in different directories. Which one are you talking about?

--

Mohameeed Chaouche

unread,
Aug 10, 2018, 6:35:52 AM8/10/18
to bob-...@googlegroups.com
I have opened the directory and see several .hdf5 files , i dont know how to make use of that ? 


On Aug 10, 2018 12:30 PM, "Amir Mohammadi" <183....@gmail.com> wrote:
> Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

No you don't get an .hdf5 file for each video. You get several. Each in different directories. Which one are you talking about?

On Fri, Aug 10, 2018 at 12:16 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
Allright, i remember that one, Thank you !

Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

1-what those numbers represent ?
2-how can i implement the output files in a facial recognition system ? (i see that bob.bio.face does that)
3-is it possible to use other feature extraction methods i see that in (antispoofing.lbp) there is HOG method as well , what other methods can i test as well, for example (GLCM) ?


Thank you very much !

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

Amir Mohammadi

unread,
Aug 10, 2018, 6:40:54 AM8/10/18
to bob-...@googlegroups.com
Can you please share the file path of one of these .hdf5 files so we know exactly which one you are talking about?

Is it in the `preprocessed` directory or in the `extracted` directory?

On Fri, Aug 10, 2018 at 12:35 PM Mohameeed Chaouche <mohamed.c...@gmail.com> wrote:
I have opened the directory and see several .hdf5 files , i dont know how to make use of that ? 

On Aug 10, 2018 12:30 PM, "Amir Mohammadi" <183....@gmail.com> wrote:
> Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

No you don't get an .hdf5 file for each video. You get several. Each in different directories. Which one are you talking about?

On Fri, Aug 10, 2018 at 12:16 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
Allright, i remember that one, Thank you !

Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

1-what those numbers represent ?
2-how can i implement the output files in a facial recognition system ? (i see that bob.bio.face does that)
3-is it possible to use other feature extraction methods i see that in (antispoofing.lbp) there is HOG method as well , what other methods can i test as well, for example (GLCM) ?


Thank you very much !

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameed Chaouche

unread,
Aug 10, 2018, 6:45:18 AM8/10/18
to bob-devel
Hey Amir,

As you can see in the pictures above those are the generated files and folders after issuing the command (spoof.py replay-attack lbp-svm --sub-directory ~/lbp-svm-test).

The .hdf5 files are in the two folders : extracted and preprocessed.

Thanks for your help,
folders2.JPG
folders3.JPG
folders4.JPG
folders5.JPG
folders6.JPG
folders7.JPG
array.JPG

547928057

unread,
Aug 10, 2018, 6:48:26 AM8/10/18
to bob-devel
ImportError cannot import name “histograms”
Where is the “Histograms” module?
Thanks 



------------------ Original ------------------
From: Mohameed Chaouche <mohamed.c...@gmail.com>
Date: Fri,Aug 10,2018 6:45 PM
To: bob-devel <bob-...@googlegroups.com>
Subject: Re: [bob-devel] Re: Explanation for bob.pad.face

Mohameeed Chaouche

unread,
Aug 10, 2018, 8:07:59 AM8/10/18
to bob-...@googlegroups.com
Hey Amir,

No , in extracted and preprocessed directories there is (devel,test,train) directories only,and in each one of the three there is attack and real directories , i will share the tree in a second .

Thank you


On Aug 10, 2018 12:40, "Amir Mohammadi" <183....@gmail.com> wrote:
Can you please share the file path of one of these .hdf5 files so we know exactly which one you are talking about?

Is it in the `preprocessed` directory or in the `extracted` directory?

On Fri, Aug 10, 2018 at 12:35 PM Mohameeed Chaouche <mohamed.c...@gmail.com> wrote:
I have opened the directory and see several .hdf5 files , i dont know how to make use of that ? 

On Aug 10, 2018 12:30 PM, "Amir Mohammadi" <183....@gmail.com> wrote:
> Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

No you don't get an .hdf5 file for each video. You get several. Each in different directories. Which one are you talking about?

On Fri, Aug 10, 2018 at 12:16 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
Allright, i remember that one, Thank you !

Afterwards , i know that i will have the .hdf5 files for each .mov video in the REPLAY-ATTACK dataset containing for each frame  an array containing 58 rows each row containing numbers ( 0.0075422 , 0.0057232):

1-what those numbers represent ?
2-how can i implement the output files in a facial recognition system ? (i see that bob.bio.face does that)
3-is it possible to use other feature extraction methods i see that in (antispoofing.lbp) there is HOG method as well , what other methods can i test as well, for example (GLCM) ?


Thank you very much !

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

Mohameed Chaouche

unread,
Aug 10, 2018, 8:33:00 AM8/10/18
to bob-devel
here is the tree file
tree.txt

Mohameed Chaouche

unread,
Aug 10, 2018, 8:40:37 AM8/10/18
to bob-devel
now my question is how to make use of this data , to avoid replay-attacks.. thats where i am stuck at the moment

Pavel Korshunov

unread,
Aug 10, 2018, 8:58:48 AM8/10/18
to bob-...@googlegroups.com
Hi,

It looks like you have only finished preprocessing and extraction stages of your experiment, which led to  'preprocessed' and 'extracted' folders with intermediate results. Did you stop the experiment half way? Normally, you should also have Projector.hdf5 file in your 'lbp-svm-test' and 'projected' folder. Then, the scores will be computed and, by default, saved in '../results/lbp-svm-test' folder. The scores will be in text format and you can use them to compute error rates and other statistics of your experiment. 
So, you should probably just let your experiment finish and you will have the results. 

P.S. Also, what version of Matlab are you using?
cheers,
Pavel

On Fri, Aug 10, 2018 at 2:40 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
now my question is how to make use of this data , to avoid replay-attacks.. thats where i am stuck at the moment

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameeed Chaouche

unread,
Aug 10, 2018, 9:20:53 AM8/10/18
to bob-...@googlegroups.com
Hello pavel i am not using Matlab , i am on a linux machine and to read the hdf5 file i am using an open source program on linux.

How can i use the result afterwards ? To impliment it on a facial recognition system 


On Aug 10, 2018 14:58, "Pavel Korshunov" <pave...@gmail.com> wrote:
Hi,

It looks like you have only finished preprocessing and extraction stages of your experiment, which led to  'preprocessed' and 'extracted' folders with intermediate results. Did you stop the experiment half way? Normally, you should also have Projector.hdf5 file in your 'lbp-svm-test' and 'projected' folder. Then, the scores will be computed and, by default, saved in '../results/lbp-svm-test' folder. The scores will be in text format and you can use them to compute error rates and other statistics of your experiment. 
So, you should probably just let your experiment finish and you will have the results. 

P.S. Also, what version of Matlab are you using?
cheers,
Pavel

On Fri, Aug 10, 2018 at 2:40 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
now my question is how to make use of this data , to avoid replay-attacks.. thats where i am stuck at the moment

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+unsubscribe@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+unsubscribe@googlegroups.com.

Pavel Korshunov

unread,
Aug 10, 2018, 9:26:59 AM8/10/18
to bob-...@googlegroups.com
Sorry, I meant which version of Python you are using.

Anyway, these results will just tell you how well the specific toolchain (features plus algorithm) are performing on the specific database. To implement such detection in a practical system, you would need to adapt the tools and algorithm used in the experiment into real-time system, i.e., capture video from the camera, process the video, extract features, used pre-trained classifier to classifier, apply threshold, etc. We do not have such real-time implementation, since we focus on research type of evaluations on public databases.


On Fri, Aug 10, 2018 at 3:20 PM Mohameeed Chaouche <mohamed.c...@gmail.com> wrote:
Hello pavel i am not using Matlab , i am on a linux machine and to read the hdf5 file i am using an open source program on linux.

How can i use the result afterwards ? To impliment it on a facial recognition system 

On Aug 10, 2018 14:58, "Pavel Korshunov" <pave...@gmail.com> wrote:
Hi,

It looks like you have only finished preprocessing and extraction stages of your experiment, which led to  'preprocessed' and 'extracted' folders with intermediate results. Did you stop the experiment half way? Normally, you should also have Projector.hdf5 file in your 'lbp-svm-test' and 'projected' folder. Then, the scores will be computed and, by default, saved in '../results/lbp-svm-test' folder. The scores will be in text format and you can use them to compute error rates and other statistics of your experiment. 
So, you should probably just let your experiment finish and you will have the results. 

P.S. Also, what version of Matlab are you using?
cheers,
Pavel

On Fri, Aug 10, 2018 at 2:40 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
now my question is how to make use of this data , to avoid replay-attacks.. thats where i am stuck at the moment

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameeed Chaouche

unread,
Aug 10, 2018, 9:27:01 AM8/10/18
to bob-...@googlegroups.com
And its not done yet its still running . But i still have no idea what to do with the results ?

Mohameeed Chaouche

unread,
Aug 10, 2018, 9:31:55 AM8/10/18
to bob-...@googlegroups.com
Okay i get it now , for example i want to replace the videos in the training set with camera frames and provide the model to a machine learning algorithme to apply it on a camera frames

Pavel Korshunov

unread,
Aug 10, 2018, 9:41:42 AM8/10/18
to bob-...@googlegroups.com
yes, something like that, but may be just replace the videos in the evaluation set with the camera frames, so that you can use algorithm trained on the training set to evaluate the frames of the camera. But you got the general idea. 

On Fri, Aug 10, 2018 at 3:31 PM Mohameeed Chaouche <mohamed.c...@gmail.com> wrote:
Okay i get it now , for example i want to replace the videos in the training set with camera frames and provide the model to a machine learning algorithme to apply it on a camera frames
On Aug 10, 2018 15:27, "Mohameeed Chaouche" <mohamed.c...@gmail.com> wrote:
And its not done yet its still running . But i still have no idea what to do with the results ?

On Aug 10, 2018 15:20, "Mohameeed Chaouche" <mohamed.c...@gmail.com> wrote:
Hello pavel i am not using Matlab , i am on a linux machine and to read the hdf5 file i am using an open source program on linux.

How can i use the result afterwards ? To impliment it on a facial recognition system 

On Aug 10, 2018 14:58, "Pavel Korshunov" <pave...@gmail.com> wrote:
Hi,

It looks like you have only finished preprocessing and extraction stages of your experiment, which led to  'preprocessed' and 'extracted' folders with intermediate results. Did you stop the experiment half way? Normally, you should also have Projector.hdf5 file in your 'lbp-svm-test' and 'projected' folder. Then, the scores will be computed and, by default, saved in '../results/lbp-svm-test' folder. The scores will be in text format and you can use them to compute error rates and other statistics of your experiment. 
So, you should probably just let your experiment finish and you will have the results. 

P.S. Also, what version of Matlab are you using?
cheers,
Pavel

On Fri, Aug 10, 2018 at 2:40 PM Mohameed Chaouche <mohamed.c...@gmail.com> wrote:
now my question is how to make use of this data , to avoid replay-attacks.. thats where i am stuck at the moment

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
-- You received this message because you are subscribed to the Google Groups bob-devel group. To post to this group, send email to bob-...@googlegroups.com. To unsubscribe from this group, send email to bob-devel+...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/bob-devel or directly the project website at http://idiap.github.com/bob/

---
You received this message because you are subscribed to the Google Groups "bob-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bob-devel+...@googlegroups.com.

Mohameed Chaouche

unread,
Aug 10, 2018, 9:55:55 AM8/10/18
to bob-devel
yes, i know that the trained model will be able to make difference between and image and a real face for example using the LBP algorithme.

what i am trying to know is when i use the command (spoof.py replay-attack lbp-svm --sub-directory ~/lbp-svm-test) , what file (the trained model) should i pass as an argument to a face detection method in a script that captures frames so it can use it to make the difference between a real person and spoof attack ?

and for the python version i am using the (bob_py3 virtual environment) so it should be python 3.6 as u can see in the picture above.
python_version.JPG

Mohameed Chaouche

unread,
Aug 10, 2018, 10:05:04 AM8/10/18
to bob-devel
okay , i found something that i seem to understand finally i hope i am right , here in the picture below the array 63x63 pixels contains LBP values varies from (0-256) so each pixel contains a value from the picture(frame) and we do the same thing for each frame and store the whole data in an hdf5 file, am i right ?
lbp_array.JPG

Pavel Korshunov

unread,
Aug 10, 2018, 10:18:54 AM8/10/18
to bob-...@googlegroups.com
After the training is finished, the classifier model will be saved in Projector.hdf5 file. This file you should be using in your real-time attack detection system.

--

Mohameed Chaouche

unread,
Aug 10, 2018, 10:32:24 AM8/10/18
to bob-devel
Great ! thank you Pavel ! i will keep you guys updated

547928057

unread,
Aug 10, 2018, 11:29:47 AM8/10/18
to bob-devel
Hello A:
   I have carried out the first step successfully, "spoof.py lbp-svm --subdirectory".
When I do the step two:
evaluate.py \
--dev-files  <PATH_TO_STORE_THE_RESULTS>/grandtest/scores/scores-dev  \
--eval-files <PATH_TO_STORE_THE_RESULTS>/grandtest/scores/scores-eval \
--legends "LBP features of facial region + SVM classifier + Replay-Mobile database" \
-F 7 \
--criterion EER \
--roc <PATH_TO_STORE_THE_RESULTS>/ROC.pdf
An error has occurred for picture in appendix. ImportError: cannot import name "histograms".   I guess is that a python API  is not installed.
BUt I don't know how to resolve this problem.  The statement in error is following:


from . import (histograms, metrics, det, fmr_iapmr, epc)
from .. import (far_threshold, plot, utils, ppndf)
------------------ 原始邮件 ------------------
发件人: "Mohameed Chaouche"<mohamed.c...@gmail.com>;
发送时间: 2018年8月10日(星期五) 晚上6:45
收件人: "bob-devel"<bob-...@googlegroups.com>;
主题: [bob-devel] Re: Explanation for bob.pad.face
Screenshot from 2018-08-10 20-10-09.png

Manuel Günther

unread,
Aug 10, 2018, 11:35:56 AM8/10/18
to bob-devel
Mohameed,

the files in the preprocessed directory are the results of the preprocessing step. If your preprocessor extracts LBP then, yes, these files contain LBP patterns extracted from the images/video frames. Depending on which extractor you used, you will see the results of your extractor in the extracted directory. And so on.

Which types of preprocessors, extractors and algorithms you use depend heavily on the employed processing tool chain. There is actually a command that will tell you -- based on tools that you use on the command line (e.g., lbp-svm in your case), where the configuration files are. I guess that this command has changed lately, so maybe Amir can tell you more about that.

Manuel

Amir Mohammadi

unread,
Aug 10, 2018, 11:38:15 AM8/10/18
to bob-...@googlegroups.com
Hi 547928057,

Please use a separate thread for your questions.
To learn how to evaluate your PAD results, please see

Amir

Manuel Günther

unread,
Aug 10, 2018, 11:39:01 AM8/10/18
to bob-devel
This looks like you have an old version of bob installed, or the different bob packages do not match. Can you try to do a fresh conda installation of Bob and try again: https://www.idiap.ch/software/bob/docs/bob/docs/stable/bob/doc/install.html

Manuel

547928057

unread,
Aug 10, 2018, 12:55:26 PM8/10/18
to bob-devel
Hello A:
I reinstalled conda and bob, however, same problem as last time.
1.My configuration is as follows:
Anaconda3  python3.6.6  conda-4.5.9  bob5.0.0, then execute following two steps as https://www.idiap.ch/software/bob/docs/bob/docs/stable/bob/doc/install.html
$ conda update -n base conda
$ conda config --set show_channel_urls True
$ conda create --name bob_py3 --override-channels \
  -c https://www.idiap.ch/software/bob/conda -c defaults \
  python=3 bob
$ conda activate bob_py3
$ conda config --env --add channels defaults
$ conda config --env --add channels https://www.idiap.ch/software/bob/conda
2. I install the only two package for avoiding different bob packages do not match:
$  conda install bob.pad.face bob.db.replay
3. LBP features of facial region + SVM classifier
$ spoof.py replay-attack lbp-svm \
--sub-directory <PATH_TO_STORE_THE_RESULTS> \
--grid idiap...............ok

$ python bob_py3/lib/python3.6/site-packages/bob/pad/base/script/evaluate.py \
--dev-files results1/grandtest/scores/scores-dev \
--eval-files results1/grandtest/scores/scores-eval \
--legends "LBP features of facial region + SVM classifier + REPLAY-ATTACK database" \
-F 7 --criterion EER \
--roc results1/ROC.pdf...................error:
Traceback (most recent call last):
File "/home/ajian/anaconda3/envs/bob_py3/lib/python3.6/site-packages/bob/pad/base/script/evaluate.py", line 8, in <module>

from . import (histograms, metrics, det, fmr_iapmr, epc)
ImportError: cannot import name 'histograms'

4.Some packages' version information in appendix.
------------------ 原始邮件 ------------------
发件人: "bob-devel"<bob-...@googlegroups.com>;
发送时间: 2018年8月10日(星期五) 晚上11:39
收件人: "bob-devel"<bob-...@googlegroups.com>;
主题: Re: 回复:[bob-devel] Re: Explanation for bob.pad.face

This looks like you have an old version of bob installed, or the different bob packages do not match. Can you try to do a fresh conda installation of Bob and try again: https://www.idiap.ch/software/bob/docs/bob/docs/stable/bob/doc/install.html

Manuel

--
Screenshot from 2018-08-11 00-43-43.png

Manuel Günther

unread,
Aug 10, 2018, 1:44:51 PM8/10/18
to bob-devel
We lately modified the way that the evaluation is performed. Please follow the tip of Amir and read the updated documentation: https://www.idiap.ch/software/bob/docs/bob/docs/stable/bob.pad.base/doc/experiments.html#evaluating-experiments

@Amir: I assume that you forgot to delete the evaluate.py script from the package after changing to the click scripts. I will check and open a ticket.

Manuel

547928057

unread,
Aug 10, 2018, 2:13:33 PM8/10/18
to bob-devel
Thanks!


------------------ 原始邮件 ------------------
发件人: "bob-devel"<bob-...@googlegroups.com>;
发送时间: 2018年8月11日(星期六) 凌晨1:44
收件人: "bob-devel"<bob-...@googlegroups.com>;
主题: Re: 回复: 回复:[bob-devel] Re: Explanation for bob.pad.face

We lately modified the way that the evaluation is performed. Please follow the tip of Amir and read the updated documentation: https://www.idiap.ch/software/bob/docs/bob/docs/stable/bob.pad.base/doc/experiments.html#evaluating-experiments

@Amir: I assume that you forgot to delete the evaluate.py script from the package after changing to the click scripts. I will check and open a ticket.

Manuel

--

547928057

unread,
Aug 17, 2018, 4:06:35 AM8/17/18
to 刘阿建
Hello A:
when I execute the evaluation step of :
bob pad metrics -v -c eer ~/results/grandtest/scores/scores-dev
when the code locates in bob/measure/utils.py, I can't find the resource code of function err_threshold(neg,pos).
where is the function of err_threshold
Thanks



------------------ 原始邮件 ------------------
发件人: "刘阿建"<5479...@qq.com>;
发送时间: 2018年8月11日(星期六) 凌晨2:13
收件人: "bob-devel"<bob-...@googlegroups.com>;
主题: 回复: 回复: 回复:[bob-devel] Re: Explanation for bob.pad.face

Manuel Günther

unread,
Aug 17, 2018, 8:05:56 PM8/17/18
to bob-devel
For performance reasons, this function is implemented in C++ and bound to Python. You can find its implementation here: https://gitlab.idiap.ch/bob/bob.measure/blob/a5aa37c34401a787017113d610656f57af9fc24f/bob/measure/cpp/error.cpp#L93, where the minimizingThreshold function is implemented in the header file: https://gitlab.idiap.ch/bob/bob.measure/blob/a5aa37c34401a787017113d610656f57af9fc24f/bob/measure/cpp/error.h#L150

In case you are also interested in the binding code (which I seriously doubt, but nevertheless), look here: https://gitlab.idiap.ch/bob/bob.measure/blob/a5aa37c34401a787017113d610656f57af9fc24f/bob/measure/main.cpp#L361

Manuel
Reply all
Reply to author
Forward
0 new messages