neurots.extract_input.from_neurom¶
Extracts the distributions associated with NeuroM module.
Functions
|
Extract the number of trees for a specific tree type from a given population. |
|
Extract soma size. |
|
Transform distributions. |
|
Extract the trunk data for a specific tree type. |
|
Extract 3d trunk angle data. |
|
Extract the trunk data for a specific tree type. |
- neurots.extract_input.from_neurom.number_neurites(pop, neurite_type=NeuriteType.basal_dendrite)¶
Extract the number of trees for a specific tree type from a given population.
- Parameters:
pop (neurom.core.population.Population) – The given population.
neurite_type (neurom.core.types.NeuriteType) – Consider only the neurites of this type.
- Returns:
A dictionary with the following structure:
{ "num_trees": { "data": { "bins": <bin values>, "weights": <weights> } } }
- Return type:
- neurots.extract_input.from_neurom.soma_data(pop)¶
Extract soma size.
- Parameters:
pop (neurom.core.population.Population) – The given population.
- Returns:
A dictionary with the following structure:
{ "size": <the soma size> }
- Return type:
- neurots.extract_input.from_neurom.transform_distr(opt_distr)¶
Transform distributions.
- Parameters:
opt_distr (neurom.stats.FitResults) – The fitted distribution.
- Returns:
A dictionary whose structure depends on the type of distribution:
if
type == "norm"
:
{ "norm": { "mean": <mean value>, "std": <std value> } }
if
type == "uniform"
:
{ "uniform": { "min": <min value>, "max": <max value> } }
if
type == "expon"
:
{ "expon": { "loc": <loc value>, "lambda": <lambda value> } }
- Return type:
- neurots.extract_input.from_neurom.trunk_neurite(pop, neurite_type=NeuriteType.basal_dendrite, bins=30)¶
Extract the trunk data for a specific tree type.
See docstring of
trunk_neurite_simple()
andtrunk_neurite_3d_angles()
for more details on the extracted angles.- Parameters:
pop (neurom.core.population.Population) – The given population.
neurite_type (neurom.core.types.NeuriteType) – Consider only the neurites of this type.
bins (int or list[int] or str, optional) – The bins to use (this parameter is passed to
numpy.histogram()
).method (str) – Method to use, either
simple
or3d_angles
.
- Returns:
A dictionary with the trunk data.
- Return type:
- neurots.extract_input.from_neurom.trunk_neurite_3d_angles(pop, neurite_type, bins)¶
Extract 3d trunk angle data.
We extract non-projected, or 3d angles between the pia/apical and any neurite trunk.
If no apical dendrite is present, the entry
apical_3d_angles
will be absent.- Parameters:
pop (neurom.core.population.Population) – The given population.
neurite_type (neurom.core.types.NeuriteType) – Consider only the neurites of this type.
bins (int or list[int] or str, optional) – The bins to use (this parameter is passed to
numpy.histogram()
).
- Returns:
A dictionary with the following structure:
{ "trunk": { "pia_3d_angles": { "data": { "bins": <bin values>, "weights": <weights> } }, "apical_3d_angles": { "data": { "bins": <bin values>, "weights": <weights> } } } }
- Return type:
- neurots.extract_input.from_neurom.trunk_neurite_simple(pop, neurite_type, bins)¶
Extract the trunk data for a specific tree type.
- Parameters:
pop (neurom.core.population.Population) – The given population.
neurite_type (neurom.core.types.NeuriteType) – Consider only the neurites of this type.
bins (int or list[int] or str, optional) – The bins to use (this parameter is passed to
numpy.histogram()
).
- Returns:
A dictionary with the following structure:
{ "trunk": { "orientation_deviation": { "data": { "bins": <bin values>, "weights": <weights> } }, "azimuth": { "uniform": { "min": <min value>, "max": <max value> } }, "absolute_elevation_deviation": { "data": { "bins": <bin values>, "weights": <weights> } } } }
- Return type: