Skip to content
This repository was archived by the owner on Feb 26, 2025. It is now read-only.

Commit 5a23f52

Browse files
authored
Merge pull request #418 from BlueBrain/macos
avoid loading hoc.so in mac that raises symbol not found #417
2 parents 948ab28 + 88a50e6 commit 5a23f52

File tree

1 file changed

+5
-12
lines changed

1 file changed

+5
-12
lines changed

bluepyopt/ephys/simulators.py

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -34,16 +34,11 @@ def __init__(self, dt=None, cvode_active=True, cvode_minstep=None,
3434
"./data/".
3535
"""
3636

37-
if platform.system() == 'Windows':
38-
# hoc.so does not exist on NEURON Windows
39-
# although \\hoc.pyd can work here, it gives an error for
40-
# nrn_nobanner_ line
41-
self.disable_banner = False
42-
self.banner_disabled = False
43-
else:
44-
self.disable_banner = True
45-
self.banner_disabled = False
46-
37+
# hoc.so does not exist on NEURON Windows or MacOS
38+
# although \\hoc.pyd can work here, it gives an error for
39+
# nrn_nobanner_ line
40+
self.disable_banner = platform.system() not in ['Windows', 'Darwin']
41+
self.banner_disabled = False
4742
self.mechanisms_directory = mechanisms_directory
4843
self.neuron.h.load_file('stdrun.hoc')
4944

@@ -93,8 +88,6 @@ def _nrn_disable_banner():
9388
ctypes.c_int.in_dll(nrndll, 'nrn_nobanner_').value = 1
9489

9590
# pylint: disable=R0201
96-
# TODO function below should probably a class property or something in that
97-
# sense
9891
@property
9992
def neuron(self):
10093
"""Return neuron module"""

0 commit comments

Comments
 (0)