summaryrefslogtreecommitdiff
path: root/core/list_synapses.cpp
blob: 6132b56eaa8f0d26266a85c8fd5652ae8506f4c1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include <iostream>

#include "everything_else.hpp"
#include "id_list.hpp"
#include "topology.hpp"

int main(int argc, char **argv) {
  assert(argc == 3);
  assertSimDir();
  {
    Topology t;
    IdList<Ptr<Neuron>::ptr_t> src(argv[1]), dst(argv[2]);
    
    for (auto i : src) {
      int j=0;
      Ptr<Synapse> s(-1);
      while ((s = t.synapse(Ptr<Neuron>(i), j++)) != t.nil())
	if (dst.count(s.extractNeuron()()))
	  std::cout << s() << "\t" << i << " -> " << s.extractNeuron() << "\n";
    }
  }
}
contact: Jan Huwald // Impressum