feat: Add pose mode analysis and face width detection for improved profile classification
This commit introduces a comprehensive analysis of pose modes and face width detection to enhance profile classification accuracy. New scripts have been added to analyze pose data in the database, check identified faces for pose information, and validate yaw angles. The PoseDetector class has been updated to calculate face width from landmarks, which serves as an additional indicator for profile detection. The frontend and API have been modified to include pose mode in responses, ensuring better integration with existing functionalities. Documentation has been updated to reflect these changes, improving user experience and accuracy in face processing.
This commit is contained in:
@@ -20,6 +20,7 @@ export interface FaceItem {
|
||||
quality_score: number
|
||||
face_confidence: number
|
||||
location: string
|
||||
pose_mode?: string
|
||||
}
|
||||
|
||||
export interface UnidentifiedFacesResponse {
|
||||
@@ -36,6 +37,7 @@ export interface SimilarFaceItem {
|
||||
location: string
|
||||
quality_score: number
|
||||
filename: string
|
||||
pose_mode?: string
|
||||
}
|
||||
|
||||
export interface SimilarFacesResponse {
|
||||
|
||||
@@ -275,7 +275,7 @@ export default function AutoMatch() {
|
||||
className="px-4 py-2 bg-blue-600 text-white rounded hover:bg-blue-700 disabled:bg-gray-400 disabled:cursor-not-allowed"
|
||||
title={hasNoResults ? 'No matches found. Adjust tolerance or process more photos.' : ''}
|
||||
>
|
||||
{busy ? 'Processing...' : hasNoResults ? 'No Matches Available' : '🚀 Start Auto-Match'}
|
||||
{busy ? 'Processing...' : hasNoResults ? 'No Matches Available' : '🚀 Run Auto-Match'}
|
||||
</button>
|
||||
<div className="flex items-center gap-2">
|
||||
<label className="text-sm font-medium text-gray-700">Auto-Accept Threshold:</label>
|
||||
|
||||
@@ -472,6 +472,12 @@ export default function Identify() {
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
{/* Pose mode display */}
|
||||
{currentFace.pose_mode && (
|
||||
<div className="mb-2 text-sm text-gray-600">
|
||||
<span className="font-medium">Pose:</span> {currentFace.pose_mode}
|
||||
</div>
|
||||
)}
|
||||
<div className="grid grid-cols-2 gap-2">
|
||||
<div className="col-span-2">
|
||||
<label className="block text-sm font-medium text-gray-700">Select Existing Person (optional)</label>
|
||||
@@ -668,6 +674,13 @@ export default function Identify() {
|
||||
{confidencePct}% {confidenceDesc}
|
||||
</div>
|
||||
|
||||
{/* Pose mode */}
|
||||
{s.pose_mode && (
|
||||
<div className="text-sm text-gray-600 flex-shrink-0">
|
||||
{s.pose_mode}
|
||||
</div>
|
||||
)}
|
||||
|
||||
{/* Filename */}
|
||||
<div className="text-sm text-gray-700 flex-1 min-w-0 truncate" title={s.filename}>
|
||||
{s.filename}
|
||||
|
||||
Reference in New Issue
Block a user