hi everyone!, im am having a specific problem with numpy, i cant seem to find how is this simple filter supposed to be done:
i have a table that defines all the filters like this:
table[property][items]
item0 item1 item2
prop0 1 0 1
prop1 1 1 0
prop2 0 0 1
prop3 1 1 1
so every property (row) contains a binary compressed in uint64's, the length of that binary in bits is about the amount of items in the database (each bit indicates if this filter is present in that item)
now imagine i want to get only the items that contain certain binary properties:
must_have[is_property_present]
which props are selected?
prop0 prop1 prop2 prop3
0 1 0 1
this has a bit for every property in the database, it contains a 1 for each property that must be in the candidates.
the candidates (the result) must be like this:
candidates[does_matchs]
which items match?
item0 item1 item2 item3
1 1 0 1
the has a bit for every item in the database, it contains a 1 for each item that matchs with the specified filters.
i know how to manage memory in C but i am really new to Numpy, so pls be patient. thanks in advance!! ๐