SpiNNakerManchester / sPyNNaker8

The PyNN 0.8 interface to sPyNNaker.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

'PopulationView' object has no attribute '_get_vertex'

JWeinland opened this issue · comments

Hello everyone,
this error occurs when running the code below on SpiNNaker:

Traceback (most recent call last):
  File "snn_dvs_cn_pynn081.py", line 405, in <module>
    snn_net.create_network()
  File "snn_dvs_cn_pynn081.py", line 162, in create_network
    self.connect_input_to_network(network)
  File "snn_dvs_cn_pynn081.py", line 224, in connect_input_to_network
    sim.StaticSynapse( weight=self.dyn_params[5], delay=self.dyn_params[12]))
  File "/home/jk/virtualenvs/pyNN081/local/lib/python2.7/site-packages/spynnaker8/__init__.py", line 244, in Projection
    space=space, label=label)
  File "/home/jk/virtualenvs/pyNN081/local/lib/python2.7/site-packages/spynnaker8/models/projection.py", line 76, in __init__
    time_scale_factor=self._simulator.time_scale_factor)
  File "/home/jk/virtualenvs/pyNN081/local/lib/python2.7/site-packages/spynnaker/pyNN/models/pynn_projection_common.py", line 103, in __init__
    pre_synaptic_population._get_vertex,
AttributeError: 'PopulationView' object has no attribute '_get_vertex'
2017-10-25 14:30:02 INFO: signal_shutdown [atexit]

Section of the code in which the error occurs:

 def connect_input_to_network(self):
        """Connect input  to network """
        cam_l = [sim.PopulationView(self._input_population[0],
                                    selector=np.arange(y * self.dim_x,y* self.dim_x + self.dim_x)) for y in range(self.dim_y)]
        cam_r = [sim.PopulationView(self._input_population[1],
                                    selector=np.arange(y * self.dim_x,y* self.dim_x + self.dim_x)) for y in range(self.dim_y)]


        for y in range(self.dim_y):
            sim.Projection(cam_r[y],self.network['collectors'][y],sim.FromListConnector(self.create_con_list_ni('r')),
                           sim.StaticSynapse(weight=self.dyn_params[5], delay=self.dyn_params[12]))

thanks a lot in advance!

this is mainly due to the pop views and assembliers being place holders. they have not yet been implemented. You shouldn't be able to do sim.pop_view, which means we slipped up there.

we only support populations and projections. views and assemblers are a ongoing project

Some populations view work has gone in.

Is this still an issue.

If yes reopen.