The Virtual Brain Project

Table Of Contents

Previous topic

zip_surface Package

Next topic

config Package

This Page

visualizers Package

List here all Python modules where Visualization adapters are described. Listed modules will be introspected and DB filled.

annotations_viewer

class tvb.adapters.visualizers.annotations_viewer.ConnectivityAnnotationsView[source]

Bases: tvb.adapters.visualizers.surface_view.ABCSurfaceDisplayer

Given a Connectivity Matrix and a Surface data the viewer will display the matrix ‘inside’ the surface data. The surface is only displayed as a shadow.

get_form_class()[source]
get_required_memory_size(view_model)[source]
get_triangles_mapping(region_mapping_gid)[source]

:return Numpy array of length triangles and for each the region corresponding to one of its vertices.

launch(view_model)[source]
tree_json(annotations_gid)[source]
Returns:JSON to be rendered in a Tree of entities
class tvb.adapters.visualizers.annotations_viewer.ConnectivityAnnotationsViewForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.annotations_viewer.ConnectivityAnnotationsViewModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

connectivity_index : tvb.adapters.visualizers.annotations_viewer.ConnectivityAnnotationsViewModel.connectivity_index = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

annotations_index : tvb.adapters.visualizers.annotations_viewer.ConnectivityAnnotationsViewModel.annotations_index = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

region_mapping_index : tvb.adapters.visualizers.annotations_viewer.ConnectivityAnnotationsViewModel.region_mapping_index = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A region map to identify us the Cortical Surface to display, as well as how the mapping from Connectivity to Cortex is done

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

annotations_index

Keep a GID but also link the type of DataType it should point to

connectivity_index

Keep a GID but also link the type of DataType it should point to

region_mapping_index

Keep a GID but also link the type of DataType it should point to

brain

class tvb.adapters.visualizers.brain.BrainViewer[source]

Bases: tvb.adapters.visualizers.surface_view.ABCSurfaceDisplayer

Interface between the 3D view of the Brain Cortical Surface and TVB framework. This viewer will build the required parameter dictionary that will be sent to the HTML / JS for further processing, having as end result a brain surface plus activity that will be displayed in 3D.

PAGE_SIZE = 500
compute_parameters(time_series, shell_surface=None)[source]

Create the required parameter dictionary for the HTML/JS viewer.

Return type:dict
Raises Exception:
 when * number of measure points exceeds the maximum allowed * a Face object cannot be found in database
generate_preview(view_model, figure_size=None)[source]

Generate the preview for the burst page

get_form_class()[source]
get_required_memory_size(view_model)[source]

Assume one page doesn’t get ‘dumped’ in time and it is highly probably that two consecutive pages will be in the same time in memory.

launch(view_model)[source]

Build visualizer’s page.

populate_surface_fields(time_series_index)[source]

To be overwritten for populating fields: one_to_one_map/connectivity/region_map/surface fields

read_data_page_split(time_series_gid, from_idx, to_idx, step=None, specific_slices=None)[source]
retrieve_measure_points_params(time_series)[source]

To be overwritten method, for retrieving the measurement points (region centers, EEG sensors).

class tvb.adapters.visualizers.brain.BrainViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.brain.BrainViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

time_series : tvb.adapters.visualizers.brain.BrainViewerModel.time_series = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

shell_surface : tvb.adapters.visualizers.brain.BrainViewerModel.shell_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Surface to be displayed semi-transparently as overlay, for visual navigation purposes only.

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

shell_surface

Keep a GID but also link the type of DataType it should point to

time_series

Keep a GID but also link the type of DataType it should point to

class tvb.adapters.visualizers.brain.DualBrainViewer[source]

Bases: tvb.adapters.visualizers.brain.BrainViewer

Visualizer merging Brain 3D display and EEG lines display.

get_form_class()[source]
launch(view_model)[source]
populate_surface_fields(time_series_index)[source]

Prepares the urls from which the client may read the data needed for drawing the surface.

retrieve_measure_points_params(time_series)[source]
sensors_to_surface(sensors_gid, surface_to_map_gid)[source]
class tvb.adapters.visualizers.brain.DualBrainViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.brain.DualBrainViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

time_series : tvb.adapters.visualizers.brain.DualBrainViewerModel.time_series = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

projection_surface : tvb.adapters.visualizers.brain.DualBrainViewerModel.projection_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A surface on which to project the results. When missing, the first EEGCap is taken. This parameter is ignored when InternalSensors measures.
shell_surface : tvb.adapters.visualizers.brain.DualBrainViewerModel.shell_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Wrapping surface over the internal sensors, to be displayed semi-transparently, for visual purposes only.

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

projection_surface

Keep a GID but also link the type of DataType it should point to

shell_surface

Keep a GID but also link the type of DataType it should point to

time_series

Keep a GID but also link the type of DataType it should point to

complex_imaginary_coherence

class tvb.adapters.visualizers.complex_imaginary_coherence.ImaginaryCoherenceDisplay[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

This viewer takes as inputs a result from complex coherence analysis, and returns required parameters for a MatplotLib representation.

generate_preview(view_model, figure_size=None)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]

