Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • bob.bio.base bob.bio.base
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 16
    • Issues 16
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 2
    • Merge requests 2
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Artifacts
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Terraform modules
    • Model experiments
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • bobbob
  • bob.bio.basebob.bio.base
  • Issues
  • #79
Closed
Open
Issue created Jun 03, 2017 by Manuel Günther@mguentherMaintainer

`Algorithm.read_probe` should not exist

This is something that I had in mind when designing the Algorithm, but which I postponed far too long by now, and it regularly bites me:

In the Algorithm, the read_probe function should not exist. Instead, the according functions of the Extractor.read_feature or Algorithm.read_feature should be called instead. For model enrollment, this is already done: https://gitlab.idiap.ch/bob/bob.bio.base/blob/master/bob/bio/base/tools/algorithm.py#L247

For probes, I was too lazy to implement this correctly, and added an Algorithm.read_probe function instead. In most cases, this works as expected. But when data structures are more complex, then the algorithm needs to know, how to read the features. For example, in bob.bio.face.algoritm.GaborJet, the read_probe function: https://gitlab.idiap.ch/bob/bob.bio.face/blob/master/bob/bio/face/algorithm/GaborJet.py#L204 is an exact copy of the bob.bio.face.extractor.GridGraph.read_feature function: https://gitlab.idiap.ch/bob/bob.bio.face/blob/master/bob/bio/face/extractor/GridGraph.py#L221

The reason, why I was too lazy to implement it correctly is that during scoring, the probes are read in the innermost function: https://gitlab.idiap.ch/bob/bob.bio.base/blob/master/bob/bio/base/tools/scoring.py#L16 and I didn't want to pass the reader through all the function calls. Stupid me. Since now so many more packages have been written, which use the bad implementation, fixing this is a major issue:

  • Fix the scoring script to use the correct reader
  • Remove the read_probe from the Algorithm base class and all derived classes in all packages
  • Fix the verify.py script and all derived scripts to pass the extractor to the scoring function
  • Check all the test cases and assure that Algorithm.read_probe is replaced with the according call to Extractor.read_feature or Algorithm.read_feature
Assignee
Assign to
Time tracking