The Virtual Brain Project

Table Of Contents

Previous topic

mat Package

Next topic

nifti Package

This Page

networkx_connectivity Package


class tvb.adapters.uploaders.networkx_connectivity.parser.NetworkxParser(storage_path, key_edge_weight=None, key_edge_tract=None, key_node_coordinates=None, key_node_label=None, key_node_region=None, key_node_hemisphere=None)[source]

Bases: object

This class reads content of a NetworkX stream and builds a Connectivity instance filled with details.

KEY_EDGE_TRACT = ['fiber_length_mean']
KEY_EDGE_WEIGHT = ['adc_mean', 'fiber_weight_mean']
KEY_NODE_COORDINATES = ['dn_position']
KEY_NODE_HEMISPHERE = ['dn_hemisphere']
KEY_NODE_LABEL = ['dn_name', 'dn_label']
KEY_NODE_REGION = ['dn_region']
OPERATORS = '[*-+:]'
REGION_CORTICAL = 'cortical'

Populate Connectivity DataType from NetworkX object. Tested with results from Connectome Mapper Toolkit.

Parameters:network – NetworkX graph
Returns:Connectivity object
static prepare_input_params_tree(prefix=None)[source]
Parameters:prefix – An optional string, to be used in front of the GUI displayed labels
Returns:Adapter Input tree, with possible user-given keys for reading from NetworkX object