mirror of
https://github.com/immich-app/immich.git
synced 2025-11-26 00:20:47 +09:00
chore(server): duplication default settings (#9781)
This commit is contained in:
@@ -256,8 +256,8 @@ export const defaults = Object.freeze<SystemConfig>({
|
|||||||
modelName: 'ViT-B-32__openai',
|
modelName: 'ViT-B-32__openai',
|
||||||
},
|
},
|
||||||
duplicateDetection: {
|
duplicateDetection: {
|
||||||
enabled: false,
|
enabled: true,
|
||||||
maxDistance: 0.03,
|
maxDistance: 0.0155,
|
||||||
},
|
},
|
||||||
facialRecognition: {
|
facialRecognition: {
|
||||||
enabled: true,
|
enabled: true,
|
||||||
|
|||||||
@@ -214,7 +214,7 @@ describe(SearchService.name, () => {
|
|||||||
expect(searchMock.searchDuplicates).toHaveBeenCalledWith({
|
expect(searchMock.searchDuplicates).toHaveBeenCalledWith({
|
||||||
assetId: assetStub.hasEmbedding.id,
|
assetId: assetStub.hasEmbedding.id,
|
||||||
embedding: assetStub.hasEmbedding.smartSearch!.embedding,
|
embedding: assetStub.hasEmbedding.smartSearch!.embedding,
|
||||||
maxDistance: 0.03,
|
maxDistance: 0.0155,
|
||||||
type: assetStub.hasEmbedding.type,
|
type: assetStub.hasEmbedding.type,
|
||||||
userIds: [assetStub.hasEmbedding.ownerId],
|
userIds: [assetStub.hasEmbedding.ownerId],
|
||||||
});
|
});
|
||||||
@@ -240,7 +240,7 @@ describe(SearchService.name, () => {
|
|||||||
expect(searchMock.searchDuplicates).toHaveBeenCalledWith({
|
expect(searchMock.searchDuplicates).toHaveBeenCalledWith({
|
||||||
assetId: assetStub.hasEmbedding.id,
|
assetId: assetStub.hasEmbedding.id,
|
||||||
embedding: assetStub.hasEmbedding.smartSearch!.embedding,
|
embedding: assetStub.hasEmbedding.smartSearch!.embedding,
|
||||||
maxDistance: 0.03,
|
maxDistance: 0.0155,
|
||||||
type: assetStub.hasEmbedding.type,
|
type: assetStub.hasEmbedding.type,
|
||||||
userIds: [assetStub.hasEmbedding.ownerId],
|
userIds: [assetStub.hasEmbedding.ownerId],
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ describe(ServerInfoService.name, () => {
|
|||||||
it('should respond the server features', async () => {
|
it('should respond the server features', async () => {
|
||||||
await expect(sut.getFeatures()).resolves.toEqual({
|
await expect(sut.getFeatures()).resolves.toEqual({
|
||||||
smartSearch: true,
|
smartSearch: true,
|
||||||
duplicateDetection: false,
|
duplicateDetection: true,
|
||||||
facialRecognition: true,
|
facialRecognition: true,
|
||||||
map: true,
|
map: true,
|
||||||
reverseGeocoding: true,
|
reverseGeocoding: true,
|
||||||
|
|||||||
@@ -81,8 +81,8 @@ const updatedConfig = Object.freeze<SystemConfig>({
|
|||||||
modelName: 'ViT-B-32__openai',
|
modelName: 'ViT-B-32__openai',
|
||||||
},
|
},
|
||||||
duplicateDetection: {
|
duplicateDetection: {
|
||||||
enabled: false,
|
enabled: true,
|
||||||
maxDistance: 0.03,
|
maxDistance: 0.0155,
|
||||||
},
|
},
|
||||||
facialRecognition: {
|
facialRecognition: {
|
||||||
enabled: true,
|
enabled: true,
|
||||||
|
|||||||
@@ -102,7 +102,7 @@
|
|||||||
min={0.001}
|
min={0.001}
|
||||||
max={0.1}
|
max={0.1}
|
||||||
desc="Maximum distance between two images to consider them duplicates, ranging from 0.001-0.1. Higher values will detect more duplicates, but may result in false positives."
|
desc="Maximum distance between two images to consider them duplicates, ranging from 0.001-0.1. Higher values will detect more duplicates, but may result in false positives."
|
||||||
disabled={disabled || $featureFlags.duplicateDetection}
|
disabled={disabled || !$featureFlags.duplicateDetection}
|
||||||
isEdited={config.machineLearning.duplicateDetection.maxDistance !==
|
isEdited={config.machineLearning.duplicateDetection.maxDistance !==
|
||||||
savedConfig.machineLearning.duplicateDetection.maxDistance}
|
savedConfig.machineLearning.duplicateDetection.maxDistance}
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user