-
Notifications
You must be signed in to change notification settings - Fork 3
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
Option to prune small twigs before nblast #19
Comments
maybe reverse Strahler order |
Could also remove anything tagged as |
Here is a first attempt at this. Trials on some DA1 PNs show a reduction in the number of nodes of about 25%, which seems useful though not huge. It may have a greater impact on neurons with very extensive arbours. prune_terminals <- function(x, maxorder=1, maxlength=2000,...) {
badsegs = strahler_order(x)$segments <= maxorder &
seglengths(x) <= maxlength
goodids = unlist(x$SegList[!badsegs])
prune_vertices(x, goodids, invert = T)
}
|
So more significant, but it actually takes 30 s to do the whole dotprops and strahler order thing. More than 20s of that is dotprops, with much of the time spent rbinding. |
NB have been having a problem where neurons have cycles
|
Looks like this relates to a bug introduced into nat when trying to speed up resampling of neurons in natverse/nat@77ca3e5. |
We now have a good implementation of this in (good enough that we may move to nat). |
So we can update |
No. Catbot uses the basic |
I think twigs5 is def better than simp10 although it might take longer. |
By combining strahler order and segment length we could probably remove a large number of small terminal branches without any impact on nblast results.
The text was updated successfully, but these errors were encountered: