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. |
- 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.
- 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 pararmeter is passed to
numpy.histogram()
).
- Returns
A dictionary with the following structure:
{ "trunk": { "orientation_deviation": { "data": { "bins": <bin values>, "weights": <weights> } }, "azimuth": { "inuform": { "min": <min value>, "max": <max value> } }, "absolute_elevation_deviation": { "data": { "bins": <bin values>, "weights": <weights> } } } }
- Return type