The Virtual Brain Project

Table Of Contents

Previous topic

config Package

Next topic

logger Package

This Page

init Package

datatypes_registry

tvb.config.init.datatypes_registry.populate_datatypes_registry()[source]

initializer

class tvb.config.init.initializer.Introspector[source]

Bases: builtins.object

introspect()[source]
tvb.config.init.initializer.initialize(skip_import=False)[source]

Initialize when Application is starting. Check for new algorithms or new DataTypes.

tvb.config.init.initializer.reset()[source]

Service Layer for Database reset.

introspector_registry

class tvb.config.init.introspector_registry.IntrospectionRegistry[source]

Bases: builtins.object

This registry gathers classes that have a role in generating DB tables and rows. It is used at introspection time, for the following operations:

  • fill-in all rows in the ALGORITHM_CATEGORIES table
  • fill-in all rows in the ALGORITHMS table. Will add BCT algorithms only if Matlab/Octave path is set
  • generate DB tables for all datatype indexes
  • fill-in all rows in the PORTLETS table using data defined in XML files
  • keep an evidence of the datatype index removers

All classes that subclass AlgorithmCategoryConfig, ABCAdapter, ABCRemover, HasTraitsIndex should be imported here and added to the proper dictionary/list. e.g. Each new class of type HasTraitsIndex should be imported here and added to the DATATYPES list.

