Conversation
953cde5 to
473be0d
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1012 +/- ##
==========================================
+ Coverage 89.27% 89.34% +0.07%
==========================================
Files 221 223 +2
Lines 15292 15534 +242
==========================================
+ Hits 13652 13879 +227
- Misses 1640 1655 +15 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| mat = spla.inv(cooc, assume_a="pos") | ||
| log.info("inverted co-occurrance matrix in %s", timer) | ||
|
|
||
| mat /= np.diag(mat) |
There was a problem hiding this comment.
Aren't we missing a minus sign here?
| q_vec[q_good] = 1.0 | ||
|
|
||
| _log.debug("multiplying matrix for %d items", np.sum(q_ok)) | ||
| scores = self.weights @ q_vec |
There was a problem hiding this comment.
Does this match the paper's s=xB scoring formula? Since we compute Bx here, I was wondering if the orientation is correct.
There was a problem hiding this comment.
Good catch, but since B is symmetric, it doesn't matter.
There was a problem hiding this comment.
If P is symmetric, dividing it by its diagonal as in B = P / (-np.diag(P)) in the paper should break symmetry. I ran a quick test and it wasn’t symmetric. Am I missing something?
There was a problem hiding this comment.
You're probably right — I'll check again tomorrow.
There was a problem hiding this comment.
Yep, you're right. Fixed.
| :attr:`environment`, then in :attr:`os.environ`. | ||
| """ | ||
| if name in self.environment: | ||
| return name |
There was a problem hiding this comment.
I think we should return the value here as self.environment[name], right?
This adds an implementation of EASE, along with supporting changes to matrix relationship sets and co-occurrence counting.
It could be further sped up (a little) by directly counting into a dense matrix, instead of counting into a sparse matrix and then making it dense.
Closes #942.