-
Notifications
You must be signed in to change notification settings - Fork 5
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
Fix: Make bifurcation angles globally invariant #95
base: main
Are you sure you want to change the base?
Conversation
PS: this PR is based on #94, which we may want to merge first |
b8ba3aa
to
687e2ef
Compare
687e2ef
to
7a5a39e
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #95 +/- ##
==========================================
+ Coverage 97.76% 97.79% +0.02%
==========================================
Files 39 39
Lines 2197 2219 +22
Branches 381 386 +5
==========================================
+ Hits 2148 2170 +22
Misses 30 30
Partials 19 19
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #95 +/- ##
==========================================
- Coverage 97.88% 97.86% -0.02%
==========================================
Files 39 39
Lines 2217 2245 +28
Branches 296 303 +7
==========================================
+ Hits 2170 2197 +27
Misses 29 29
- Partials 18 19 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
|
thanks @adrien-berchet , @lidakanari can we merge this? |
Shouldn't the |
it is passed via parameters file |
You are passing |
is |
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.
You need to add a global test to generate a neuron at a couple of different directions and ensure the results do not change (i.e. the persistence and the local/global angles should remain the same).
Also, I think it would be useful to expose this functionality at the neuron level.
I am not sure if the results are correct as I cannot test on the population through the growth process.
My main concern is that the 'pia_direction' does not correspond to the orientation that is set as input for the apical. This could potentially cause an issue if one of the trees needs to grow towards a different direction, while the others grow to other directions. Since this directionality is only exposed at the tree level, it is not obvious how the growth of the neuron as the whole will be affected. Shouldn't this impact be global rather than local at the tree level? In addition, the global orientation has not been an issue for any other cell type apart from "flat" cells. Was this wrong so far but we missed it in the morphometrics? I am not sure how this correction will impact the pyramidal cells for example that are currently growing as expected taking into account the computed angle distributions. Could we add a test that this PR fixes so that we are aware of the improvement? It will be more clear this way :) |
@lidakanari so I did a complete refactoring, it was indeed not making so much sense. I did the following:
I hope this is more clear now! |
edfc545
to
0d31987
Compare
If one sets a non-[0,1,0] pia_direction, as it is the case for insitu synthesis, bifurcation angles are 'wrong', in the sense that they will depend on the pia_direction. As this is a global rotation of a cell, the bifurcation angles should be invariant to pia_direction.
As an example, here is a synthesized cell on a plane (z=0 always) with rotation invariance (this PR) and pia_direction = [1, 1, 1]:
and the same setup without this PR:
we see in the first case the original plane (z=0) rotated to match y-> pia_direction=[1,1,1].