Skip to content

Commit

Permalink
Remove old init functions
Browse files Browse the repository at this point in the history
  • Loading branch information
gekkom committed Feb 14, 2024
1 parent 583a860 commit d2133d2
Showing 1 changed file with 0 additions and 36 deletions.
36 changes: 0 additions & 36 deletions snntorch/_neurons/neurons.py
Original file line number Diff line number Diff line change
Expand Up @@ -311,18 +311,6 @@ def init_rleaky():

return spk, mem

@staticmethod
def init_synaptic():
"""Used to initialize syn and mem as an empty SpikeTensor.
``init_flag`` is used as an attribute in the forward pass to convert
the hidden states to the same as the input.
"""

syn = _SpikeTensor(init_flag=False)
mem = _SpikeTensor(init_flag=False)

return syn, mem

@staticmethod
def init_rsynaptic():
"""
Expand All @@ -336,30 +324,6 @@ def init_rsynaptic():

return spk, syn, mem

@staticmethod
def init_lapicque():
"""
Used to initialize mem as an empty SpikeTensor.
``init_flag`` is used as an attribute in the forward pass to convert
the hidden states to the same as the input.
"""

mem = _SpikeTensor(init_flag=False)

return mem

@staticmethod
def init_alpha():
"""Used to initialize syn_exc, syn_inh and mem as an empty SpikeTensor.
``init_flag`` is used as an attribute in the forward pass to convert
the hidden states to the same as the input.
"""
syn_exc = _SpikeTensor(init_flag=False)
syn_inh = _SpikeTensor(init_flag=False)
mem = _SpikeTensor(init_flag=False)

return syn_exc, syn_inh, mem


class _SpikeTensor(torch.Tensor):
"""Inherits from torch.Tensor with additional attributes.
Expand Down

0 comments on commit d2133d2

Please sign in to comment.