Draw interactive display.

class tvb.adapters.visualizers.complex_imaginary_coherence.ImaginaryCoherenceDisplayForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.complex_imaginary_coherence.ImaginaryCoherenceDisplayModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

input_data : tvb.adapters.visualizers.complex_imaginary_coherence.ImaginaryCoherenceDisplayModel.input_data = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
Imaginary Coherence Analysis to display

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

input_data

Keep a GID but also link the type of DataType it should point to

connectivity

class tvb.adapters.visualizers.connectivity.Connectivity2DViewer[source]

Bases: builtins.object

Having as inputs a Connectivity matrix(required) and two arrays that represent the colors and shapes of the nodes from the matrix(optional) the viewer will build the required parameter dictionary that will be sent to the HTML/JS 2D representation of the connectivity matrix.

DEFAULT_COLOR = '#d73027'
MAX_RAY = 40
MAX_WEIGHT_VALUE = 0.6
MIN_RAY = 4
MIN_WEIGHT_VALUE = 0.0
OTHER_COLOR = '#1a9850'
compute_parameters(input_data, colors=None, rays=None, step=None)[source]

Build the required HTML response to be displayed.

Raises LaunchException:
 when number of regions in input_data is less than 3
compute_preview_parameters(input_data, width, height, colors=None, rays=None, step=None)[source]

Build the required HTML response to be displayed in the BURST preview iFrame.

point2json(node_lbl, x_coord, y_coord, adjacencies, angle, shape_dimension, shape_color)[source]

Method used for creating a valid JSON for a certain point.

class tvb.adapters.visualizers.connectivity.Connectivity3DViewer[source]

Bases: builtins.object

Behavior for the HTML/JS 3D representation of the connectivity matrix.

static compute_parameters(input_data, colors=None, rays=None)[source]

Having as inputs a Connectivity matrix(required) and two arrays that represent the rays and colors of the nodes from the matrix(optional) this method will build the required parameter dictionary that will be sent to the HTML/JS 3D representation of the connectivity matrix.

class tvb.adapters.visualizers.connectivity.ConnectivityViewer[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

Given a Connectivity Matrix and a Surface data the viewer will display the matrix ‘inside’ the surface data. The surface is only displayed as a shadow.

generate_preview(view_model, figure_size=None)[source]

Generate the preview for the BURST cockpit.

see launch_

static get_connectivity_parameters(input_connectivity, conn_path)[source]

Returns a dictionary which contains all the needed data for drawing a connectivity.

get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]

Given the input connectivity data and the surface data, build the HTML response to be displayed.

class tvb.adapters.visualizers.connectivity.ConnectivityViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.connectivity.ConnectivityViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

Attributes meaning:

connectivity: GID towards the Connectivity object which will be displayed surface_data: if provided, it is displayed as a shadow to give an idea of the connectivity position

relative to the full brain cortical surface

colors: used to establish a colormap for the nodes displayed in 2D Connectivity viewers rays: used to establish the size of the spheres representing each node in 3D Nodes viewer step: a threshold applied to the 2D Connectivity Viewers to differentiate 2 types of nodes the ones

with a value greater that this will be displayed as red discs, instead of yellow

connectivity : tvb.adapters.visualizers.connectivity.ConnectivityViewerModel.connectivity = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

surface_data : tvb.adapters.visualizers.connectivity.ConnectivityViewerModel.surface_data = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
The Brain Surface is used to give you an idea of the connectivity position relative to the full brain cortical surface. This surface will be displayed as a shadow (only used in 3D Edges tab).
step : tvb.adapters.visualizers.connectivity.ConnectivityViewerModel.step = Attr(field_type=<class ‘float’>, default=None, required=False)
All nodes with a value greater or equal (>=) than this threshold will be displayed as red discs, otherwise (<) they will be yellow. (This applies to 2D Connectivity tabs and the threshold will depend on the metric used to set the Node Color)
colors : tvb.adapters.visualizers.connectivity.ConnectivityViewerModel.colors = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A ConnectivityMeasure DataType that establishes a colormap for the nodes displayed in the 2D Connectivity tabs.
rays : tvb.adapters.visualizers.connectivity.ConnectivityViewerModel.rays = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A ConnectivityMeasure datatype used to establish the size of the spheres representing each node. (It only applies to 3D Nodes tab).

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

colors

Keep a GID but also link the type of DataType it should point to

connectivity

Keep a GID but also link the type of DataType it should point to

rays

Keep a GID but also link the type of DataType it should point to

step

An Attr declares the following about the attribute it describes: * the type * a default value shared by all instances * if the value might be missing * documentation It will resolve to attributes on the instance.

surface_data

Keep a GID but also link the type of DataType it should point to

connectivity_edge_bundle

A Javascript displayer for connectivity, using hierarchical edge bundle diagrams from d3.js.

