Skip to content

gaze

GazeDetectionInferenceResponse

Bases: BaseModel

Response for gaze detection inference.

Attributes:

Name Type Description
predictions List[GazeDetectionPrediction]

List of gaze detection predictions.

time float

The processing time (second).

Source code in inference/core/entities/responses/gaze.py
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
class GazeDetectionInferenceResponse(BaseModel):
    """Response for gaze detection inference.

    Attributes:
        predictions (List[inference.core.entities.responses.gaze.GazeDetectionPrediction]): List of gaze detection predictions.
        time (float): The processing time (second).
    """

    predictions: List[GazeDetectionPrediction]

    time: float = Field(description="The processing time (second)")
    time_face_det: Optional[float] = Field(
        None, description="The face detection time (second)"
    )
    time_gaze_det: Optional[float] = Field(
        None, description="The gaze detection time (second)"
    )

GazeDetectionPrediction

Bases: BaseModel

Gaze Detection prediction.

Attributes:

Name Type Description
face FaceDetectionPrediction

The face prediction.

yaw float

Yaw (radian) of the detected face.

pitch float

Pitch (radian) of the detected face.

Source code in inference/core/entities/responses/gaze.py
 8
 9
10
11
12
13
14
15
16
17
18
19
20
class GazeDetectionPrediction(BaseModel):
    """Gaze Detection prediction.

    Attributes:
        face (inference.core.entities.responses.inference.FaceDetectionPrediction): The face prediction.
        yaw (float): Yaw (radian) of the detected face.
        pitch (float): Pitch (radian) of the detected face.
    """

    face: FaceDetectionPrediction

    yaw: float = Field(description="Yaw (radian) of the detected face")
    pitch: float = Field(description="Pitch (radian) of the detected face")