Skip to content
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

allow for two point (single section) SWC somas #1144

Merged
merged 2 commits into from
Apr 8, 2021

Conversation

mgeplf
Copy link
Collaborator

@mgeplf mgeplf commented Apr 7, 2021

  • add test for simple two point swc soma
  • only test for neuromorpho three point soma if the SWC file has
    a soma of three points

* add test for simple two point swc soma
* only test for neuromorpho three point soma if the SWC file has
  a soma of three points
soma3geom = 0
if (nsoma_pts == 3 && pix2ix(1) == 0 && pix2ix(2) == 0) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

previously, for 2 points, this would cause an error:

NEURON: subscript out of range x
 near line 0
 }
  ^
        Import3d_SWC_read[13].pix2ix(2)
      Import3d_SWC_read[13].check_soma3geom(2, Vector[1450])
    Import3d_SWC_read[13].sectionify()
  Import3d_SWC_read[13].input("temp.tmp")

My hoc isn't great, but I take it that it doesn't do short-circuit evaluation?

@mgeplf
Copy link
Collaborator Author

mgeplf commented Apr 7, 2021

The original SWC format paper (An on-line archive of reconstructed hippocampal neurons) says this:
image

So, I believe that a single cylinder is an allowable value for the soma.

@pramodk pramodk requested a review from nrnhines April 7, 2021 16:18
Copy link
Member

@nrnhines nrnhines left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Too bad about the lack of short circuit evaluation in an if statement.

@pramodk pramodk merged commit 5038de0 into neuronsimulator:master Apr 8, 2021
@pramodk
Copy link
Member

pramodk commented Apr 8, 2021

thanks @mgeplf!

@mgeplf mgeplf deleted the two_point_swc_soma branch April 8, 2021 06:13
asanin-epfl added a commit to BlueBrain/MorphIO that referenced this pull request Apr 8, 2021
asanin-epfl added a commit to BlueBrain/MorphIO that referenced this pull request Apr 8, 2021
alexsavulescu pushed a commit that referenced this pull request Apr 13, 2021
* add test for simple two point swc soma
* only test for neuromorpho three point soma if the SWC file has
  a soma of three points
alexsavulescu pushed a commit that referenced this pull request Apr 30, 2021
* add test for simple two point swc soma
* only test for neuromorpho three point soma if the SWC file has
  a soma of three points
@alexsavulescu alexsavulescu mentioned this pull request Mar 22, 2022
15 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants