Commit 6866c8b1 authored by Yannick DAYER's avatar Yannick DAYER
Browse files

[py] Create protocol files for verafinger and fv3d

Rename the config file

Reorganize the config file
parent fb30cea2
Pipeline #44293 failed with stage
in 7 minutes and 27 seconds
......@@ -12,15 +12,25 @@ the link.
from bob.extension import rc
from ..database.fv3d import Database
from bob.bio.vein.database.fv3d import Database
from bob.bio.base.pipelines.vanilla_biometrics import DatabaseConnector
import logging
logger = logging.getLogger("bob.bio.vein")
# Retrieve directory from config
_fv3d_directory = rc["bob.db.fv3d.directory"]
"""Value in ``~/.bobrc`` for this dataset directory"""
# Set default protocol if not given via a config file
if 'protocol' not in locals():
logger.info("protocol not specified, using default: 'central'")
protocol = 'central'
legacy_database = Database(
original_directory = _fv3d_directory,
original_extension = '.png',
protocol = protocol,
)
"""The :py:class:`bob.bio.base.database.BioDatabase` derivative with fv3d
database settings
......@@ -45,5 +55,5 @@ must make sure to set this value with ``bob config set bob.db.fv3d.directory``
to the place where you actually installed the `3D Fingervein`_ dataset, as
explained in the section :ref:`bob.bio.vein.baselines`.
"""
protocol = 'central' # TODO protocol implementation in bob pipelines?
print(f"protocol is '{protocol}'")
logger.debug(f"Loaded database fv3d config file, using protocol '{protocol}'.")
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:51:16 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> Nom verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> Nom verafinger
# The protocol resource must be specified before the database resource.
# This will be the default protocol if none is specified.
protocol = 'Nom'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:50:47 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> B verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> B verafinger
# The protocol resource must be specified before the database resource.
protocol = 'B'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 10:54:47 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# 3D Fingervein dataset, defined ar bob.db.fv3d.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> central fv3d
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> central fv3d
# The protocol resource must be specified before the database resource.
# This will be the default protocol if none is specified.
protocol = 'central'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:51:02 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> Cropped-Nom verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> Cropped-Nom verafinger
# The protocol resource must be specified before the database resource.
protocol = 'cropped-Nom'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:50:51 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> Cropped-B verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> Cropped-B verafinger
# The protocol resource must be specified before the database resource.
protocol = 'Cropped-B'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:50:54 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> Cropped-Fifty verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> Cropped-Fifty verafinger
# The protocol resource must be specified before the database resource.
protocol = 'Cropped-Fifty'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:50:58 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> Cropped-Full verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> Cropped-Full verafinger
# The protocol resource must be specified before the database resource.
protocol = 'Cropped-Fifty'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:51:06 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> Fifty verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> Fifty verafinger
# The protocol resource must be specified before the database resource.
protocol = 'Fifty'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 14:51:11 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# VeraFinger dataset, defined ar bob.db.verafinger.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> Full verafinger
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> Full verafinger
# The protocol resource must be specified before the database resource.
protocol = 'Full'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 12:14:05 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# 3D Fingervein dataset, defined ar bob.db.fv3d.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> left fv3d
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> left fv3d
# The protocol resource must be specified before the database resource.
protocol = 'left'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 12:14:56 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# 3D Fingervein dataset, defined ar bob.db.fv3d.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> right fv3d
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> right fv3d
# The protocol resource must be specified before the database resource.
protocol = 'right'
# author: Yannick Dayer <yannick.dayer@idiap.ch>
# Fri 16 Oct 2020 12:15:16 UTC+02
# This is a config file for bob.bio.vein
# It defines the database protocol to use with the Database Interface for the
# 3D Fingervein dataset, defined ar bob.db.fv3d.
# It is defined as a resource in the setup file of this package.
# Usage:
# $ bob bio pipelines vanilla-biometrics <pipeline> stitched fv3d
# or:
# $ bob bio pipelines vanilla-biometrics -p <pipeline> stitched fv3d
# The protocol resource must be specified before the database resource.
protocol = 'stitched'
......@@ -17,15 +17,24 @@ the link.
"""
from bob.extension import rc
from ..database.putvein import PutveinBioDatabase
from bob.bio.vein.database.putvein import PutveinBioDatabase
from bob.bio.base.pipelines.vanilla_biometrics import DatabaseConnector
import logging
logger = logging.getLogger("bob.bio.vein")
_putvein_directory = rc["bob.db.putvein.directory"]
"""Value in ``~/.bobrc`` for this dataset directory"""
# Set default protocol if not given via a config file
if 'protocol' not in locals():
logger.info("protocol not specified, using default: 'central'")
protocol = 'central'
legacy_database = PutveinBioDatabase(
original_directory = _putvein_directory,
original_extension = '.bmp',
protocol = protocol,
)
"""The :py:class:`bob.bio.base.database.BioDatabase` derivative with PUT Vein
database settings
......@@ -61,9 +70,4 @@ command-line of ``verify.py`` or using the keyword ``protocol`` on a
configuration file that is loaded **after** this configuration resource.
"""
logger.debug(f"loaded database putvein config file, using protocol '{protocol}'.")
......@@ -18,15 +18,24 @@ You can download the raw data of the `UTFVP`_ database by following the link.
"""
from bob.extension import rc
from ..database.utfvp import Database
from bob.bio.vein.database.utfvp import Database
from bob.bio.base.pipelines.vanilla_biometrics import DatabaseConnector
import logging
logger = logging.getLogger("bob.bio.vein")
_utfvp_directory = rc["bob.db.utfvp.directory"]
"""Value in ``~/.bobrc`` for this dataset directory"""
# Set default protocol if not given via a config file
if 'protocol' not in locals():
logger.info("protocol not specified, using default: 'central'")
protocol = 'central'
legacy_database = Database(
original_directory = _utfvp_directory,
original_extension = '.png',
protocol = protocol,
)
"""The :py:class:`bob.bio.base.database.BioDatabase` derivative with UTFVP settings
"""
......@@ -52,6 +61,4 @@ installed the `utfvp`_ dataset, as explained in the section
:ref:`bob.bio.vein.baselines`.
"""
protocol = 'nom' # TODO protocol implementation in bob pipelines?
logger.debug(f"Loaded database utfvp config file, using protocol '{protocol}'.")
......@@ -16,18 +16,17 @@ from bob.extension import rc
from bob.bio.vein.database.verafinger import Database
from bob.bio.base.pipelines.vanilla_biometrics import DatabaseConnector
import logging
logger = logging.getLogger("bob.bio.vein")
_verafinger_directory = rc["bob.db.verafinger.directory"]
"""Value in ``~/.bobrc`` for this dataset directory"""
protocol = 'Nom' # TODO protocol implementation in bob pipelines?
"""The default protocol to use for tests
# Set default protocol if not given via a config file
if 'protocol' not in locals():
logger.info("protocol not specified, using default: 'central'")
protocol = 'central'
We accept any biometric recognition protocol implemented by bob.db.verafinger.
Variants of the biometric recognition protocol ending in ``-va`` can be used to
test for vulnerability analysis. For example, use the protocol ``Nom-va`` to
test the vulnerability of a biometric recognition pipeline using the ``Nom``
protocol for enrollment and probe samples from presentation attacks.
"""
"""Updated with the wrapper for the pipelines package"""
database = DatabaseConnector(Database(
......@@ -53,3 +52,6 @@ Notice that ``original_directory`` is set to
installed the `vera fingervein`_ dataset, as explained in the section
:ref:`bob.bio.vein.baselines`.
"""
print(f"VERAFINGER: protocol = '{protocol}'.")
logger.debug(f"Loaded database verafinger config file, using protocol '{protocol}'.")
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment