Full-stack application for predicting where humans look in images using DeepGaze saliency models. Includes heatmap overlays, gaze sequence prediction, hotspot detection, AOI analysis, rule-based insights, optional Claude AI design analysis, and professional PDF report generation. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
19 lines
385 B
Python
19 lines
385 B
Python
from abc import ABC, abstractmethod
|
|
|
|
import numpy as np
|
|
from PIL import Image
|
|
|
|
|
|
class BaseSaliencyModel(ABC):
|
|
@abstractmethod
|
|
def load(self) -> None:
|
|
...
|
|
|
|
@abstractmethod
|
|
def predict(self, image: Image.Image) -> np.ndarray:
|
|
"""Returns 2D array (H, W) with values in [0, 1]."""
|
|
...
|
|
|
|
@abstractmethod
|
|
def get_name(self) -> str:
|
|
...
|