Skip to content

Implement batch scoring and enhance existing methods#58

Open
krataratha wants to merge 1 commit into
pterhoer:masterfrom
krataratha:patch-1
Open

Implement batch scoring and enhance existing methods#58
krataratha wants to merge 1 commit into
pterhoer:masterfrom
krataratha:patch-1

Conversation

@krataratha

Copy link
Copy Markdown

Added get_scores_batch method to calculate SER-FIQ scores for a batch of aligned images efficiently. Updated apply_mtcnn and get_score methods for better functionality.

Added get_scores_batch method to calculate SER-FIQ scores for a batch of aligned images efficiently. Updated apply_mtcnn and get_score methods for better functionality.
Copilot AI review requested due to automatic review settings June 18, 2026 03:09

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to extend the SER_FIQ interface to support efficient SER-FIQ scoring for multiple aligned face images in one call, while also updating/duplicating existing scoring and MTCNN-alignment-related methods.

Changes:

  • Added get_scores_batch(...) to compute SER-FIQ scores for a batch of aligned images by batching forward passes.
  • Added/updated a get_score(...) implementation adjacent to the new batch method.
  • Introduced an apparent duplicated/partial copy of __init__, apply_mtcnn, and get_score content in the class body (currently breaking the module).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread face_image_quality.py
Comment on lines +218 to +221
return scores
gpu:int=0, # Which gpu should be used -> gpu id
det:int=0, # Mtcnn option, 1= Use R+O, 0=Detect from beginning
):
Comment thread face_image_quality.py
Comment on lines +123 to +126
def get_score(self, aligned_img : np.ndarray,
T : int = 100,
alpha : float = 130.0,
r : float = 0.88):
Comment thread face_image_quality.py
T : int, optional
Amount of forward passes to use. The default is 100.
alpha : float, optional
Stretching factor, can be choosen to scale the score values
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants