-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
77 sparseoptimization pattern discrepancy #125
base: master
Are you sure you want to change the base?
Conversation
dimalvovs
commented
Nov 15, 2024
- add comments to chi-squared calc
- add 1 to denominator and numerator to avoid NaN in chi-squared calc
vignette
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't comment on how the 1+
's will affect calculations and their accuracy for a chisq calculation. I'll only ask: isn't the purpose of the SparseIterator
that it will skip all 0 values? So dsq = get<1>(it) * get<1>(it)
must be > 0
?
Also, though it's clearly outside the scope of this PR, it feels like there's the possibility for computational savings by storing the results of the dot products inside the for loop to be re-used in the while loop. Similarly, I think the dsq
values are constant throughout the CoGAPS run (they're just the element-wise square of the genes x sample matrix, right?). Could a static variable be used to store these?
that is exactly right, I think the root cause is the implementation of the sparseIterator, so maybe this draft PR should be more of a proof that that the |
f25f63c
to
b06f01b
Compare
additional to-dos from a call with @favorov:
|