|
@@ -17,8 +17,6 @@ import {
|
|
ClusteringMethod,
|
|
ClusteringMethod,
|
|
ClusteringService,
|
|
ClusteringService,
|
|
Face,
|
|
Face,
|
|
- FaceAlignmentMethod,
|
|
|
|
- FaceAlignmentService,
|
|
|
|
FaceCropMethod,
|
|
FaceCropMethod,
|
|
FaceCropService,
|
|
FaceCropService,
|
|
FaceDetection,
|
|
FaceDetection,
|
|
@@ -38,7 +36,6 @@ import {
|
|
import { getLocalFiles } from "services/fileService";
|
|
import { getLocalFiles } from "services/fileService";
|
|
import { EnteFile } from "types/file";
|
|
import { EnteFile } from "types/file";
|
|
import { isInternalUserForML } from "utils/user";
|
|
import { isInternalUserForML } from "utils/user";
|
|
-import arcfaceAlignmentService from "./arcfaceAlignmentService";
|
|
|
|
import arcfaceCropService from "./arcfaceCropService";
|
|
import arcfaceCropService from "./arcfaceCropService";
|
|
import FaceService from "./faceService";
|
|
import FaceService from "./faceService";
|
|
import hdbscanClusteringService from "./hdbscanClusteringService";
|
|
import hdbscanClusteringService from "./hdbscanClusteringService";
|
|
@@ -139,16 +136,6 @@ export class MLFactory {
|
|
throw Error("Unknon face crop method: " + method);
|
|
throw Error("Unknon face crop method: " + method);
|
|
}
|
|
}
|
|
|
|
|
|
- public static getFaceAlignmentService(
|
|
|
|
- method: FaceAlignmentMethod,
|
|
|
|
- ): FaceAlignmentService {
|
|
|
|
- if (method === "ArcFace") {
|
|
|
|
- return arcfaceAlignmentService;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- throw Error("Unknon face alignment method: " + method);
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
public static getBlurDetectionService(
|
|
public static getBlurDetectionService(
|
|
method: BlurDetectionMethod,
|
|
method: BlurDetectionMethod,
|
|
): BlurDetectionService {
|
|
): BlurDetectionService {
|
|
@@ -187,7 +174,6 @@ export class LocalMLSyncContext implements MLSyncContext {
|
|
|
|
|
|
public faceDetectionService: FaceDetectionService;
|
|
public faceDetectionService: FaceDetectionService;
|
|
public faceCropService: FaceCropService;
|
|
public faceCropService: FaceCropService;
|
|
- public faceAlignmentService: FaceAlignmentService;
|
|
|
|
public blurDetectionService: BlurDetectionService;
|
|
public blurDetectionService: BlurDetectionService;
|
|
public faceEmbeddingService: FaceEmbeddingService;
|
|
public faceEmbeddingService: FaceEmbeddingService;
|
|
public faceClusteringService: ClusteringService;
|
|
public faceClusteringService: ClusteringService;
|
|
@@ -225,8 +211,6 @@ export class LocalMLSyncContext implements MLSyncContext {
|
|
this.faceDetectionService =
|
|
this.faceDetectionService =
|
|
MLFactory.getFaceDetectionService("YoloFace");
|
|
MLFactory.getFaceDetectionService("YoloFace");
|
|
this.faceCropService = MLFactory.getFaceCropService("ArcFace");
|
|
this.faceCropService = MLFactory.getFaceCropService("ArcFace");
|
|
- this.faceAlignmentService =
|
|
|
|
- MLFactory.getFaceAlignmentService("ArcFace");
|
|
|
|
this.blurDetectionService =
|
|
this.blurDetectionService =
|
|
MLFactory.getBlurDetectionService("Laplacian");
|
|
MLFactory.getBlurDetectionService("Laplacian");
|
|
this.faceEmbeddingService =
|
|
this.faceEmbeddingService =
|