-
Notifications
You must be signed in to change notification settings - Fork 25
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
SOM should protect against inputs with no column names #41
Comments
Already reported #38, but not yet implemented IIRC. |
Well, you know what they say... when it rains, it pours. FlowSOM inherits a memory-related problem from its dependencies, namely cytolib via flowCore; see RGLab/cytolib#45. This means that I am not able to call FlowSOM with any other package that uses global C variables, which pretty much makes it impossible to use in my bluster package (for coordinating different clustering methods). So, I went for the nuclear option of copying all the relevant code from FlowSOM into bluster to avoid these dependency problems (and also fix this issue at the same time). I had to reimplement it in C++, though, which led to #42. |
I thought that when it rains, we get wet... |
Yes, and I couldn't see any |
Hi Aaron and Samuel,
I'll try to look into this and remember our reasoning next week!
All the best,
Sofie
…On Fri, 8 Jan 2021, 09:55 Aaron Lun, ***@***.***> wrote:
Yes, and I couldn't see any change-related termination code in *kohonen*.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#41 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAOS72Z7QFDWYPRNZREWU4DSY3B6NANCNFSM4VXA7K3A>
.
|
The issue regarding the colnames should be solved with the latest commit. |
In the following example:
All observations are assigned the same code - odd. Diving into the source reveals the offending line:
FlowSOM/R/2_buildSOM.R
Lines 201 to 209 in 6f79b8b
Here,
colnames(codes)
isNULL
, which causesdata
to be subsetted to an empty numeric vector. The C code subsequently performs out-of-bounds accesses, leading to very difficult memory-related bugs downstream of usingSOM()
.An expedient solution would be to simply enforce identical
colnames
in any non-NULL
value ofcodes
. Ifcodes=NULL
, then it's derived from the data and there is no need for a separate check that the columns are matching.The text was updated successfully, but these errors were encountered: