pyneuroml.utils package#

The utils package contains various utility functions to aid users working with PyNeuroML

Copyright 2023 NeuroML Contributors

pyneuroml.utils.extract_position_info(nml_model: NeuroMLDocument, verbose: bool = False) tuple#

Extract position information from a NeuroML model

Returns a tuple of dictionaries:

  • cell_id_vs_cell: dict(cell id, cell object)

  • pop_id_vs_cell: dict(pop id, cell object)

  • positions: dict(pop id, dict(cell id, position in x, y, z))

  • pop_id_vs_color: dict(pop id, colour property)

  • pop_id_vs_radii: dict(pop id, radius property)

Parameters
  • nml_model (NeuroMLDocument) – NeuroML2 model to extract position information from

  • verbose (bool) – toggle function verbosity

Returns

[cell id vs cell dict, pop id vs cell dict, positions dict, pop id vs colour dict, pop id vs radii dict]

Return type

tuple of dicts