Skip to content

Commit

Permalink
[doc] update state resetting APIs
Browse files Browse the repository at this point in the history
  • Loading branch information
chaoming0625 committed Nov 10, 2023
1 parent e1fa7c6 commit ebea6b6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
8 changes: 4 additions & 4 deletions docs/tutorial_toolbox/state_resetting.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"Similar to [state saving and loading](./saving_and_loading.ipynb) , state resetting is implemented with two functions:\n",
"\n",
"- a local function ``.reset_state()`` which resets all local variables in the current node.\n",
"- a global function ``.reset()`` which resets all variables in parent and children nodes."
"- a global function ``brainpy.reset_state()`` which resets all variables in parent and children nodes."
],
"metadata": {
"collapsed": false
Expand Down Expand Up @@ -93,7 +93,7 @@
{
"cell_type": "markdown",
"source": [
"By calling ``net.reset()``, we can reset all states in this network, including variables in the neurons, synapses, and networks. By using ``net.reset_state()``, we can reset the local variables which are defined in the current network. "
"By calling ``brainpy.reset_state(net)``, we can reset all states in this network, including variables in the neurons, synapses, and networks. By using ``net.reset_state()``, we can reset the local variables which are defined in the current network. "
],
"metadata": {
"collapsed": false
Expand All @@ -115,7 +115,7 @@
],
"source": [
"print('Before reset:', net.N.V.value)\n",
"net.reset()\n",
"bp.reset_state(net)\n",
"print('After reset:', net.N.V.value)"
],
"metadata": {
Expand Down Expand Up @@ -157,7 +157,7 @@
{
"cell_type": "markdown",
"source": [
"There is no change for the ``V`` variable, meaning that the network's ``reset_state()`` can not reset states in the children node. Instead, to reset the whole states of the network, users should use ``reset()`` function. "
"There is no change for the ``V`` variable, meaning that the network's ``reset_state()`` can not reset states in the children node. Instead, to reset the whole states of the network, users should use ``brainpy.reset_state()`` function. "
],
"metadata": {
"collapsed": false
Expand Down
1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
Expand Down

0 comments on commit ebea6b6

Please sign in to comment.