23#ifndef SONATA_CONNECTOR_H
24#define SONATA_CONNECTOR_H
78 SonataConnector(
const Dictionary& graph_specs,
const long hyperslab_size );
96 H5::H5File* open_file_( std::string& fname );
104 H5::Group* open_group_(
const H5::H5File* file,
const std::string& grp_name );
112 H5::Group* open_group_(
const H5::Group* group,
const std::string& grp_name );
121 void open_required_dsets_(
const H5::Group* pop_grp );
130 void try_open_edge_group_dsets_(
const H5::Group* edge_grp );
135 void check_dsets_consistency();
148 void get_attribute_( std::string& attribute_value,
const H5::DataSet& dataset,
const std::string& attribute_name );
160 void create_edge_type_id_2_syn_spec_(
Dictionary edge_dict );
172 void set_synapse_params_(
Dictionary syn_dict,
size_t synapse_model_id,
int type_id );
185 void get_synapse_params_(
size_t snode_id, Node& target,
size_t target_thread, RngPtr rng,
int edge_type_id );
200 double get_syn_property_(
const Dictionary& syn_spec,
202 const bool dataset_exists,
203 std::vector< double >& data,
204 const std::string& name );
209 void sequential_chunkwise_connector_();
216 void connect_chunk_(
const hsize_t hyperslab_size,
const hsize_t offset );
227 template <
typename T >
228 void read_subset_(
const H5::DataSet& dataset,
229 std::vector< T >& data_buf,
230 H5::PredType datatype,
231 hsize_t hyperslab_size,
249 hsize_t find_edge_groups_( H5::Group* pop_grp, std::vector< std::string >& edge_grp_names );
260 hsize_t get_nrows_( H5::DataSet dataset );
265 void reset_params_();
267 typedef std::map< std::string, std::shared_ptr< ConnParameter > > ConnParameterMap;
270 std::set< std::string > skip_syn_params_;
276 hsize_t hyperslab_size_;
279 bool weight_dataset_exist_;
282 bool delay_dataset_exist_;
285 std::string source_attribute_value_;
288 std::string target_attribute_value_;
294 std::map< int, size_t > edge_type_id_2_syn_model_;
297 std::map< int, ConnParameterMap > edge_type_id_2_syn_spec_;
300 std::map< int, std::vector< Dictionary > > edge_type_id_2_param_dicts_;
303 std::string cur_fname_;
304 H5::DataSet src_node_id_dset_;
305 H5::DataSet tgt_node_id_dset_;
306 H5::DataSet edge_type_id_dset_;
307 H5::DataSet syn_weight_dset_;
308 H5::DataSet delay_dset_;
Dictionary class for interface to Python and C++ API.
Definition dictionary.h:213
Namespace for the NEST simulation kernel.
Definition beta_normalization_factor.h:33
void connect(NodeCollectionPTR sources, NodeCollectionPTR targets, const Dictionary &connectivity, const std::vector< Dictionary > &synapse_params)
Create bipartite connections.
Definition nest.cpp:424