All this fidding with bits in the Thread "How to get non-unique
elements from an array" got me digressing to search engines and
indexing.
So if you have for example
Doc1=The quick brown fox
Doc2=Jumped over the brown dog
Doc3=Cut him to the quick
You can build a table with bit number and word.
1 the
2 quick
3 brown
4 fox
5 jumped
6 over
7 dog
8 cut
9 him
10 to
11 quick
To create indices
Doc1=00000001111
Doc2=00001110101
Doc3=11110000011
You can very quickly return the Docs that contain 'the' [
Doc1,Doc2,Doc3 ], or brown [ Doc1,Doc2 ] etc.
The rubyquiz idea would be to write a simple indexer/query system.
···
--
Into RFID? www.rfidnewsupdate.com Simple, fast, news.
The rubyquiz idea would be to write a simple indexer/query system.
require 'odeum_index'
Not to discourage the quiz idea, just wanted to mention
that ruby does have document indexing libraries available.
( http://www.zedshaw.com/projects/ruby_odeum/ )
Regards,
Bill
···
From: "Lyndon Samson" <lyndon.samson@gmail.com>
[snip quiz idea]
Is there any interest in this? I'm fine with running it, if anybody thinks they would like to work it.
James Edward Gray II
···
On Oct 18, 2005, at 7:41 PM, Lyndon Samson wrote:
All this fidding with bits in the Thread "How to get non-unique
elements from an array" got me digressing to search engines and
indexing.
It sounds interesting to me. Despite doing all the benchmarking I
never did create my own solution for the non-unique array elements
problem, so it might be fun to take part in a similar exercise for a
quiz.
In the spirit of that thread, I think part of the quiz should be to
solve the indexing problem in the shortest, most elegant, yet fastest
way possible. Maybe that goes without saying, but I've seen some
pretty long quiz solutions in the past.
Ryan
···
On 10/19/05, James Edward Gray II <james@grayproductions.net> wrote:
Is there any interest in this? I'm fine with running it, if anybody
thinks they would like to work it.
memory should could too - the user should at least provide a big estimage of
memory usage..
-a
···
On Wed, 19 Oct 2005, Ryan Leavengood wrote:
On 10/19/05, James Edward Gray II <james@grayproductions.net> wrote:
Is there any interest in this? I'm fine with running it, if anybody
thinks they would like to work it.
It sounds interesting to me. Despite doing all the benchmarking I
never did create my own solution for the non-unique array elements
problem, so it might be fun to take part in a similar exercise for a
quiz.
In the spirit of that thread, I think part of the quiz should be to
solve the indexing problem in the shortest, most elegant, yet fastest
way possible. Maybe that goes without saying, but I've seen some
pretty long quiz solutions in the past.
--
email :: ara [dot] t [dot] howard [at] noaa [dot] gov
phone :: 303.497.6469
anything that contradicts experience and logic should be abandoned.
-- h.h. the 14th dalai lama
===============================================================================
I've added this problem to the quiz queue. It will show up in a few weeks.
Thank you both.
James Edward Gray II
···
On Oct 19, 2005, at 9:54 AM, Ryan Leavengood wrote:
On 10/19/05, James Edward Gray II <james@grayproductions.net> wrote:
Is there any interest in this? I'm fine with running it, if anybody
thinks they would like to work it.
It sounds interesting to me. Despite doing all the benchmarking I
never did create my own solution for the non-unique array elements
problem, so it might be fun to take part in a similar exercise for a
quiz.
Hey guys,
Also check out Ferret for another ruby indexing library.
http://ferret.davebalmain.com/trac
But this quiz is still a great idea. It was something I thought about while
writing Ferret. It will be interesting to see what people come up with. I'll
certainly be partaking. As Ryan mentioned, the goal should be to solve the
problem in the shortest, most elegant, yet fastest
way possible.
HINT: From the OP's example, you'll get much better search speeds for large
document sets by inverting the index.
Regards,
Dave
···
On 10/20/05, James Edward Gray II <james@grayproductions.net> wrote:
On Oct 19, 2005, at 9:54 AM, Ryan Leavengood wrote:
> On 10/19/05, James Edward Gray II <james@grayproductions.net> wrote:
>
>>
>> Is there any interest in this? I'm fine with running it, if anybody
>> thinks they would like to work it.
>>
>
> It sounds interesting to me. Despite doing all the benchmarking I
> never did create my own solution for the non-unique array elements
> problem, so it might be fun to take part in a similar exercise for a
> quiz.
I've added this problem to the quiz queue. It will show up in a few
weeks.
Thank you both.
James Edward Gray II