Beispiel #1
0
 def connections_on(self, gid):
     # ================================ TASK 1 ================================ #
     # e) Define the source of cell with gid as the previous cell with gid-1
     #    caution: close the ring at gid 0
     src = #TODO#
     return [connection(cmem(src,0), cmem(gid,0), 0.1, 10)]
Beispiel #2
0
    def connections_on(self, gid):
# ================================ SOLUTION 1 ================================ #
        # 1e) Define the source of cell with gid as the previous cell with gid-1
        #    caution: close the ring at gid 0
        src = self.num_cells()-1 if gid==0 else gid-1
        return [connection(cmem(src,0), cmem(gid,0), 0.1, 10)]
 def connections_on(self, gid):
     src = self.num_cells()-1 if gid==0 else gid-1
     return [connection(cmem(src,0), cmem(gid,0), 0.1, 10)]
Beispiel #4
0
 def connections_on(self, gid):
     src_id = (gid - 1) % self.ncells
     src = arb.cell_member(src, 0)
     tgt = arb.cell_member(gid, 0)
     return [arb.connection(src, tgt, 0.1, 10)]