Skip to content

Commit 22c9fe7

Browse files
authored
Merge pull request #424 from brainpy/doc
update docs
2 parents 34d8764 + 10853b8 commit 22c9fe7

File tree

15 files changed

+560
-551
lines changed

15 files changed

+560
-551
lines changed

brainpy/_src/dyn/_docs.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@
1111
detach_spk: bool.
1212
method: str. The numerical integration method.
1313
spk_type: The spike data type.
14+
spk_reset: The way to reset the membrane potential when the neuron generates spikes.
15+
This parameter only works when the computing mode is ``TrainingMode``.
16+
It can be ``soft`` and ``hard``. Default is ``soft``.
1417
'''.strip()
1518

1619
ref_doc = '''

brainpy/_src/dyn/ions/base.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,8 +171,8 @@ def current(self, V, C=None, E=None, external: bool = False):
171171
172172
Args:
173173
V: The membrane potential.
174-
C: The ion concentration.
175-
E: The reversal potential.
174+
C: The given ion concentration.
175+
E: The given reversal potential.
176176
external: Include the external current.
177177
178178
Returns:

brainpy/_src/dyn/neurons/base.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ def __init__(
2929

3030
spk_fun: Callable = bm.surrogate.InvSquareGrad(),
3131
spk_type: Any = None,
32+
spk_reset: str = 'soft',
3233
detach_spk: bool = False,
3334
):
3435
super().__init__(size=size,
@@ -38,6 +39,7 @@ def __init__(
3839
sharding=sharding,
3940
method=method)
4041

42+
self.spk_reset = spk_reset
4143
self.spk_fun = is_callable(spk_fun)
4244
self.detach_spk = detach_spk
4345
self._spk_type = spk_type

0 commit comments

Comments
 (0)