BlueBrain / NeuroM

Neuronal Morphology Analysis Tool
https://neurom.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
102 stars 55 forks source link

axons may start from a dendrite. #562

Closed jdcourcol closed 3 years ago

jdcourcol commented 7 years ago

We are assuming so far that all neurites start from the soma. It appears that in some reconstructions (and in biology), axons may start from a dendrite.

wvangeit commented 7 years ago

See here e.g.: https://www.eurekalert.org/pub_releases/2014-09/uob-cwd092214.php https://www.ncbi.nlm.nih.gov/pubmed/25199704

lidakanari commented 7 years ago

This is encoded in the reconstruction (at least in ascii files). We have to ensure that in this case the data are loaded correctly and we have to define an analysis that makes sense in this case. In order to include this case, I computed the tree_type by the median of the tree_type of each point. In this case the assumption is that the initial part is considered to be of the same type as the rest of the tree.

mgeplf commented 7 years ago

@wvangeit do you know what NEURON does? @lidakanari do you have an example of the ascii files you mentioned?

wvangeit commented 7 years ago

Regarding Neuron, I tried it last week. At least in the latest version and using the SWC reader, Neuron connects the axon nicely to the dendrite (the replace_axon function of e.g. BluePyOpt will however replace the axon with an AIS connected to the soma)

mgeplf commented 7 years ago

@wvangeit Ok, good to know.

I can see how SWC would be able to handle it, as each point has a neurite type associated with it. Other formats, I have less idea about (name, I need to see a neurolucida version, so I can see how they encode the switch)

INF-Rene commented 5 years ago

Having trouble with this. Want to analyze axons in a bunch of SWC files but axons start often at the dendrite in my cells and are then marked as dendrite instead of axon.

Is there any workaround for this?

wizmer commented 5 years ago

I don't exactly know what you need to do but you can still find the root sections of remote axons. Something like this should work:

from neurom import iter_sections, NeuriteType

def find_remote_axons(neuron):
    remote_axons = list()
    for section in iter_sections(neuron):
        if section.is_root():
            continue
        if section.type == NeuriteType.axon and section.parent.type != NeuriteType.axon:
            remote_axons.append(section)
    return remote_axons
INF-Rene commented 5 years ago

Ah great, that works perfectly. Need to do some different things, but I can do it all by just iterating over the sections. Thanks a lot.

wizmer commented 5 years ago

You're welcome. Actually, if your remote axon is real and not an artefact of the reconstruction process, could I ask you to send me the file ? I have been told such morphologies exist but I haven't seen any yet. Thanks

INF-Rene commented 5 years ago

Sure, I have sent one to your email. They occur a lot in interneurons. I am analyzing a set of PV+ interneurons and about half of them have the axon starting at the dendrite

asanin-epfl commented 3 years ago

Closing as it is handled in NeuroM v2. The test is test_has_no_dangling_branch. The example morphology is tests/data/neurolucida/axon-sprout-from-dendrite.asc.