View Single Post
Old 04-04-2009, 05:29 PM   #9
Xenophon
curmudgeon
Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.
 
Xenophon's Avatar
 
Posts: 1,481
Karma: 5748190
Join Date: Jun 2006
Location: Redwood City, CA USA
Device: Kobo Aura HD, (ex)nook, (ex)PRS-700, (ex)PRS-500
Quote:
Originally Posted by kovidgoyal View Post
Not really, it's a pretty simple problem, say you have 20000 books in your database, and are adding 100 new books

Then calibre has to make 20,000 * 100 comparisons to check for duplicates. That's presumably what's slowing it down.
Surely it need only make log2(20,000) * 100 comparisons, right? And you could optimize even that by hashing over whatever you are using for the comparison first. And...

Care to exchange a bit of email?

Xenophon
Xenophon is offline   Reply With Quote