Running baselines in grandtest protocol of WMCA =============================================== In the baseline experiments, initially experiments are done separately for all four channels and score fusion is performed. Running experiments for each channel is described below. The feature based baselines implemented are Image Quality Measure + Logistic Regression (IQM+LR), Local Binary Pattern + Logistic Regression (LBP+LR), and Haralick-RDWT-SVM (H-SVM). For the baselines using Haralick-SVM you need to have mahotas packsge. It is available from conda-forge channel and can be installed as .. code-block:: sh conda install -c https://conda.anaconda.org/conda-forge mahotas The steps to reproduce the results for grandtest protocol are listed below. A. Color channel ---------------- 1.A.1. IQM - LR .. code-block:: sh ./bin/spoof.py \ wmca-color \ iqm-lr \ --sub-directory /color/ -vvv --grid idiap python bin/scoring.py -df \ /color/grandtest-color-50/scores/scores-dev -ef \ /color/grandtest-color-50/scores/scores-eval 1.A.2 Haralick- SVM .. code-block:: sh ./bin/spoof.py \ wmca-color \ haralick-svm \ --skip-preprocessing \ --preprocessed-directory /color/preprocessed \ --sub-directory /color/haralicksvm/ -vvv --grid idiap python bin/scoring.py -df \ /color/haralicksvm/grandtest-color-50/scores/scores-dev -ef \ /color/haralicksvm/grandtest-color-50/scores/scores-eval B. Depth channel ---------------- 1.B.1 LBP-LR .. code-block:: sh ./bin/spoof.py \ wmca-depth \ lbp-lr-depth \ --sub-directory /depth/ -vvv --grid idiap python bin/scoring.py -df \ /depth/grandtest-depth-50/scores/scores-dev -ef \ /depth/grandtest-depth-50/scores/scores-eval 1.B.2 Haralick SVM .. code-block:: sh ./bin/spoof.py \ wmca-depth \ haralick-svm \ --skip-preprocessing \ --preprocessed-directory /depth/preprocessed \ --sub-directory /depth/haralicksvm/ -vvv --grid idiap python bin/scoring.py -df \ /depth/haralicksvm/grandtest-depth-50/scores/scores-dev -ef \ /depth/haralicksvm/grandtest-depth-50/scores/scores-eval C. Infrared channel ------------------- 1.C.1 LBP-LR .. code-block:: sh ./bin/spoof.py \ wmca-infrared \ lbp-lr-infrared \ --sub-directory /infrared/ -vvv --grid idiap 1.C.2 Haralick SVM .. code-block:: sh ./bin/spoof.py \ wmca-infrared \ haralick-svm \ --skip-preprocessing \ --preprocessed-directory /infrared/preprocessed \ --sub-directory /infrared/haralicksvm/ -vvv --grid idiap python bin/scoring.py -df \ /infrared/haralicksvm/grandtest-infrared-50/scores/scores-dev -ef \ /infrared/haralicksvm/grandtest-infrared-50/scores/scores-eval D. Thermal channel ------------------ 1.D.1 LBP-LR .. code-block:: sh ./bin/spoof.py \ wmca-thermal \ lbp-lr-thermal \ --sub-directory /thermal/ -vvv --grid idiap python bin/scoring.py -df \ /thermal/grandtest-thermal-50/scores/scores-dev -ef \ /thermal/grandtest-thermal-50/scores/scores-eval 1.D.2 Haralick SVM .. code-block:: sh ./bin/spoof.py \ wmca-thermal \ haralick-svm \ --skip-preprocessing \ --preprocessed-directory /thermal/preprocessed \ --sub-directory /thermal/haralicksvm/ -vvv --grid idiap python bin/scoring.py -df \ /thermal/haralicksvm/grandtest-thermal-50/scores/scores-dev -ef \ /thermal/haralicksvm/grandtest-thermal-50/scores/scores-eval E. Score fusion (Haralick-SVM) ------------------------------ .. code-block:: sh ./bin/python bin/mean_fusion.py -c \ /color/haralicksvm/grandtest-color-50/scores/scores-dev -s \ /mean_fusion/grandtest/haralick/ python bin/scoring.py -df \ /mean_fusion/grandtest/haralick/scores_mean_fused_dev -ef \ /mean_fusion/grandtest/haralick/scores_mean_fused_eval F. Score fusion (IQM-LBP-LR) ---------------------------- .. code-block:: sh ./bin/python bin/mean_fusion.py -c \ /color/grandtest-color-50/scores/scores-dev -s \ /mean_fusion/grandtest/ python bin/scoring.py -df \ /mean_fusion/grandtest/scores_mean_fused_dev -ef \ /mean_fusion/grandtest/scores_mean_fused_eval BASELINES in LOO protocols (for score fusion) ============================================= For the experiments first do individual experiments for all channels, after that perform fusion. This needs to be repeated for all the protocols A. Color -------- unseen_protocols=['','-LOO_fakehead','-LOO_flexiblemask','-LOO_glasses','-LOO_papermask','-LOO_prints','-LOO_replay','-LOO_rigidmask'] The protocols can be easily indexed as PROTOCOL = 'grandtest-color-50'+unseen_protocols[0] .. code-block:: sh ./bin/spoof.py \ wmca-color \ iqm-lr \ --protocol grandtest-color-50-LOO_fakehead \ --skip-preprocessing --skip-extraction --skip-extractor-training --allow-missing-files \ --extracted-directory /color/extracted/ \ --grid idiap \ --sub-directory /LOO/color/grandtest-color-50-LOO_fakehead/ B. Depth -------- .. code-block:: sh ./bin/spoof.py \ wmca-depth \ lbp-lr-depth \ --protocol grandtest-depth-50-LOO_fakehead \ --skip-preprocessing --skip-extraction --skip-extractor-training --allow-missing-files \ --extracted-directory /depth/extracted/ \ --grid idiap \ --sub-directory /LOO/depth/grandtest-depth-50-LOO_fakehead/ C. Infrared ----------- .. code-block:: sh ./bin/spoof.py \ wmca-infrared \ lbp-lr-infrared \ --protocol grandtest-infrared-50-LOO_fakehead \ --skip-preprocessing --skip-extraction --skip-extractor-training --allow-missing-files \ --extracted-directory /infrared/extracted/ \ --grid idiap \ --sub-directory /LOO/infrared/grandtest-infrared-50-LOO_fakehead/ D. Thermal ---------- .. code-block:: sh ./bin/spoof.py \ wmca-thermal \ lbp-lr-thermal \ --protocol grandtest-thermal-50-LOO_fakehead \ --skip-preprocessing --skip-extraction --skip-extractor-training --allow-missing-files \ --extracted-directory /thermal/extracted/ \ --grid idiap \ --sub-directory /LOO/thermal/grandtest-thermal-50-LOO_fakehead/ E. Score fusion --------------- The protocols are, '-LOO_fakehead','-LOO_flexiblemask','-LOO_glasses','-LOO_papermask','-LOO_prints','-LOO_replay','-LOO_rigidmask' .. code-block:: sh ./bin/python bin/mean_fusion.py -c \ /LOO/color/grandtest-color-50-LOO_fakehead/grandtest-color-50-LOO_fakehead/scores/scores-dev .. code-block:: sh python bin/scoring.py -df \ /mean_fusion/grandtest-color-50-LOO_fakehead/fusionmine/scores_mean_fused_dev -ef \ /mean_fusion/grandtest-color-50-LOO_fakehead/fusionmine/scores_mean_fused_eval Similarly, repeat the experiment for all protocols. BASELINES in LOO protocols (Haralick-SVM) ========================================= Color ----- .. code-block:: sh ./bin/spoof.py wmca-color haralick-svm --protocol grandtest-color-50-LOO_fakehead --skip-preprocessing --skip-extraction --skip-extractor-training --allow-missing-files --extracted-directory /color/haralicksvm/extracted/ --grid idiap --sub-directory /LOO/color/haralicksvm/grandtest-color-50-LOO_fakehead/ Repeat the same procedure for all four channels. Score fusion Haralick-SVM ------------------------- Once scores from all channels are available. Run the following command. .. code-block:: sh ./bin/python bin/mean_fusion.py -c /LOO/color/haralicksvm/grandtest-color-50-LOO_fakehead/grandtest-color-50-LOO_fakehead/scores/scores-dev -s /mean_fusion/haralick/grandtest-color-50-LOO_fakehead/ Scoring for Haralick Mean fusion -------------------------------- .. code-block:: sh python bin/scoring.py -df /mean_fusion/haralick/grandtest-color-50-LOO_fakehead/scores_mean_fused_dev -ef /mean_fusion/haralick/grandtest-color-50-LOO_fakehead/scores_mean_fused_eval Similarly, repeat the experiment for all LOO sub-protocols.