class tvb.adapters.visualizers.connectivity_edge_bundle.ConnectivityEdgeBundle[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

get_form_class()[source]
get_required_memory_size(**kwargs)[source]

Return required memory.

launch(view_model)[source]

Construct data for visualization and launch it.

class tvb.adapters.visualizers.connectivity_edge_bundle.ConnectivityEdgeBundleForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.connectivity_edge_bundle.ConnectivityEdgeBundleModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

connectivity : tvb.adapters.visualizers.connectivity_edge_bundle.ConnectivityEdgeBundleModel.connectivity = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

connectivity

Keep a GID but also link the type of DataType it should point to

cross_coherence

A displayer for the cross coherence of a time series.

class tvb.adapters.visualizers.cross_coherence.CrossCoherenceVisualizer[source]

Bases: tvb.adapters.visualizers.matrix_viewer.ABCMappedArraySVGVisualizer

get_form_class()[source]
launch(view_model)[source]

Construct data for visualization and launch it.

class tvb.adapters.visualizers.cross_coherence.CrossCoherenceVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.cross_coherence.CrossCoherenceVisualizerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

datatype : tvb.adapters.visualizers.cross_coherence.CrossCoherenceVisualizerModel.datatype = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

datatype

Keep a GID but also link the type of DataType it should point to

cross_correlation

A visualizer for cross correlation.

class tvb.adapters.visualizers.cross_correlation.CrossCorrelationVisualizer[source]

Bases: tvb.adapters.visualizers.matrix_viewer.ABCMappedArraySVGVisualizer

get_form_class()[source]
launch(view_model)[source]

Construct data for visualization and launch it.

class tvb.adapters.visualizers.cross_correlation.CrossCorrelationVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.cross_correlation.CrossCorrelationVisualizerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

datatype : tvb.adapters.visualizers.cross_correlation.CrossCorrelationVisualizerModel.datatype = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

datatype

Keep a GID but also link the type of DataType it should point to

eeg_monitor

class tvb.adapters.visualizers.eeg_monitor.EegMonitor[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

This viewer takes as inputs at least one ArrayWrapper and at most 3 ArrayWrappers, and returns the needed parameters for a 2D representation of the values from these arrays, in EEG form. So far arrays of at most 3 dimensions are supported.

compute_parameters(input_data, data_2=None, data_3=None, is_preview=False, is_extended_view=False, selected_dimensions=None)[source]

Start the JS visualizer, similar to EEG-lab

Parameters:
  • is_preview – Boolean True wne shown on Burst page
  • selected_dimensions – from GUI int
  • is_extended_view – Boolean when to display as dual-viewer
  • input_data (TimeSeriesEEG) – Time series to display
  • data_2 – additional input data
  • data_3 – additional input data
Returns:

the needed parameters for a 2D representation

Return type:

dict

Raises LaunchException:
 

when at least two input data parameters are provided and they sample periods differ

compute_required_info(list_of_timeseries)[source]

Compute average difference between Max and Min.

current_page = 0
generate_preview(view_model, figure_size=None)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

has_nan = False
launch(view_model)[source]

Compute visualizer’s page

page_size = 4000
preview_page_size = 250
class tvb.adapters.visualizers.eeg_monitor.EegMonitorForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.eeg_monitor.EegMonitorModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

input_data : tvb.adapters.visualizers.eeg_monitor.EegMonitorModel.input_data = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
Time series to display.
data_2 : tvb.adapters.visualizers.eeg_monitor.EegMonitorModel.data_2 = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Time series to display.
data_3 : tvb.adapters.visualizers.eeg_monitor.EegMonitorModel.data_3 = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Time series to display.

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

data_2

Keep a GID but also link the type of DataType it should point to

data_3

Keep a GID but also link the type of DataType it should point to

input_data

Keep a GID but also link the type of DataType it should point to

fourier_spectrum

class tvb.adapters.visualizers.fourier_spectrum.FourierSpectrumDisplay[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

This viewer takes as inputs a result form FFT analysis, and returns required parameters for a MatplotLib representation.

generate_preview(view_model, figure_size=None)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]
class tvb.adapters.visualizers.fourier_spectrum.FourierSpectrumForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
get_traited_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.fourier_spectrum.FourierSpectrumModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

input_data : tvb.adapters.visualizers.fourier_spectrum.FourierSpectrumModel.input_data = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
Fourier Analysis to display

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

input_data

Keep a GID but also link the type of DataType it should point to

histogram

class tvb.adapters.visualizers.histogram.HistogramViewer[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

The viewer takes as input a result DataType as computed by BCT analyzers.

generate_preview(view_model, figure_size=None)[source]

The preview for the burst page.

get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]

Prepare input data for display.

Parameters:input_data (ConnectivityMeasureIndex) – A BCT computed measure for a Connectivity
prepare_parameters(connectivity_measure_gid)[source]

Prepare all required parameters for a launch.

class tvb.adapters.visualizers.histogram.HistogramViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.histogram.HistogramViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

input_data : tvb.adapters.visualizers.histogram.HistogramViewerModel.input_data = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
A BCT computed measure for a Connectivity

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

input_data

Keep a GID but also link the type of DataType it should point to

ica

A matrix visualizer for the Independent Component Analysis. It displays the mixing matrix of size n_features x n_components

class tvb.adapters.visualizers.ica.ICA[source]

Bases: tvb.adapters.visualizers.matrix_viewer.ABCMappedArraySVGVisualizer

get_form_class()[source]
launch(view_model)[source]

Construct data for visualization and launch it.

class tvb.adapters.visualizers.ica.ICAForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.ica.ICAModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

datatype : tvb.adapters.visualizers.ica.ICAModel.datatype = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

i_svar : tvb.adapters.visualizers.ica.ICAModel.i_svar = Attr(field_type=<class ‘int’>, default=0, required=True)

i_mode : tvb.adapters.visualizers.ica.ICAModel.i_mode = Attr(field_type=<class ‘int’>, default=0, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

datatype

Keep a GID but also link the type of DataType it should point to

i_mode

An Attr declares the following about the attribute it describes: * the type * a default value shared by all instances * if the value might be missing * documentation It will resolve to attributes on the instance.

i_svar

An Attr declares the following about the attribute it describes: * the type * a default value shared by all instances * if the value might be missing * documentation It will resolve to attributes on the instance.

local_connectivity_view

class tvb.adapters.visualizers.local_connectivity_view.LocalConnectivityViewer[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

Local connectivity visualizer

get_form_class()[source]
get_required_memory_size()[source]
launch(view_model)[source]
class tvb.adapters.visualizers.local_connectivity_view.LocalConnectivityViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.local_connectivity_view.LocalConnectivityViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

local_conn : tvb.adapters.visualizers.local_connectivity_view.LocalConnectivityViewerModel.local_conn = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

local_conn

Keep a GID but also link the type of DataType it should point to

matrix_viewer

class tvb.adapters.visualizers.matrix_viewer.ABCMappedArraySVGVisualizer[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

To be inherited by visualizers for DataTypeMatrix subclasses

compute_2d_view(dtm_index, slice_s)[source]

Create a 2d view of the matrix using the suggested slice If the given slice is invalid or fails to produce a 2d array the default is used which selects the first 2 dimensions. If the matrix is complex the real part is shown :param dtm_index: main input. It can have more then 2D :param slice_s: a string representation of a slice :return: (a 2d array, the slice used to make it, is_default_returned)

compute_params(dtm_index, matrix2d, title_suffix, labels=None, given_slice=None, slice_used=None, is_default_slice=True)[source]
static compute_raw_matrix_params(matrix)[source]

Serializes matrix data, shape and stride metadata to json

extract_source_labels(datatype_matrix)[source]
generate_preview(view_model, **kwargs)[source]
get_required_memory_size(view_model)[source]

Return required memory.

class tvb.adapters.visualizers.matrix_viewer.MappedArrayVisualizer[source]

Bases: tvb.adapters.visualizers.matrix_viewer.ABCMappedArraySVGVisualizer

get_form_class()[source]
launch(view_model)[source]
class tvb.adapters.visualizers.matrix_viewer.MatrixVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.matrix_viewer.MatrixVisualizerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

datatype : tvb.adapters.visualizers.matrix_viewer.MatrixVisualizerModel.datatype = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

slice : tvb.adapters.visualizers.matrix_viewer.MatrixVisualizerModel.slice = Attr(field_type=<class ‘str’>, default=None, required=False)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

datatype

Keep a GID but also link the type of DataType it should point to

slice

An Attr declares the following about the attribute it describes: * the type * a default value shared by all instances * if the value might be missing * documentation It will resolve to attributes on the instance.

pca

A displayer for the principal components analysis.

class tvb.adapters.visualizers.pca.PCA[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

generate_preview(pca, figure_size=None)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return required memory. Here, it’s unknown/insignificant.

launch(view_model)[source]

Construct data for visualization and launch it.

class tvb.adapters.visualizers.pca.PCAForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.pca.PCAModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

pca : tvb.adapters.visualizers.pca.PCAModel.pca = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

pca

Keep a GID but also link the type of DataType it should point to

pearson_cross_correlation

class tvb.adapters.visualizers.pearson_cross_correlation.PearsonCorrelationCoefficientVisualizer[source]

Bases: tvb.adapters.visualizers.matrix_viewer.ABCMappedArraySVGVisualizer

Viewer for Pearson CorrelationCoefficients. Very similar to the CrossCorrelationVisualizer - this one done with Matplotlib

get_form_class()[source]
launch(view_model)[source]

Construct data for visualization and launch it.

class tvb.adapters.visualizers.pearson_cross_correlation.PearsonCorrelationCoefficientVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.pearson_cross_correlation.PearsonCorrelationCoefficientVisualizerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

datatype : tvb.adapters.visualizers.pearson_cross_correlation.PearsonCorrelationCoefficientVisualizerModel.datatype = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

datatype

Keep a GID but also link the type of DataType it should point to

pearson_edge_bundle

class tvb.adapters.visualizers.pearson_edge_bundle.PearsonEdgeBundle[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

Viewer for Pearson CorrelationCoefficients. Very similar to the CrossCorrelationVisualizer - this one done with Matplotlib

get_form_class()[source]
get_required_memory_size(view_model)[source]

Return required memory.

launch(view_model)[source]

Construct data for visualization and launch it.

phase_plane_interactive

class tvb.adapters.visualizers.phase_plane_interactive.PhaseLineD3(model, integrator)[source]

Bases: tvb.adapters.visualizers.phase_plane_interactive._PhaseSpace

compute_phase_plane()[source]
update_axis(mode, svx, x_range)[source]
class tvb.adapters.visualizers.phase_plane_interactive.PhasePlane(model, integrator)[source]

Bases: tvb.adapters.visualizers.phase_plane_interactive._PhaseSpace

Responsible with computing phase space slices and trajectories. A collection of math-y utilities it is view independent (holds no state related to views).

class tvb.adapters.visualizers.phase_plane_interactive.PhasePlaneD3(model, integrator)[source]

Bases: tvb.adapters.visualizers.phase_plane_interactive.PhasePlane

Provides data for a d3 client

compute_phase_plane()[source]
Returns:A json representation of the phase plane.
trajectories(starting_points, n_steps=512)[source]
Parameters:starting_points – A list of starting points represented as dicts of state_var_name to value
Returns:a tuple of trajectories and signals
update_axis(mode, svx, svy, x_range, y_range, state_vars)[source]
update_integrator_clamping()[source]
tvb.adapters.visualizers.phase_plane_interactive.nullcline(x, y, z)[source]
tvb.adapters.visualizers.phase_plane_interactive.phase_space_d3(model, integrator)[source]
Returns:A phase plane or a phase line depending on the dimensionality of the model

pse

Data for Parameter Space Exploration view will be defined here. The purpose of this entities is to be used in Jinja2 UI, or for populating visualizer.

class tvb.adapters.visualizers.pse.DiscretePSE(datatype_group_gid, color_metric, size_metric, back_page)[source]

Bases: tvb.basic.config.utils.EnhancedDictionary

prepare_individual_jsons()[source]

Apply JSON.dumps on all attributes which can not be passes as they are towards UI.

class tvb.adapters.visualizers.pse.PSEDiscreteGroupModel(datatype_group_gid, color_metric, size_metric, back_page)[source]

Bases: tvb.adapters.visualizers.pse.PSEGroupModel

determine_default_metrics()[source]
fill_pse_context()[source]
prepare_display_data()[source]
class tvb.adapters.visualizers.pse.PSEGroupModel(datatype_group_gid)[source]

Bases: builtins.object

get_all_metrics()[source]
get_all_node_info()[source]
get_available_metric_keys()[source]
get_range1_key()[source]
get_range2_key()[source]
parse_pse_data_for_display()[source]
range1_values[source]
range2_values[source]
class tvb.adapters.visualizers.pse.PSEModel(operation)[source]

Bases: builtins.object

determine_operation_result()[source]
get_range1_label()[source]
get_range2_label()[source]
is_range1_float()[source]
is_range2_float()[source]
prepare_node_info()[source]

Build a dictionary with all the required information to be displayed for a given node.

pse_discrete

class tvb.adapters.visualizers.pse_discrete.DiscretePSEAdapter[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

Visualization adapter for Parameter Space Exploration. Will be used as a generic visualizer, accessible when input entity is DataTypeGroup. Will also be used in Burst as a supplementary navigation layer.

get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]

Launch the visualizer.

static prepare_parameters(datatype_group_gid, back_page, color_metric=None, size_metric=None)[source]
class tvb.adapters.visualizers.pse_discrete.DiscretePSEAdapterForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.pse_discrete.DiscretePSEAdapterModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

datatype_group : tvb.adapters.visualizers.pse_discrete.DiscretePSEAdapterModel.datatype_group = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

datatype_group

Keep a GID but also link the type of DataType it should point to

pse_isocline

class tvb.adapters.visualizers.pse_isocline.IsoclinePSEAdapter[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

Visualization adapter for Parameter Space Exploration. Will be used as a generic visualizer, accessible when input entity is DataTypeGroup. Will also be used in Burst as a supplementary navigation layer.

burst_preview(view_model)[source]

Generate the preview for the burst page.

get_form_class()[source]
get_metric_matrix(datatype_group_gid, selected_metric=None)[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]
static prepare_node_data(datatype_group_gid)[source]
class tvb.adapters.visualizers.pse_isocline.IsoclinePSEAdapterForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.pse_isocline.IsoclinePSEAdapterModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

datatype_group : tvb.adapters.visualizers.pse_isocline.IsoclinePSEAdapterModel.datatype_group = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

datatype_group

Keep a GID but also link the type of DataType it should point to

class tvb.adapters.visualizers.pse_isocline.PSEIsoGroupModel(datatype_group_gid)[source]

Bases: tvb.adapters.visualizers.pse.PSEGroupModel

get_all_node_info()[source]
parse_pse_data_for_display()[source]

region_volume_mapping

Backend-side for Visualizers that display measures on regions in the brain volume.

class tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

class tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

background : tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel.background = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

background

Keep a GID but also link the type of DataType it should point to

class tvb.adapters.visualizers.region_volume_mapping.ConnectivityMeasureVolumeVisualizer[source]

Bases: tvb.adapters.visualizers.region_volume_mapping._MappedArrayVolumeBase

get_form_class()[source]
launch(view_model)[source]
class tvb.adapters.visualizers.region_volume_mapping.ConnectivityMeasureVolumeVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.region_volume_mapping.ConnectivityMeasureVolumeVisualizerModel(**kwargs)[source]

Bases: tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel

connectivity_measure : tvb.adapters.visualizers.region_volume_mapping.ConnectivityMeasureVolumeVisualizerModel.connectivity_measure = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
A connectivity measure

region_mapping_volume : tvb.adapters.visualizers.region_volume_mapping.ConnectivityMeasureVolumeVisualizerModel.region_mapping_volume = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

background : tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel.background = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

connectivity_measure

Keep a GID but also link the type of DataType it should point to

region_mapping_volume

Keep a GID but also link the type of DataType it should point to

class tvb.adapters.visualizers.region_volume_mapping.MappedArrayVolumeVisualizer[source]

Bases: tvb.adapters.visualizers.region_volume_mapping._MappedArrayVolumeBase

This is a generic mapped array visualizer on a region volume. To view a multidimensional array one has to give this viewer a slice.

get_form_class()[source]
launch(view_model)[source]
class tvb.adapters.visualizers.region_volume_mapping.MriVolumeVisualizer[source]

Bases: tvb.adapters.visualizers.region_volume_mapping._MappedArrayVolumeBase

get_form_class()[source]
get_required_memory_size(view_model)[source]
launch(view_model)[source]
class tvb.adapters.visualizers.region_volume_mapping.MriVolumeVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.region_volume_mapping.RegionVolumeMappingVisualiser[source]

Bases: tvb.adapters.visualizers.region_volume_mapping._MappedArrayVolumeBase

get_form_class()[source]
launch(view_model)[source]
class tvb.adapters.visualizers.region_volume_mapping.RegionVolumeMappingVisualiserForm(prefix='', project_id=None)[source]

Bases: tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.region_volume_mapping.RegionVolumeMappingVisualiserModel(**kwargs)[source]

Bases: tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel

region_mapping_volume : tvb.adapters.visualizers.region_volume_mapping.RegionVolumeMappingVisualiserModel.region_mapping_volume = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

connectivity_measure : tvb.adapters.visualizers.region_volume_mapping.RegionVolumeMappingVisualiserModel.connectivity_measure = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A connectivity measure

background : tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel.background = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

connectivity_measure

Keep a GID but also link the type of DataType it should point to

region_mapping_volume

Keep a GID but also link the type of DataType it should point to

class tvb.adapters.visualizers.region_volume_mapping.VolumeVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.region_volume_mapping.VolumeVisualizerModel(**kwargs)[source]

Bases: tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel

measure : tvb.adapters.visualizers.region_volume_mapping.VolumeVisualizerModel.measure = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
A measure to view on anatomy

region_mapping_volume : tvb.adapters.visualizers.region_volume_mapping.VolumeVisualizerModel.region_mapping_volume = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

data_slice : tvb.adapters.visualizers.region_volume_mapping.VolumeVisualizerModel.data_slice = Attr(field_type=<class ‘str’>, default=None, required=False)

background : tvb.adapters.visualizers.region_volume_mapping.BaseVolumeVisualizerModel.background = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

data_slice

An Attr declares the following about the attribute it describes: * the type * a default value shared by all instances * if the value might be missing * documentation It will resolve to attributes on the instance.

measure

Keep a GID but also link the type of DataType it should point to

region_mapping_volume

Keep a GID but also link the type of DataType it should point to

sensors

class tvb.adapters.visualizers.sensors.SensorsViewer[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

Sensor visualizer - for visual inspecting of TVB Sensors DataTypes.

get_form_class()[source]
get_required_memory_size()[source]
launch(view_model)[source]

Prepare visualizer parameters.

We support viewing all sensor types through a single viewer, so that a user doesn’t need to go back to the data-page, for loading a different type of sensor.

sensors_to_surface(sensors_gid, surface_to_map_gid)[source]
class tvb.adapters.visualizers.sensors.SensorsViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.sensors.SensorsViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

sensors : tvb.adapters.visualizers.sensors.SensorsViewerModel.sensors = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
Internals sensors to view
projection_surface : tvb.adapters.visualizers.sensors.SensorsViewerModel.projection_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A surface on which to project the results. When missing, the first EEGCap is taken. This parameter is ignored when InternalSensors are inspected
shell_surface : tvb.adapters.visualizers.sensors.SensorsViewerModel.shell_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Wrapping surface over the internal sensors, to be displayed semi-transparently, for visual purposes only.

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

projection_surface

Keep a GID but also link the type of DataType it should point to

sensors

Keep a GID but also link the type of DataType it should point to

shell_surface

Keep a GID but also link the type of DataType it should point to

tvb.adapters.visualizers.sensors.function_sensors_to_surface(sensors_gid, surface_to_map_gid)[source]

Map EEG sensors onto the head surface (skin-air).

EEG sensor locations are typically only given on a unit sphere, that is, they are effectively only identified by their orientation with respect to a coordinate system. This method is used to map these unit vector sensor “locations” to a specific location on the surface of the skin.

Assumes coordinate systems are aligned, i.e. common x,y,z and origin.

tvb.adapters.visualizers.sensors.prepare_mapped_sensors_as_measure_points_params(sensors, eeg_cap=None, adapter_id=None)[source]

Compute sensors positions by mapping them to the eeg_cap surface If eeg_cap is not specified the mapping will use a default EEGCal DataType in current project. If no default EEGCap is found, return sensors as they are (not projected)

Returns:dictionary to be used in Viewers for rendering measure_points
Return type:dict
tvb.adapters.visualizers.sensors.prepare_sensors_as_measure_points_params(sensors)[source]

Returns urls from where to fetch the measure points and their labels

surface_view

class tvb.adapters.visualizers.surface_view.ABCSurfaceDisplayer[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

generate_region_boundaries(surface_gid, region_mapping_gid)[source]

Return the full region boundaries, including: vertices, normals and lines indices.

class tvb.adapters.visualizers.surface_view.BaseSurfaceViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
class tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

region_map : tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel.region_map = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A region map
connectivity_measure : tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel.connectivity_measure = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A connectivity measure
shell_surface : tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel.shell_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Face surface to be displayed semi-transparently, for orientation only.

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

connectivity_measure

Keep a GID but also link the type of DataType it should point to

region_map

Keep a GID but also link the type of DataType it should point to

shell_surface

Keep a GID but also link the type of DataType it should point to

class tvb.adapters.visualizers.surface_view.ConnectivityMeasureOnSurfaceViewer[source]

Bases: tvb.adapters.visualizers.surface_view.SurfaceViewer

This displays a connectivity measure on a surface via a RegionMapping It reuses almost everything from SurfaceViewer, but it make required another input param.

get_form_class()[source]
launch(view_model)[source]
class tvb.adapters.visualizers.surface_view.ConnectivityMeasureOnSurfaceViewerForm(prefix='', project_id=None)[source]

Bases: tvb.adapters.visualizers.surface_view.BaseSurfaceViewerForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.surface_view.RegionMappingViewer[source]

Bases: tvb.adapters.visualizers.surface_view.SurfaceViewer

This is a viewer for RegionMapping DataTypes. It reuses almost everything from SurfaceViewer, but it make required another input param.

get_form_class()[source]
launch(view_model)[source]
class tvb.adapters.visualizers.surface_view.RegionMappingViewerForm(prefix='', project_id=None)[source]

Bases: tvb.adapters.visualizers.surface_view.BaseSurfaceViewerForm

static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.surface_view.SurfaceURLGenerator[source]

Bases: tvb.core.adapters.abcdisplayer.URLGenerator

static get_url_for_region_boundaries(surface_gid, region_mapping_gid, adapter_id)[source]
static get_urls_for_pick_rendering(surface_h5)[source]

Compose URLS for the JS code to retrieve a surface for picking.

static get_urls_for_rendering(surface_h5, region_mapping_gid=None)[source]

Compose URLs for the JS code to retrieve a surface from the UI for rendering.

class tvb.adapters.visualizers.surface_view.SurfaceViewer[source]

Bases: tvb.adapters.visualizers.surface_view.ABCSurfaceDisplayer

Static SurfaceData visualizer - for visual inspecting imported surfaces in TVB. Optionally it can display associated RegionMapping entities.

get_form_class()[source]
get_required_memory_size(view_model)[source]
launch(view_model)[source]
class tvb.adapters.visualizers.surface_view.SurfaceViewerForm(prefix='', project_id=None)[source]

Bases: tvb.adapters.visualizers.surface_view.BaseSurfaceViewerForm

static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.surface_view.SurfaceViewerModel(**kwargs)[source]

Bases: tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel

surface : tvb.adapters.visualizers.surface_view.SurfaceViewerModel.surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

region_map : tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel.region_map = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A region map
connectivity_measure : tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel.connectivity_measure = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
A connectivity measure
shell_surface : tvb.adapters.visualizers.surface_view.BaseSurfaceViewerModel.shell_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Face surface to be displayed semi-transparently, for orientation only.

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

surface

Keep a GID but also link the type of DataType it should point to

title = 'Surface Visualizer'
tvb.adapters.visualizers.surface_view.ensure_shell_surface(project_id, shell_surface=None, preferred_type='Face')[source]

time_series

A Javascript displayer for time series, using SVG.

class tvb.adapters.visualizers.time_series.ABCSpaceDisplayer[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

static build_params_for_selectable_connectivity(connectivity)[source]
build_params_for_subselectable_ts(ts_h5)[source]

creates a template dict with the initial selection to be displayed in a time series viewer

get_grouped_space_labels(ts_h5)[source]
Returns:A structure of this form [(‘left’, [(idx, lh_label)...]), (‘right’: [(idx, rh_label) ...])]
get_space_labels(ts_h5)[source]
Returns:An array of strings with the connectivity node labels.
class tvb.adapters.visualizers.time_series.TimeSeriesDisplay[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

MAX_PREVIEW_DATA_LENGTH = 200
generate_preview(view_model, figure_size=None)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return required memory.

launch(view_model)[source]

Construct data for visualization and launch it.

class tvb.adapters.visualizers.time_series.TimeSeriesForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.time_series.TimeSeriesModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

time_series : tvb.adapters.visualizers.time_series.TimeSeriesModel.time_series = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

time_series

Keep a GID but also link the type of DataType it should point to

time_series_volume

Backend-side for TS Visualizer of TS Volume DataTypes.

class tvb.adapters.visualizers.time_series_volume.TimeSeriesVolumeVisualiser[source]

Bases: tvb.adapters.visualizers.region_volume_mapping._MappedArrayVolumeBase

ensure_background(background_index)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return required memory.

get_voxel_time_series(entity_gid, **kwargs)[source]

Retrieve for a given voxel (x,y,z) the entire timeline.

Parameters:
  • x – int coordinate
  • y – int coordinate
  • z – int coordinate
Returns:

A complex dictionary with information about current voxel. The main part will be a vector with all the values over time from the x,y,z coordinates.

launch(view_model)[source]
class tvb.adapters.visualizers.time_series_volume.TimeSeriesVolumeVisualiserForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.time_series_volume.TimeSeriesVolumeVisualiserModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

time_series : tvb.adapters.visualizers.time_series_volume.TimeSeriesVolumeVisualiserModel.time_series = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

background : tvb.adapters.visualizers.time_series_volume.TimeSeriesVolumeVisualiserModel.background = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

background

Keep a GID but also link the type of DataType it should point to

time_series

Keep a GID but also link the type of DataType it should point to

topographic

class tvb.adapters.visualizers.topographic.TopographicViewer[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

Interface between TVB Framework and web display of a topography viewer.

generate_preview(view_model, figure_size=None)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]
class tvb.adapters.visualizers.topographic.TopographicViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.topographic.TopographicViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

data_0 : tvb.adapters.visualizers.topographic.TopographicViewerModel.data_0 = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
Punctual values for each node in the connectivity matrix. This will give the colors of the resulting topographic image.
data_1 : tvb.adapters.visualizers.topographic.TopographicViewerModel.data_1 = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Comparative values
data_2 : tvb.adapters.visualizers.topographic.TopographicViewerModel.data_2 = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Comparative values

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

data_0

Keep a GID but also link the type of DataType it should point to

data_1

Keep a GID but also link the type of DataType it should point to

data_2

Keep a GID but also link the type of DataType it should point to

class tvb.adapters.visualizers.topographic.TopographyCalculations[source]

Bases: builtins.object

static compute_topography_data(topography, sensor_locations)[source]

Trim data, to make sure everything is inside the head contour.

static normalize_sensors(points_positions)[source]

Centers the brain.

tract

A tracts visualizer .. moduleauthor:: Mihai Andrei <mihai.andrei@codemart.ro>

class tvb.adapters.visualizers.tract.TractViewer[source]

Bases: tvb.adapters.visualizers.time_series.ABCSpaceDisplayer

Tract visualizer

get_form_class()[source]
get_required_memory_size(view_model)[source]
launch(view_model)[source]
class tvb.adapters.visualizers.tract.TractViewerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.tract.TractViewerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

tracts : tvb.adapters.visualizers.tract.TractViewerModel.tracts = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

shell_surface : tvb.adapters.visualizers.tract.TractViewerModel.shell_surface = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=False)
Surface to be displayed semi-transparently, for visual purposes only.

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

shell_surface

Keep a GID but also link the type of DataType it should point to

tracts

Keep a GID but also link the type of DataType it should point to

wavelet_spectrogram

Plot the power of a WaveletCoefficients object

class tvb.adapters.visualizers.wavelet_spectrogram.WaveletSpectrogramVisualizer[source]

Bases: tvb.core.adapters.abcdisplayer.ABCDisplayer

Plot the power of a WaveletCoefficients object using SVG an D3.

generate_preview(view_model)[source]
get_form_class()[source]
get_required_memory_size(view_model)[source]

Return the required memory to run this algorithm.

launch(view_model)[source]
class tvb.adapters.visualizers.wavelet_spectrogram.WaveletSpectrogramVisualizerForm(prefix='', project_id=None)[source]

Bases: tvb.core.adapters.abcadapter.ABCAdapterForm

static get_filters()[source]
static get_input_name()[source]
static get_required_datatype()[source]
static get_view_model()[source]
class tvb.adapters.visualizers.wavelet_spectrogram.WaveletSpectrogramVisualizerModel(**kwargs)[source]

Bases: tvb.core.neotraits.view_model.ViewModel

input_data : tvb.adapters.visualizers.wavelet_spectrogram.WaveletSpectrogramVisualizerModel.input_data = DataTypeGidAttr(field_type=<class ‘uuid.UUID’>, default=None, required=True)
Wavelet spectrogram to display

gid : tvb.basic.neotraits._core.HasTraits.gid = Attr(field_type=<class ‘uuid.UUID’>, default=None, required=True)

input_data

Keep a GID but also link the type of DataType it should point to