From 0e4a681c5832a0c31f46afaa5e2a175bcb6512f1 Mon Sep 17 00:00:00 2001 From: Guillaume HEUSCH <guillaume.heusch@idiap.ch> Date: Wed, 16 Jan 2019 11:36:17 +0100 Subject: [PATCH] [database] casiasurf: added the necessary parameters in the CasiaPadFile init, to be compliant with super class(es) --- bob/pad/face/database/casiasurf.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/bob/pad/face/database/casiasurf.py b/bob/pad/face/database/casiasurf.py index 9c609fb4..a77b3ee2 100644 --- a/bob/pad/face/database/casiasurf.py +++ b/bob/pad/face/database/casiasurf.py @@ -24,22 +24,24 @@ class CasiaSurfPadFile(VideoPadFile): """ - def __init__(self, f, stream_type, attack_type): + def __init__(self, s, stream_type): """ Init Parameters ---------- - f : :py:class:`object` + s : :py:class:`object` An instance of the Sample class defined in the low level db interface of the CASIA-SURF database, in the bob.db.casiasurf.models.py file. stream_type: str of list of str The streams to be loaded. """ - self.f = f + self.path = None + self.s = s self.stream_type = stream_type super(CasiaSurfPadFile, self).__init__( - client_id=f.id, - attack_type=attack_type) + client_id=s.id, + attack_type=s.attack_type, + path=None) def load(self, directory=None, extension='.jpg', frame_selector=FrameSelector(selection_style='all')): @@ -175,7 +177,7 @@ class CasiaSurfPadDatabase(PadDatabase): lowlevel_purposes.append('unknown') samples = self.db.objects(groups=groups, purposes=lowlevel_purposes, **kwargs) - samples = [CasiaSurfPadFile(s, stream_type=protocol, attack_type=s.attack_type) for s in samples] + samples = [CasiaSurfPadFile(s, stream_type=protocol) for s in samples] return samples -- GitLab