Skip to content

Commit

Permalink
Black style formatting (v23.7.0) applied
Browse files Browse the repository at this point in the history
  • Loading branch information
jlubo committed Aug 16, 2023
1 parent 3adc610 commit 60b8c94
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions python/test/unit/test_diffusion.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
particles.
"""


# ---------------------------------------------------------------------------------------
# recipe class
class recipe(A.recipe):
Expand Down Expand Up @@ -59,7 +60,6 @@ def event_generators(self, gid):
# ---------------------------------------------------------------------------------------
# test class
class TestDiffusion(unittest.TestCase):

# Constructor (overridden)
def __init__(self, args):
super(TestDiffusion, self).__init__(args)
Expand All @@ -72,7 +72,6 @@ def __init__(self, args):
def simulate_diffusion(
self, cat, _num_segs, _num_cvs_per_seg, _length, _r_1, _r_2=0.0, _r_3=0.0
):

# ---------------------------------------------------------------------------------------
# set the main parameters and calculate geometrical measures
num_segs = _num_segs # number of segments
Expand All @@ -97,7 +96,7 @@ def simulate_diffusion(
num_segs * num_cvs_per_seg
) # surface area of one cylindrical CV in µm^2 (excluding the circle-shaped ends, since Arbor does not consider current flux there)
volume_tot = (
np.pi * (radius_1 ** 2 + radius_2 ** 2 + radius_3 ** 2) * length_per_seg
np.pi * (radius_1**2 + radius_2**2 + radius_3**2) * length_per_seg
) # volume of the whole setup in µm^3
volume_per_cv = volume_tot / (
num_segs * num_cvs_per_seg
Expand Down Expand Up @@ -150,7 +149,6 @@ def simulate_diffusion(
}
)
elif num_segs == 3:

s = tree.append(
A.mnpos,
A.mpoint(-1 / 3 * length, 0, 0, radius_1),
Expand Down Expand Up @@ -302,7 +300,6 @@ def simulate_diffusion(
# Test: simulations with equal radii
@fixtures.diffusion_catalogue()
def test_diffusion_equal_radii(self, diffusion_catalogue):

self.simulate_diffusion(
diffusion_catalogue, 1, 600, 10, 4
) # 1 segment with radius 4 µm
Expand Down

0 comments on commit 60b8c94

Please sign in to comment.