Debian Codegraph @

brian2/utils/environment.py

raw
1 """
2 Utility functions to get information about the environment Brian is running in.
3 """
4
5 import builtins
6
7
8 def running_from_ipython():
9 """
10 Check whether we are currently running under ipython.
11
12 Returns
13 -------
14 ipython : bool
15 Whether running under ipython or not.
16 """
17 return getattr(builtins, "__IPYTHON__", False)