Skip to content

Commit

Permalink
[conn] add brainpy.conn.set_default_dtype
Browse files Browse the repository at this point in the history
  • Loading branch information
chaoming0625 committed Sep 14, 2023
1 parent 69df9da commit 6552722
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
10 changes: 10 additions & 0 deletions brainpy/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# -*- coding: utf-8 -*-

__version__ = "2.4.4.post4"
_minimal_brainpylib_version = '0.1.10'

# fundamental supporting modules
from brainpy import errors, check, tools
Expand All @@ -11,6 +12,15 @@
except ModuleNotFoundError:
raise ModuleNotFoundError(tools.jaxlib_install_info) from None


try:
import brainpylib
if brainpylib.__version__ < _minimal_brainpylib_version:
raise SystemError(f'This version of brainpy ({__version__}) needs brainpylib >= {_minimal_brainpylib_version}.')
del brainpylib
except ModuleNotFoundError:
pass

# Part: Math Foundation #
# ----------------------- #

Expand Down
1 change: 1 addition & 0 deletions brainpy/connect.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
coo2mat_num as coo2mat_num,
mat2mat_num as mat2mat_num,
visualizeMat as visualizeMat,
set_default_dtype as set_default_dtype,

CONN_MAT,
PRE_IDS, POST_IDS,
Expand Down

0 comments on commit 6552722

Please sign in to comment.