Skip to content

Commit e609d47

Browse files
authored
Merge pull request #242 from chaoming0625/master
change doc path/organization
2 parents 3c4e200 + 54823db commit e609d47

23 files changed

+3473
-2604
lines changed

.github/workflows/Linux_CI.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,15 @@ jobs:
2828
run: |
2929
python -m pip install --upgrade pip
3030
python -m pip install flake8 pytest
31-
# python -m pip install https://github.com/google/jax/archive/refs/tags/jax-v0.3.14.tar.gz
31+
# python -m pip install https://github.com/google/jax/archive/refs/tags/jax-v0.3.14.tar.gz
3232
if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
3333
python setup.py install
3434
- name: Lint with flake8
3535
run: |
3636
# stop the build if there are Python syntax errors or undefined names
3737
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
3838
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
39-
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
39+
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
4040
- name: Test with pytest
4141
run: |
4242
pytest brainpy/

.github/workflows/MacOS_CI.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,15 @@ jobs:
2828
run: |
2929
python -m pip install --upgrade pip
3030
python -m pip install flake8 pytest
31-
# python -m pip install https://github.com/google/jax/archive/refs/tags/jax-v0.3.14.tar.gz
31+
# python -m pip install https://github.com/google/jax/archive/refs/tags/jax-v0.3.14.tar.gz
3232
if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
3333
python setup.py install
3434
- name: Lint with flake8
3535
run: |
3636
# stop the build if there are Python syntax errors or undefined names
3737
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
3838
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
39-
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
39+
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
4040
- name: Test with pytest
4141
run: |
4242
pytest brainpy/

.github/workflows/Windows_CI.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
# stop the build if there are Python syntax errors or undefined names
4040
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
4141
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
42-
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
42+
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
4343
- name: Test with pytest
4444
run: |
4545
pytest brainpy/

brainpy/integrators/ode/tests/test_delay_ode.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@ def __init__(self, *args, **kwargs):
4444
self.ref2 = delay_odeint(20., self.eq1, args={'xdelay': case2_delay}, state_delays={'x': case2_delay}, method='euler')
4545

4646
@parameterized.named_parameters(
47-
{'testcase_name': f'constant_delay_{name}', 'method': name}
47+
{'testcase_name': f'constant_delay_{name}',
48+
'method': name}
4849
for name in get_supported_methods()
4950
)
5051
def test1(self, method):
@@ -54,8 +55,8 @@ def test1(self, method):
5455
case1 = delay_odeint(20., self.eq1, args={'xdelay': case1_delay}, state_delays={'x': case1_delay}, method=method)
5556
case2 = delay_odeint(20., self.eq1, args={'xdelay': case2_delay}, state_delays={'x': case2_delay}, method=method)
5657

57-
self.assertTrue((case1.x - self.ref1.x).mean() < 1e-3)
58-
self.assertTrue((case2.x - self.ref2.x).mean() < 1e-3)
58+
self.assertTrue((case1['x'] - self.ref1['x']).mean() < 1e-3)
59+
self.assertTrue((case2['x'] - self.ref2['x']).mean() < 1e-3)
5960

6061
# fig, axs = plt.subplots(2, 1)
6162
# fig.tight_layout(rect=[0, 0, 1, 0.95], pad=3.0)
@@ -90,7 +91,7 @@ def test1(self, method):
9091
case1 = delay_odeint(4., self.eq, args={'xdelay': delay1}, state_delays={'x': delay1}, dt=0.01, method=method)
9192
case2 = delay_odeint(4., self.eq, args={'xdelay': delay2}, state_delays={'x': delay2}, dt=0.01, method=method)
9293

93-
self.assertTrue((case1.x - self.ref1.x).mean() < 1e-1)
94-
self.assertTrue((case2.x - self.ref2.x).mean() < 1e-1)
94+
self.assertTrue((case1['x'] - self.ref1['x']).mean() < 1e-1)
95+
self.assertTrue((case2['x'] - self.ref2['x']).mean() < 1e-1)
9596

9697

docs/index.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ The code of BrainPy is open-sourced at GitHub:
4747
:maxdepth: 2
4848
:caption: BDP Tutorials
4949

50-
tutorial_basics/index
50+
tutorial_math/index
5151
tutorial_building/index
5252
tutorial_simulation/index
5353
tutorial_training/index
@@ -76,13 +76,13 @@ The code of BrainPy is open-sourced at GitHub:
7676
:maxdepth: 1
7777
:caption: Advanced Tutorials
7878

79-
tutorial_math/variables
80-
tutorial_math/base
81-
tutorial_math/compilation
82-
tutorial_math/differentiation
83-
tutorial_math/control_flows
84-
tutorial_math/low-level_operator_customization
85-
tutorial_math/interoperation
79+
tutorial_advanced/variables
80+
tutorial_advanced/base
81+
tutorial_advanced/compilation
82+
tutorial_advanced/differentiation
83+
tutorial_advanced/control_flows
84+
tutorial_advanced/low-level_operator_customization
85+
tutorial_advanced/interoperation
8686

8787

8888
.. toctree::

0 commit comments

Comments
 (0)