i also did data[data != data] = 0 at the very beggining to prevent this nans in the database and the forward function only takes from that database
this is the full tracker btw
RuntimeError                              Traceback (most recent call last)
 in 
1 spiking_model = SpikingNet(device, n_time_steps=1200, begin_eval=0)
----> 2 train_many_epochs(spiking_model)
 in train_many_epochs(model)
27         epoch = i
28         optimizer = optim.SGD(model.parameters(), lr=0.1, momentum=0.5)
—> 29         train(model, device, train_set_loader, optimizer, epoch, logging_interval=1)
30         test(model, device, test_set_loader)
31
 in train(model, device, train_set_loader, optimizer, epoch, logging_interval)
10         target = target.long()
11         loss = F.nll_loss(output, target)
—> 12         loss.backward()
13
14         torch.nn.utils.clip_grad_norm_(model.parameters(),0.5)
~.conda\envs\py36\lib\site-packages\torch\tensor.py in backward(self, gradient, retain_graph, create_graph)
193                 products. Defaults to False.
194         “”"
–> 195         torch.autograd.backward(self, gradient, retain_graph, create_graph)
196
197     def register_hook(self, hook):
~.conda\envs\py36\lib\site-packages\torch\autograd_init_.py in backward(tensors, grad_tensors, retain_graph, create_graph, grad_variables)
97     Variable._execution_engine.run_backward(
98         tensors, grad_tensors, retain_graph, create_graph,
—> 99         allow_unreachable=True)  # allow_unreachable flag
100
101
RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.cuda.FloatTensor [100, 20]] is at version 1202; expected version 1200 instead. Hint: the backtrace further above shows the operation that failed to compute its gradient. The variable in question was changed in there or anywhere later. Good luck!
i don’t know if the anomaly mode gives you anything else i didn’t find anything