ADAPTERS = {<class 'tvb.config.algorithm_categories.AnalyzeAlgorithmCategoryConfig'>: [<class 'tvb.adapters.analyzers.cross_correlation_adapter.CrossCorrelateAdapter'>, <class 'tvb.adapters.analyzers.cross_correlation_adapter.PearsonCorrelationCoefficientAdapter'>, <class 'tvb.adapters.analyzers.fcd_adapter.FunctionalConnectivityDynamicsAdapter'>, <class 'tvb.adapters.analyzers.fmri_balloon_adapter.BalloonModelAdapter'>, <class 'tvb.adapters.analyzers.fourier_adapter.FourierAdapter'>, <class 'tvb.adapters.analyzers.ica_adapter.ICAAdapter'>, <class 'tvb.adapters.analyzers.metrics_group_timeseries.TimeseriesMetricsAdapter'>, <class 'tvb.adapters.analyzers.node_coherence_adapter.NodeCoherenceAdapter'>, <class 'tvb.adapters.analyzers.node_complex_coherence_adapter.NodeComplexCoherenceAdapter'>, <class 'tvb.adapters.analyzers.node_covariance_adapter.NodeCovarianceAdapter'>, <class 'tvb.adapters.analyzers.pca_adapter.PCAAdapter'>, <class 'tvb.adapters.analyzers.wavelet_adapter.ContinuousWaveletTransformAdapter'>], <class 'tvb.config.algorithm_categories.SimulateAlgorithmCategoryConfig'>: [<class 'tvb.adapters.simulator.simulator_adapter.SimulatorAdapter'>], <class 'tvb.config.algorithm_categories.UploadAlgorithmCategoryConfig'>: [<class 'tvb.adapters.uploaders.brco_importer.BRCOImporter'>, <class 'tvb.adapters.uploaders.connectivity_measure_importer.ConnectivityMeasureImporter'>, <class 'tvb.adapters.uploaders.csv_connectivity_importer.CSVConnectivityImporter'>, <class 'tvb.adapters.uploaders.gifti_surface_importer.GIFTISurfaceImporter'>, <class 'tvb.adapters.uploaders.gifti_timeseries_importer.GIFTITimeSeriesImporter'>, <class 'tvb.adapters.uploaders.mat_timeseries_eeg_importer.EEGMatTimeSeriesImporter'>, <class 'tvb.adapters.uploaders.mat_timeseries_importer.MatTimeSeriesImporter'>, <class 'tvb.adapters.uploaders.mat_timeseries_importer.MatTimeSeriesImporter'>, <class 'tvb.adapters.uploaders.networkx_importer.NetworkxConnectivityImporter'>, <class 'tvb.adapters.uploaders.nifti_importer.NIFTIImporter'>, <class 'tvb.adapters.uploaders.obj_importer.ObjSurfaceImporter'>, <class 'tvb.adapters.uploaders.projection_matrix_importer.ProjectionMatrixSurfaceEEGImporter'>, <class 'tvb.adapters.uploaders.region_mapping_importer.RegionMappingImporter'>, <class 'tvb.adapters.uploaders.sensors_importer.SensorsImporter'>, <class 'tvb.adapters.uploaders.tract_importer.TrackvizTractsImporter'>, <class 'tvb.adapters.uploaders.tract_importer.ZipTxtTractsImporter'>, <class 'tvb.adapters.uploaders.tvb_importer.TVBImporter'>, <class 'tvb.adapters.uploaders.zip_connectivity_importer.ZIPConnectivityImporter'>, <class 'tvb.adapters.uploaders.zip_surface_importer.ZIPSurfaceImporter'>], <class 'tvb.config.algorithm_categories.ViewAlgorithmCategoryConfig'>: [<class 'tvb.adapters.visualizers.annotations_viewer.ConnectivityAnnotationsView'>, <class 'tvb.adapters.visualizers.brain.BrainViewer'>, <class 'tvb.adapters.visualizers.brain.DualBrainViewer'>, <class 'tvb.adapters.visualizers.eeg_monitor.EegMonitor'>, <class 'tvb.adapters.visualizers.complex_imaginary_coherence.ImaginaryCoherenceDisplay'>, <class 'tvb.adapters.visualizers.connectivity.ConnectivityViewer'>, <class 'tvb.adapters.visualizers.connectivity_edge_bundle.ConnectivityEdgeBundle'>, <class 'tvb.adapters.visualizers.covariance.CovarianceVisualizer'>, <class 'tvb.adapters.visualizers.matrix_viewer.MappedArrayVisualizer'>, <class 'tvb.adapters.visualizers.cross_coherence.CrossCoherenceVisualizer'>, <class 'tvb.adapters.visualizers.cross_correlation.CrossCorrelationVisualizer'>, <class 'tvb.adapters.visualizers.eeg_monitor.EegMonitor'>, <class 'tvb.adapters.visualizers.fourier_spectrum.FourierSpectrumDisplay'>, <class 'tvb.adapters.visualizers.histogram.HistogramViewer'>, <class 'tvb.adapters.visualizers.ica.ICA'>, <class 'tvb.adapters.visualizers.local_connectivity_view.LocalConnectivityViewer'>, <class 'tvb.adapters.visualizers.matrix_viewer.MappedArrayVisualizer'>, <class 'tvb.adapters.visualizers.pca.PCA'>, <class 'tvb.adapters.visualizers.matrix_viewer.MappedArrayVisualizer'>, <class 'tvb.adapters.visualizers.pearson_cross_correlation.PearsonCorrelationCoefficientVisualizer'>, <class 'tvb.adapters.visualizers.pearson_edge_bundle.PearsonEdgeBundle'>, <class 'tvb.adapters.visualizers.pse_discrete.DiscretePSEAdapter'>, <class 'tvb.adapters.visualizers.pse_isocline.IsoclinePSEAdapter'>, <class 'tvb.adapters.visualizers.region_volume_mapping.ConnectivityMeasureVolumeVisualizer'>, <class 'tvb.adapters.visualizers.region_volume_mapping.MappedArrayVolumeVisualizer'>, <class 'tvb.adapters.visualizers.region_volume_mapping.MriVolumeVisualizer'>, <class 'tvb.adapters.visualizers.region_volume_mapping.RegionVolumeMappingVisualiser'>, <class 'tvb.adapters.visualizers.sensors.SensorsViewer'>, <class 'tvb.adapters.visualizers.surface_view.ConnectivityMeasureOnSurfaceViewer'>, <class 'tvb.adapters.visualizers.surface_view.RegionMappingViewer'>, <class 'tvb.adapters.visualizers.surface_view.SurfaceViewer'>, <class 'tvb.adapters.visualizers.time_series.TimeSeries'>, <class 'tvb.adapters.visualizers.time_series_volume.TimeSeriesVolumeVisualiser'>, <class 'tvb.adapters.visualizers.tract.TractViewer'>, <class 'tvb.adapters.visualizers.topographic.TopographicViewer'>, <class 'tvb.adapters.visualizers.wavelet_spectrogram.WaveletSpectrogramVisualizer'>], <class 'tvb.config.algorithm_categories.CreateAlgorithmCategoryConfig'>: [<class 'tvb.adapters.creators.allen_creator.AllenConnectomeBuilder'>, <class 'tvb.adapters.creators.connectivity_creator.ConnectivityCreator'>, <class 'tvb.adapters.creators.local_connectivity_creator.LocalConnectivityCreator'>]}
ALLEN_CREATOR_CLASS = 'AllenConnectomeBuilder'
ALLEN_CREATOR_MODULE = 'tvb.adapters.creators.allen_creator'
CONNECTIVITY_CLASS = 'ConnectivityViewer'
CONNECTIVITY_MODULE = 'tvb.adapters.visualizers.connectivity'
DATATYPES = [<class 'tvb.adapters.datatypes.db.annotation.ConnectivityAnnotationsIndex'>, <class 'tvb.adapters.datatypes.db.connectivity.ConnectivityIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.connectivity.ConnectivityIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.core.entities.model.model_datatype.DataTypeMatrix'>, <class 'tvb.adapters.datatypes.db.fcd.FcdIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesIndex'>, <class 'tvb.adapters.datatypes.db.connectivity.ConnectivityIndex'>, <class 'tvb.adapters.datatypes.db.graph.ConnectivityMeasureIndex'>, <class 'tvb.adapters.datatypes.db.graph.CorrelationCoefficientsIndex'>, <class 'tvb.adapters.datatypes.db.graph.CovarianceIndex'>, <class 'tvb.core.entities.model.model_datatype.DataTypeMatrix'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.local_connectivity.LocalConnectivityIndex'>, <class 'tvb.adapters.datatypes.db.surface.SurfaceIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.mapped_value.DatatypeMeasureIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesIndex'>, <class 'tvb.adapters.datatypes.db.mapped_value.ValueWrapperIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.mode_decompositions.IndependentComponentsIndex'>, <class 'tvb.adapters.datatypes.db.mode_decompositions.PrincipalComponentsIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesIndex'>, <class 'tvb.adapters.datatypes.db.connectivity.ConnectivityIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.patterns.StimuliRegionIndex'>, <class 'tvb.adapters.datatypes.db.patterns.StimuliSurfaceIndex'>, <class 'tvb.adapters.datatypes.db.surface.SurfaceIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.projections.ProjectionMatrixIndex'>, <class 'tvb.adapters.datatypes.db.sensors.SensorsIndex'>, <class 'tvb.adapters.datatypes.db.surface.SurfaceIndex'>, <class 'tvb.adapters.datatypes.db.connectivity.ConnectivityIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.core.entities.model.model_datatype.DataTypeMatrix'>, <class 'tvb.adapters.datatypes.db.region_mapping.RegionMappingIndex'>, <class 'tvb.adapters.datatypes.db.region_mapping.RegionVolumeMappingIndex'>, <class 'tvb.adapters.datatypes.db.surface.SurfaceIndex'>, <class 'tvb.adapters.datatypes.db.volume.VolumeIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.sensors.SensorsIndex'>, <class 'tvb.adapters.datatypes.db.spectral.CoherenceSpectrumIndex'>, <class 'tvb.adapters.datatypes.db.spectral.ComplexCoherenceSpectrumIndex'>, <class 'tvb.core.entities.model.model_datatype.DataTypeMatrix'>, <class 'tvb.adapters.datatypes.db.spectral.FourierSpectrumIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesIndex'>, <class 'tvb.adapters.datatypes.db.spectral.WaveletCoefficientsIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.surface.SurfaceIndex'>, <class 'tvb.adapters.datatypes.db.temporal_correlations.CrossCorrelationIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesIndex'>, <class 'tvb.adapters.datatypes.db.connectivity.ConnectivityIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.region_mapping.RegionMappingIndex'>, <class 'tvb.adapters.datatypes.db.region_mapping.RegionVolumeMappingIndex'>, <class 'tvb.adapters.datatypes.db.sensors.SensorsIndex'>, <class 'tvb.adapters.datatypes.db.surface.SurfaceIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesEEGIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesMEGIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesRegionIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesSEEGIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesSurfaceIndex'>, <class 'tvb.adapters.datatypes.db.time_series.TimeSeriesVolumeIndex'>, <class 'tvb.adapters.datatypes.db.volume.VolumeIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.region_mapping.RegionVolumeMappingIndex'>, <class 'tvb.adapters.datatypes.db.tracts.TractsIndex'>, <class 'tvb.core.entities.model.model_datatype.DataType'>, <class 'tvb.adapters.datatypes.db.volume.VolumeIndex'>]
DISCRETE_PSE_ADAPTER_CLASS = 'DiscretePSEAdapter'
DISCRETE_PSE_ADAPTER_MODULE = 'tvb.adapters.visualizers.pse_discrete'
ISOCLINE_PSE_ADAPTER_CLASS = 'IsoclinePSEAdapter'
ISOCLINE_PSE_ADAPTER_MODULE = 'tvb.adapters.visualizers.pse_isocline'
MEASURE_METRICS_CLASS = 'TimeseriesMetricsAdapter'
MEASURE_METRICS_MODULE = 'tvb.adapters.analyzers.metrics_group_timeseries'
PORTLETS_MODULE = <module 'tvb.adapters.portlets' from '/root/tvb-root/framework_tvb/tvb/adapters/portlets/__init__.py'>
SIMULATOR_CLASS = 'SimulatorAdapter'
SIMULATOR_MODULE = 'tvb.adapters.simulator.simulator_adapter'
tvb.config.init.introspector_registry.import_adapters(adapters_top_module, all_adapter_files)[source]

@:param adapters_top_module: top module under which the ABCAdapter instances are searched for @:param all_adapter_files: list of strings representing python submodules. We will import these, relative to ‘adapters_top_module’ and introspect ass concrete subclasses of ABCAdapter defined inside @:returns: list of ABCAdapter subclasses

tvb.config.init.introspector_registry.import_dt_index(dt_top_module, all_dt_files)[source]

@:param dt_top_module: top module under which the DataType instances are searched for @:param all_dt_files: list of strings representing python submodules. We will import these, relative to ‘dt_top_module’ and introspect ass concrete subclasses of DataType defined inside @:returns: list of Dt Index subclasses

model_manager

tvb.config.init.model_manager.initialize_startup()[source]

Force DB tables create, in case no data is already found.

tvb.config.init.model_manager.reset_database()[source]

Remove all tables in DB.