Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

prettier

Manav Rathi6c8bec0badae
diff --git a/web/packages/new/photos/services/ml/clip.ts b/web/packages/new/photos/services/ml/clip.ts
index c4ccd0fe4b..72de9abedb 100644
--- a/web/packages/new/photos/services/ml/clip.ts
+++ b/web/packages/new/photos/services/ml/clip.ts
@@ -112,8 +112,9 @@ const computeEmbedding = async (
imageData: ImageData,
electron: ElectronMLWorker,
): Promise<Float32Array> => {
- // The image pre-preprocessing happens within the model itself, using ONNX primitives. This is more
- // performant and also saves us from having to reinvent (say) the antialising wheels.
+ // The image pre-preprocessing happens within the model itself, using ONNX
+ // primitives. This is more performant and also saves us from having to
+ // reinvent (say) the antialising wheels.
const { height, width, data: pixelData } = imageData;
const inputShape = [height, width, 4]; // [H, W, C]
return normalized(
diff --git a/web/packages/new/photos/services/ml/face.ts b/web/packages/new/photos/services/ml/face.ts
index f2e96c7775..dda35630af 100644
--- a/web/packages/new/photos/services/ml/face.ts
+++ b/web/packages/new/photos/services/ml/face.ts
@@ -335,10 +335,9 @@ const detectFaces = async (
imageData: ImageData,
electron: ElectronMLWorker,
): Promise<YOLOFaceDetection[]> => {
- // The image pre-preprocessing
- // happens within the model itself, using ONNX primitives. This is more
- // performant and also saves us from having to reinvent (say) the
- // antialising wheels.
+ // The image pre-preprocessing happens within the model itself, using ONNX
+ // primitives. This is more performant and also saves us from having to
+ // reinvent (say) the antialising wheels.
const {
height: imageHeight,
width: imageWidth,
@@ -364,7 +363,8 @@ const detectFaces = async (
};
/**
- * Calculate image scaling done inside ONNX model run preprocessing. Needed to correct the output.
+ * Calculate image scaling done inside ONNX model run preprocessing. Needed to
+ * correct the output.
*/
const getScaledSize = (imageWidth: number, imageHeight: number) => {
const requiredWidth = 640;