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

Move soma methods to functions #1118

Merged
merged 6 commits into from
May 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions neurom/core/morphology.py
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ def graft_morphology(section):
class Neurite:
"""Class representing a neurite tree."""

def __init__(self, root_node, process_subtrees=False):
def __init__(self, root_node, *, process_subtrees=False):
"""Constructor.

Args:
Expand Down Expand Up @@ -538,7 +538,7 @@ def __repr__(self):
class Morphology:
"""Class representing a simple morphology."""

def __init__(self, morphio_morph, name=None, process_subtrees=False):
def __init__(self, morphio_morph, name=None, *, process_subtrees=False):
"""Morphology constructor.

Args:
Expand Down
9 changes: 8 additions & 1 deletion neurom/core/population.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,13 @@ class Population:
"""

def __init__(
self, files, name='Population', ignored_exceptions=(), cache=False, process_subtrees=False
self,
files,
name='Population',
ignored_exceptions=(),
*,
cache=False,
process_subtrees=False,
):
"""Construct a morphology population.

Expand All @@ -67,6 +73,7 @@ def __init__(
will be loaded everytime it is accessed within the population. Which is good when
population is big. If true then all morphs will be loaded upon the construction
and kept in memory.
process_subtrees (bool): enable mixed tree processing if set to True

Notes:
symlinks in paths are not resolved.
Expand Down
Loading
Loading