neurots.extract_input.input_distributions

Input distributions.

Functions

distributions(filepath[, neurite_types, ...])

Extracts the input distributions from an input population.

neurots.extract_input.input_distributions._append_dicts(*args)

Merge all dicts into the first one.

neurots.extract_input.input_distributions.distributions(filepath, neurite_types=None, threshold_sec=2, diameter_input_morph=None, feature='path_distances', diameter_model=None, min_n_basals=1)

Extracts the input distributions from an input population.

The population is defined by a directory of swc or h5 files.

Parameters:
  • filepath (str) – the morphology file.

  • neurite_types (list[str]) – the neurite types to consider.

  • threshold_sec (int) – defines the minimum accepted number of terminations.

  • diameter_input_morph (str) – if input set of morphologies is provided it will be used for the generation of diameter model, if no input is provided no diameter model will be generated.

  • feature (str) – defines the TMD feature that will be used to extract the persistence barcode (can be radial_distances, path_distances or trunk_length). It is also possible to define one different feature per neurite type using a dict like {<neurite type 1>: <feature 1>, ...}.

  • diameter_model (str) – model for diameters, internal models are M1, M2, M3, M4 and M5. Can be set to external for external model.

  • min_n_basals (int) – minimum number of basals, if less we enforce this value (default=1)

Returns:

The input distributions.

Return type:

dict