P is for Practical | |
PerlMonks |
Re: Netflix (or on handling large amounts of data efficiently in perl)by tilly (Archbishop) |
on Dec 24, 2008 at 04:35 UTC ( [id://732410]=note: print w/replies, xml ) | Need Help?? |
mmap is being used as a cheap way to sidestep I/O. That doesn't make as much sense in Perl. A more natural solution in Perl is to use a dbm like Berkeley DB. Going an alternate direction you can probably store your information in under 1 GB using vec to store a vector of 32-bit numbers, each of which uses 3 bits for the rating, and the rest for the user ID. Personally I'd be inclined to use vec. (Actually I'd be inclined to use another language than Perl...)
In Section
Seekers of Perl Wisdom
|
|