[mob][photos] Merge issues
This commit is contained in:
@@ -190,7 +190,7 @@ class MLIndexingIsolate {
|
||||
Future<MLResult?> analyzeImage(
|
||||
FileMLInstruction instruction,
|
||||
) async {
|
||||
final String filePath = await getImagePathForML(instruction.enteFile);
|
||||
final String filePath = await getImagePathForML(instruction.file);
|
||||
|
||||
final Stopwatch stopwatch = Stopwatch()..start();
|
||||
late MLResult result;
|
||||
@@ -200,7 +200,7 @@ class MLIndexingIsolate {
|
||||
(
|
||||
MLIndexingOperation.analyzeImage,
|
||||
{
|
||||
"enteFileID": instruction.enteFile.uploadedFileID ?? -1,
|
||||
"enteFileID": instruction.file.uploadedFileID ?? -1,
|
||||
"filePath": filePath,
|
||||
"runFaces": instruction.shouldRunFaces,
|
||||
"runClip": instruction.shouldRunClip,
|
||||
@@ -221,21 +221,21 @@ class MLIndexingIsolate {
|
||||
result = MLResult.fromJsonString(resultJsonString);
|
||||
} catch (e, s) {
|
||||
_logger.severe(
|
||||
"Could not analyze image with ID ${instruction.enteFile.uploadedFileID} \n",
|
||||
"Could not analyze image with ID ${instruction.file.uploadedFileID} \n",
|
||||
e,
|
||||
s,
|
||||
);
|
||||
debugPrint(
|
||||
"This image with ID ${instruction.enteFile.uploadedFileID} has name ${instruction.enteFile.displayName}.",
|
||||
"This image with ID ${instruction.file.uploadedFileID} has name ${instruction.file.displayName}.",
|
||||
);
|
||||
final resultBuilder =
|
||||
MLResult.fromEnteFileID(instruction.enteFile.uploadedFileID!)
|
||||
MLResult.fromEnteFileID(instruction.file.uploadedFileID!)
|
||||
..errorOccurred();
|
||||
return resultBuilder;
|
||||
}
|
||||
stopwatch.stop();
|
||||
_logger.info(
|
||||
"Finished Analyze image with uploadedFileID ${instruction.enteFile.uploadedFileID}, in "
|
||||
"Finished Analyze image with uploadedFileID ${instruction.file.uploadedFileID}, in "
|
||||
"${stopwatch.elapsedMilliseconds} ms (including time waiting for inference engine availability)",
|
||||
);
|
||||
|
||||
|
||||
@@ -14,6 +14,7 @@ import "package:photos/models/file/file.dart";
|
||||
import "package:photos/models/file/file_type.dart";
|
||||
import "package:photos/models/ml/ml_versions.dart";
|
||||
import "package:photos/services/machine_learning/face_ml/face_recognition_service.dart";
|
||||
import "package:photos/services/machine_learning/file_ml/file_ml.dart";
|
||||
import "package:photos/services/machine_learning/ml_exceptions.dart";
|
||||
import "package:photos/services/machine_learning/ml_result.dart";
|
||||
import "package:photos/services/machine_learning/semantic_search/semantic_search_service.dart";
|
||||
|
||||
Reference in New Issue
Block a user