Note that there are some explanatory texts on larger screens.

plurals
  1. PONeed a proper data structure or index for fast user lookup based on 3d points and importance factors
    primarykey
    data
    text
    <p>I have a large number of 3d points paired with importance factors.</p> <p>Each user has a six points. For example: Person Charlie has 6 points: (22,44,55) is his first point with an importance factor of 3, (10,0,0) is his second vector with a importance factor of 2.8 all the way down to his sixth point that is (100,300,200) with an importance factor of 0.4. </p> <p>What I would like to do is to find the person that is most similar to Charlie without iterating through every single other person. Essentially minimizing this function for every user (ie, matching up the right six points from that user to Charlie):</p> <pre><code>pythagoras(point, point2) * max(importance_factor, importance_factor2) * (abs(importance_factor - importance_factor2) + 1) </code></pre> <p>And then finding the user that is most similar to Charlie over all by choosing the one with the lowest cost. I've written the code the dumb way for now (by doing lots of loops) but I'm looking for a way to properly handle the fact that there are multiple points AND importance factors.</p> <p>I started looking into spacial indexes, but I don't think they will work since I have multiple points, but perhaps I could unroll the points into a higher dimensional point? So instead of 6 points in 3 dimensions I could have 1 point in 18 dimensions? Still can't handle the importance factor, but it would better than nothing.</p> <p>Unfortunately I can't us vectors and cosines here, since (1,1,1) and (400,400,400) are <em>very</em> opposite things.</p> <p>Any ideas?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload