dev #1
File diff suppressed because one or more lines are too long
@ -462,8 +462,6 @@ func (r *ingestRepository) RetryJob(ctx context.Context, id uint32) error {
|
|||||||
}).Error
|
}).Error
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// FindNearDuplicateImage 在给定图片表中按 dHash 汉明距离检索近重复,取距离 ≤ threshold 的最近一条。
|
// FindNearDuplicateImage 在给定图片表中按 dHash 汉明距离检索近重复,取距离 ≤ threshold 的最近一条。
|
||||||
// 算子用 pgvector 的 L2(<->);因 phash 是 {0,1}^64 向量,L2² == 汉明距离,故 L2 阈值 = sqrt(threshold)。
|
// 算子用 pgvector 的 L2(<->);因 phash 是 {0,1}^64 向量,L2² == 汉明距离,故 L2 阈值 = sqrt(threshold)。
|
||||||
// phashBits 为 vector(64) 二进制向量串;NULL 的 phash 不参与比较。
|
// phashBits 为 vector(64) 二进制向量串;NULL 的 phash 不参与比较。
|
||||||
|
|||||||
@ -23,7 +23,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
// mainDetailSeedSeq 让每次 seed 出来的实体键(city + year + title)互不相同。
|
// mainDetailSeedSeq 让每次 seed 出来的实体键(city + year + title)互不相同。
|
||||||
// 正式表上有部分唯一索引 uq_ss_entity (city, year, COALESCE(title, '')) WHERE is_deleted = 0,
|
// 正式表上有部分唯一索引 uq_ss_entity (city, year, COALESCE(title, 空串)) WHERE is_deleted = 0,
|
||||||
// 若测试沿用同一 city/year/title,第二条记录会被唯一索引拒绝。
|
// 若测试沿用同一 city/year/title,第二条记录会被唯一索引拒绝。
|
||||||
var mainDetailSeedSeq int
|
var mainDetailSeedSeq int
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user