brainstate 0.1.2__py2.py3-none-any.whl → 0.1.3__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. brainstate/__init__.py +1 -1
  2. brainstate/_compatible_import.py +10 -10
  3. brainstate/mixin.py +1 -14
  4. brainstate/nn/__init__.py +81 -17
  5. brainstate/nn/{_interaction/_conv.py → _conv.py} +1 -1
  6. brainstate/nn/{_dynamics/_state_delay.py → _delay.py} +6 -2
  7. brainstate/nn/{_elementwise/_dropout.py → _dropout.py} +1 -1
  8. brainstate/nn/{_dynamics/_dynamics_base.py → _dynamics.py} +139 -18
  9. brainstate/nn/{_elementwise/_elementwise.py → _elementwise.py} +1 -1
  10. brainstate/nn/{_interaction/_embedding.py → _embedding.py} +1 -1
  11. brainstate/nn/{_event/_fixedprob_mv.py → _fixedprob_mv.py} +1 -1
  12. brainstate/nn/{_dyn_impl/_inputs.py → _inputs.py} +4 -5
  13. brainstate/nn/{_interaction/_linear.py → _linear.py} +2 -5
  14. brainstate/nn/{_event/_linear_mv.py → _linear_mv.py} +1 -1
  15. brainstate/nn/{_event/__init__.py → _ltp.py} +7 -5
  16. brainstate/nn/{_dyn_impl/_dynamics_neuron.py → _neuron.py} +2 -2
  17. brainstate/nn/{_interaction/_normalizations.py → _normalizations.py} +1 -1
  18. brainstate/nn/{_interaction/_poolings.py → _poolings.py} +1 -1
  19. brainstate/nn/{_interaction/_poolings_test.py → _poolings_test.py} +1 -1
  20. brainstate/nn/{_dynamics/_projection_base.py → _projection.py} +35 -3
  21. brainstate/nn/{_dyn_impl/_rate_rnns.py → _rate_rnns.py} +2 -2
  22. brainstate/nn/{_dyn_impl/_readout.py → _readout.py} +3 -3
  23. brainstate/nn/_stp.py +236 -0
  24. brainstate/nn/{_dyn_impl/_dynamics_synapse.py → _synapse.py} +17 -206
  25. brainstate/nn/_synaptic_projection.py +133 -0
  26. brainstate/nn/{_dynamics/_synouts.py → _synouts.py} +4 -1
  27. {brainstate-0.1.2.dist-info → brainstate-0.1.3.dist-info}/METADATA +1 -1
  28. {brainstate-0.1.2.dist-info → brainstate-0.1.3.dist-info}/RECORD +44 -46
  29. brainstate/nn/_dyn_impl/__init__.py +0 -42
  30. brainstate/nn/_dynamics/__init__.py +0 -37
  31. brainstate/nn/_elementwise/__init__.py +0 -22
  32. brainstate/nn/_interaction/__init__.py +0 -41
  33. /brainstate/nn/{_interaction/_conv_test.py → _conv_test.py} +0 -0
  34. /brainstate/nn/{_elementwise/_dropout_test.py → _dropout_test.py} +0 -0
  35. /brainstate/nn/{_dynamics/_dynamics_base_test.py → _dynamics_test.py} +0 -0
  36. /brainstate/nn/{_elementwise/_elementwise_test.py → _elementwise_test.py} +0 -0
  37. /brainstate/nn/{_event/_fixedprob_mv_test.py → _fixedprob_mv_test.py} +0 -0
  38. /brainstate/nn/{_event/_linear_mv_test.py → _linear_mv_test.py} +0 -0
  39. /brainstate/nn/{_interaction/_linear_test.py → _linear_test.py} +0 -0
  40. /brainstate/nn/{_dyn_impl/_dynamics_neuron_test.py → _neuron_test.py} +0 -0
  41. /brainstate/nn/{_interaction/_normalizations_test.py → _normalizations_test.py} +0 -0
  42. /brainstate/nn/{_dyn_impl/_rate_rnns_test.py → _rate_rnns_test.py} +0 -0
  43. /brainstate/nn/{_dyn_impl/_readout_test.py → _readout_test.py} +0 -0
  44. /brainstate/nn/{_dyn_impl/_dynamics_synapse_test.py → _synapse_test.py} +0 -0
  45. /brainstate/nn/{_dynamics/_synouts_test.py → _synouts_test.py} +0 -0
  46. {brainstate-0.1.2.dist-info → brainstate-0.1.3.dist-info}/LICENSE +0 -0
  47. {brainstate-0.1.2.dist-info → brainstate-0.1.3.dist-info}/WHEEL +0 -0
  48. {brainstate-0.1.2.dist-info → brainstate-0.1.3.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,133 @@
1
+ # Copyright 2025 BDP Ecosystem Limited. All Rights Reserved.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+ # ==============================================================================
15
+ # -*- coding: utf-8 -*-
16
+
17
+
18
+ from typing import Callable, Union
19
+
20
+ import brainunit as u
21
+
22
+ from brainstate._compatible_import import brainevent
23
+ from brainstate.mixin import ParamDescriber, AlignPost, UpdateReturn
24
+ from ._dynamics import Dynamics, Projection
25
+ from ._projection import AlignPostProj, RawProj
26
+ from ._stp import ShortTermPlasticity
27
+ from ._synapse import Synapse
28
+ from ._synouts import SynOut
29
+
30
+ __all__ = [
31
+ 'align_pre_projection',
32
+ 'align_post_projection',
33
+ ]
34
+
35
+
36
+ class align_pre_projection(Projection):
37
+ """
38
+ Represents a pre-synaptic alignment projection mechanism.
39
+
40
+ This class inherits from the `Projection` base class and is designed to
41
+ manage the pre-synaptic alignment process in neural network simulations.
42
+ It takes into account pre-synaptic dynamics, synaptic properties, delays,
43
+ communication functions, synaptic outputs, post-synaptic dynamics, and
44
+ short-term plasticity.
45
+
46
+ Attributes:
47
+ pre (Dynamics): The pre-synaptic dynamics object.
48
+ syn (Synapse): The synaptic object after pre-synaptic alignment.
49
+ delay (u.Quantity[u.second]): The output delay from the synapse.
50
+ projection (RawProj): The raw projection object handling communication,
51
+ output, and post-synaptic dynamics.
52
+ stp (ShortTermPlasticity, optional): The short-term plasticity object,
53
+ defaults to None.
54
+ """
55
+
56
+ def __init__(
57
+ self,
58
+ pre: Dynamics,
59
+ syn: Union[Synapse, ParamDescriber[Synapse]],
60
+ delay: u.Quantity[u.second] | None,
61
+ comm: Callable,
62
+ out: SynOut,
63
+ post: Dynamics,
64
+ stp: ShortTermPlasticity = None,
65
+ ):
66
+ super().__init__()
67
+ pre = pre
68
+ syn: Synapse = pre.align_pre(syn)
69
+ assert isinstance(syn, UpdateReturn), "Synapse must implement UpdateReturn interface"
70
+ # require "syn" implement the "update_return()" function
71
+ self.delay = syn.output_delay(delay)
72
+ self.projection = RawProj(comm=comm, out=out, post=post)
73
+ self.stp = stp
74
+
75
+ def update(self):
76
+ x = self.delay()
77
+ if self.stp is not None:
78
+ x = self.stp(x)
79
+ return self.projection(x)
80
+
81
+
82
+ class align_post_projection(Projection):
83
+ """
84
+ Represents a post-synaptic alignment projection mechanism.
85
+
86
+ This class inherits from the `Projection` base class and is designed to
87
+ manage the post-synaptic alignment process in neural network simulations.
88
+ It takes into account spike generators, communication functions, synaptic
89
+ properties, synaptic outputs, post-synaptic dynamics, and short-term plasticity.
90
+
91
+ Args:
92
+ *spike_generator: Callable(s) that generate spike events or transform input spikes.
93
+ comm (Callable): Communication function for the projection.
94
+ syn (Union[AlignPost, ParamDescriber[AlignPost]]): The post-synaptic alignment object or its parameter describer.
95
+ out (Union[SynOut, ParamDescriber[SynOut]]): The synaptic output object or its parameter describer.
96
+ post (Dynamics): The post-synaptic dynamics object.
97
+ stp (ShortTermPlasticity, optional): The short-term plasticity object, defaults to None.
98
+
99
+ """
100
+ def __init__(
101
+ self,
102
+ *spike_generator,
103
+ comm: Callable,
104
+ syn: Union[AlignPost, ParamDescriber[AlignPost]],
105
+ out: Union[SynOut, ParamDescriber[SynOut]],
106
+ post: Dynamics,
107
+ stp: ShortTermPlasticity = None,
108
+ ):
109
+ super().__init__()
110
+ self.spike_generator = spike_generator
111
+ self.projection = AlignPostProj(comm=comm, syn=syn, out=out, post=post)
112
+ self.stp = stp
113
+
114
+ def update(self, *x):
115
+ for fun in self.spike_generator:
116
+ x = fun(*x)
117
+ if isinstance(x, (tuple, list)):
118
+ x = tuple(x)
119
+ else:
120
+ x = (x,)
121
+ assert len(x) == 1, "Spike generator must return a single value or a tuple/list of values"
122
+ x = brainevent.BinaryArray(x[0]) # Ensure input is a BinaryFloat for spike generation
123
+ if self.stp is not None:
124
+ x = brainevent.MaskedFloat(self.stp(x)) # Ensure STP output is a MaskedFloat
125
+ return self.projection(x)
126
+
127
+
128
+ class align_pre_ltp(Projection):
129
+ pass
130
+
131
+
132
+ class align_post_ltp(Projection):
133
+ pass
@@ -19,8 +19,8 @@ import brainunit as u
19
19
  import jax.numpy as jnp
20
20
 
21
21
  from brainstate.mixin import BindCondData
22
- from brainstate.nn._module import Module
23
22
  from brainstate.typing import ArrayLike
23
+ from ._module import Module
24
24
 
25
25
  __all__ = [
26
26
  'SynOut', 'COBA', 'CUBA', 'MgBlock',
@@ -47,6 +47,9 @@ class SynOut(Module, BindCondData):
47
47
  ret = self.update(self._conductance, *args, **kwargs)
48
48
  return ret
49
49
 
50
+ def update(self, conductance, potential):
51
+ raise NotImplementedError
52
+
50
53
 
51
54
  class COBA(SynOut):
52
55
  r"""
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: brainstate
3
- Version: 0.1.2
3
+ Version: 0.1.3
4
4
  Summary: A ``State``-based Transformation System for Program Compilation and Augmentation.
5
5
  Home-page: https://github.com/chaobrain/brainstate
6
6
  Author: BrainState Developers
@@ -1,11 +1,11 @@
1
- brainstate/__init__.py,sha256=50znZ0wsJBdgX9Wvlv4xvsuNGp4XdgR60LTFrplmBz0,1496
2
- brainstate/_compatible_import.py,sha256=96CR40jbcrvaBXO0Hrlm7Cpde-4nRj-6z-P753bitFc,5001
1
+ brainstate/__init__.py,sha256=cJBE8xL38olR6vA35aozQE1oJHTkgRFUKGUaiwsU19g,1496
2
+ brainstate/_compatible_import.py,sha256=E0KTFLltv84mA6QuMzV-0KLjN5UdTP-sbhfolzjMVUA,5061
3
3
  brainstate/_state.py,sha256=o5Kk4bGwVz6Dfj9dlmZqdh6zUXcz6Tvc6WOjH9ajlIU,60716
4
4
  brainstate/_state_test.py,sha256=b6uvZdVRyC4n6-fYzmHNry1b-gJ6zE_kRSxGinqiHaw,1638
5
5
  brainstate/_utils.py,sha256=j-b239RHfC5BnvhGbSExQpdY21LrMEyWMSHBdNGThOI,1657
6
6
  brainstate/environ.py,sha256=VgtG0S_aR1g_1gplRWg_v2ZrcS-F6LZk35BPCBgsIIA,17660
7
7
  brainstate/environ_test.py,sha256=QD6sPCKNtqemVCGwkdImjMazatrvvLr6YeAVcfUnVVY,2045
8
- brainstate/mixin.py,sha256=1PPifp91eKEeMJO8cLjZPmXehPBE5tIoRhMVpvysquo,11272
8
+ brainstate/mixin.py,sha256=gt7pPK7VvDR7OO8VjBfxVVKyGQ264cvNHYNdhLpbeX0,10803
9
9
  brainstate/mixin_test.py,sha256=Oq_0fwC9vpXDN4t4dTBhWzLdFDNlcYsrcip14F1yECI,3079
10
10
  brainstate/surrogate.py,sha256=Iu1-WWJKH5CIjXIHKwEF8ufxVYpFZCltU_6dEH9DYqk,53470
11
11
  brainstate/transform.py,sha256=OvshYpPnp3YXPG6riy15Ve7jcX8t0aaATl1xZnsFeic,858
@@ -54,53 +54,51 @@ brainstate/init/_random_inits.py,sha256=GYovk2h2Lc1jY5ByW4R8OoZ71jbaE3BYGTfDw4-a
54
54
  brainstate/init/_random_inits_test.py,sha256=c1pUdWXQxL-seEvjO_8fBkaDL6T63b6ALNfQrNuuBbg,5287
55
55
  brainstate/init/_regular_inits.py,sha256=tcZDTXR8jiRqERuJleg_9JRGGzJj-V3LhTMcr_gt_k0,3149
56
56
  brainstate/init/_regular_inits_test.py,sha256=bvv0AOfLOEP0BIQIBLztKw3EPyEp7n2fHW8PUrmWuHk,1820
57
- brainstate/nn/__init__.py,sha256=dUEH_S5jRTq0nY1xNkpN_4MQrmHXHGSmGp3xgGenqNc,1924
57
+ brainstate/nn/__init__.py,sha256=NfZMwitNb9nT-UPMt4j3frIiBNHcsY1D9LWxDTNwSY0,3666
58
58
  brainstate/nn/_collective_ops.py,sha256=rWcjqaP0rW6sXdhE0fjtDi4twmq5VvhNEg8AoiQ-tDU,17390
59
59
  brainstate/nn/_collective_ops_test.py,sha256=bwq0DApcsk0_2xpxMl0_e2cGKT63g5rSngpigCm07ps,1409
60
60
  brainstate/nn/_common.py,sha256=Pt8P1LgE0qW3QnfX8CQQGH3yZ78RL7NkIqqYEw_z8xs,7096
61
+ brainstate/nn/_conv.py,sha256=Zk-yj34n6CkjntcM9xpMGLTxKNfWdIWsTsoGbtdL0yU,18448
62
+ brainstate/nn/_conv_test.py,sha256=2lcUTG7twkyhuyKwuBux-NgU8NU_W4Cp1-G8EyDJ_uk,8862
63
+ brainstate/nn/_delay.py,sha256=AbTGEVrZIG9TjwvUXxLRcNVQPPiNxgPPYpFKqJ8pfUM,16957
64
+ brainstate/nn/_dropout.py,sha256=WX9aYBG4KkPPog5qaSqujxATeb4hVQl3EorXIDmM1hg,17720
65
+ brainstate/nn/_dropout_test.py,sha256=9i2ZW5by0S9zfVHmZKLN0WpI1bXH6h9-QLXamG6lVXA,4432
66
+ brainstate/nn/_dynamics.py,sha256=l4Z8v2uGSiwDP-kXUcWPGvgc0UDyy7w6kPTAgi6p7is,48125
67
+ brainstate/nn/_dynamics_test.py,sha256=w7AV57LdhbBNYprdFpKq8MFSCbXKVkGgp_NbL3ANX3I,2769
68
+ brainstate/nn/_elementwise.py,sha256=4czeJWGQopV49iZo8DuN_WzAbXoMC1gtqaGjlON6e7c,33291
69
+ brainstate/nn/_elementwise_test.py,sha256=_dd9eX2ZJ7p24ahuoapCaRTZ0g1boufXMyqHFx1d4WY,5688
70
+ brainstate/nn/_embedding.py,sha256=SaAJbgXmuJ8XlCOX9ob4yvmgh9Fk627wMguRzJMJ1H8,2138
61
71
  brainstate/nn/_exp_euler.py,sha256=ndDB43PM4jsZKu_zdLTZ2-ojnuNrg55LZap23oBTtdA,3493
62
72
  brainstate/nn/_exp_euler_test.py,sha256=XD--qMbGHrHa3WtcPMmJKk59giDcEhSqZuBOmTNYUr8,1227
73
+ brainstate/nn/_fixedprob_mv.py,sha256=8GRp4MALSIAGnIFqVZpnEAKoWTEsyeYAiIyu6fcmLLM,6606
74
+ brainstate/nn/_fixedprob_mv_test.py,sha256=qbRBh-MpMtEOsg492gFu2w9-FOP9z_bXapm-Q0gLLYM,3929
75
+ brainstate/nn/_inputs.py,sha256=wPOfPE4IesNoDmxZJxqR0siBlJioEX-_1IZ2cltAIpM,20605
76
+ brainstate/nn/_linear.py,sha256=5WuhcqU-uBUC91vnwezQYMHPKmlZPDgIJ5UpffxoX1I,14472
77
+ brainstate/nn/_linear_mv.py,sha256=vgO7Xi7WlGULzgvvbWK5zefymn-YAdAhdAQ0tUMC2Ls,2670
78
+ brainstate/nn/_linear_mv_test.py,sha256=ZCM1Zy6mImQfCfdZOGnTwkiLLPXK5yalv1Ts9sWZuPA,3864
79
+ brainstate/nn/_linear_test.py,sha256=eIS-VCR3QmXB_byO1Uexg65Pv48CBRUA_Je-UGrFVTY,2925
80
+ brainstate/nn/_ltp.py,sha256=_najNUyfaFYcOlUTm7ThJopInbos3kwJyrm-QUfI-hc,861
63
81
  brainstate/nn/_module.py,sha256=ksbmO_-bZzaP8XTRAcN2oi2ZMdSuSv-XVeWc2VJncVc,12808
64
82
  brainstate/nn/_module_test.py,sha256=_RKHY8LHg6nbFHkvPAsEPVpp9rW6XfrcF8YD68u4o4w,8956
83
+ brainstate/nn/_neuron.py,sha256=2walTScvL034LS53pArDASXz6z26SSPbmCvchWWjkUU,27441
84
+ brainstate/nn/_neuron_test.py,sha256=QF8pixUqA5Oj7MrNi2NR8VAnfGpAvNpwV2mBc3e_pTY,6393
85
+ brainstate/nn/_normalizations.py,sha256=4B1YVI6AZyJLHseJK9eiSeMOIq--0ZuDG58iC9mrekE,37387
86
+ brainstate/nn/_normalizations_test.py,sha256=JTqpH265GT0eKw3hXmT0qC8ZM5NkUe98of0uYS7_5Us,2456
87
+ brainstate/nn/_poolings.py,sha256=h5aIj_K3X2HSMjrOtkgwiCpvLxfXXEUvFFa57Cxp5bI,46969
88
+ brainstate/nn/_poolings_test.py,sha256=qje9PVWvPGiYOv6UlTEWfpqqjpv4Xop5rO0ATcgcF0w,7497
89
+ brainstate/nn/_projection.py,sha256=h-UinIlkmJ4ITtsW-K4TpyPP-xDH3zHb7LjTWFOu4eI,13668
90
+ brainstate/nn/_rate_rnns.py,sha256=OQHMyq9kKd2q44dOHLuTqHKTGuraPMqXVutFP_LYIyU,20676
91
+ brainstate/nn/_rate_rnns_test.py,sha256=__hhx7e6LX_1mDLLQyIi4TNCaFAWnOVSTIgwHNjzf2g,2444
92
+ brainstate/nn/_readout.py,sha256=OJjSba5Wr7dtUXqYhAv1D7BUGOI-lAmg6urxPBrZe3c,7116
93
+ brainstate/nn/_readout_test.py,sha256=L2T0-SkiACxkY_I5Pbnbmy0Zw3tbpV3l5xVzAw42f2g,2136
94
+ brainstate/nn/_stp.py,sha256=-ahDEqSp8bQsU_nUK4jks8fjMYKgIbO0v7zpyGVuXtA,8645
95
+ brainstate/nn/_synapse.py,sha256=5AP_UpY5LvsAVAu0yExi7pXGpeqnlZW8J8r-Gw-26AA,20239
96
+ brainstate/nn/_synapse_test.py,sha256=xmCWFxZUIM2YtmW5otKnADGCCK__4JpXmSYcZ3wzlQM,4994
97
+ brainstate/nn/_synaptic_projection.py,sha256=iGw5NWhpvOJ62M7EzQpD1oVcHgd_L6XkPNs0VM3ognk,5083
98
+ brainstate/nn/_synouts.py,sha256=jWQP1-qXFpdYgyUSJNFD7_bk4_-67ok36br-OzbcSXY,4524
99
+ brainstate/nn/_synouts_test.py,sha256=sfjotlS--4hT22Vb5RfmpfmXABa8z-VdxZYUSocMmlU,2244
65
100
  brainstate/nn/_utils.py,sha256=epfELIy1COgdS9z5be-fmbFhagNugcIHpw4ww-HlkSY,3123
66
101
  brainstate/nn/metrics.py,sha256=TXCB_yGQzamklJCI5FGOAZ5dihtY-gjYlSi2SCLC3LA,14700
67
- brainstate/nn/_dyn_impl/__init__.py,sha256=J1hMqNey1921tZppCjuHApB6oc-5aGhWXyOXh96CeWM,1322
68
- brainstate/nn/_dyn_impl/_dynamics_neuron.py,sha256=6xsGF2Oy_oD6bcTdfwqnHBtfdAJREIl5qvNUZKZRlnQ,27482
69
- brainstate/nn/_dyn_impl/_dynamics_neuron_test.py,sha256=QF8pixUqA5Oj7MrNi2NR8VAnfGpAvNpwV2mBc3e_pTY,6393
70
- brainstate/nn/_dyn_impl/_dynamics_synapse.py,sha256=b2QMEzasbXTp7k1XWNg7nRt4-WddCym0CSEErjPRIWA,27449
71
- brainstate/nn/_dyn_impl/_dynamics_synapse_test.py,sha256=xmCWFxZUIM2YtmW5otKnADGCCK__4JpXmSYcZ3wzlQM,4994
72
- brainstate/nn/_dyn_impl/_inputs.py,sha256=Fe3tgSwJMrq2HfZJq9CTgNy24Ji6tnLCqB4hkhaY_K0,20675
73
- brainstate/nn/_dyn_impl/_rate_rnns.py,sha256=SXlrHZhih4LD99Jg8OwIWur5UQbd6E_zotkHvkFFstc,20715
74
- brainstate/nn/_dyn_impl/_rate_rnns_test.py,sha256=__hhx7e6LX_1mDLLQyIi4TNCaFAWnOVSTIgwHNjzf2g,2444
75
- brainstate/nn/_dyn_impl/_readout.py,sha256=UzaJ6WIMpNjqHolhjHTpyCZ5E2nSDucvuV5PBW7rOPs,7151
76
- brainstate/nn/_dyn_impl/_readout_test.py,sha256=L2T0-SkiACxkY_I5Pbnbmy0Zw3tbpV3l5xVzAw42f2g,2136
77
- brainstate/nn/_dynamics/__init__.py,sha256=j1HSWu01wf5-KjSaNhBC9utVGDALOhUsFPrLPcPPDsM,1208
78
- brainstate/nn/_dynamics/_dynamics_base.py,sha256=stBAkb8f973vJe66p0tve-0AO_j008BCpAA96FIPnTI,43363
79
- brainstate/nn/_dynamics/_dynamics_base_test.py,sha256=w7AV57LdhbBNYprdFpKq8MFSCbXKVkGgp_NbL3ANX3I,2769
80
- brainstate/nn/_dynamics/_projection_base.py,sha256=O86VfZkd8Qd5_8CDK-4eCGS6Jkp1CKyW6J9__bQnmo0,12893
81
- brainstate/nn/_dynamics/_state_delay.py,sha256=kSgel1OSFB92WcfGTsIjgb-KW389ydXTcLbTUjylU-A,16867
82
- brainstate/nn/_dynamics/_synouts.py,sha256=Py9DM3o-JmkoqYyQM5vl89-SBqTBRdk2CUYgYHYu3No,4453
83
- brainstate/nn/_dynamics/_synouts_test.py,sha256=sfjotlS--4hT22Vb5RfmpfmXABa8z-VdxZYUSocMmlU,2244
84
- brainstate/nn/_elementwise/__init__.py,sha256=PK8oq1K_EG2941AiUyLxCWoRdWvMO3yt8ZJbw3Lkhu8,935
85
- brainstate/nn/_elementwise/_dropout.py,sha256=ymr87YYA5x5C_c9HzNLGPJK_ebJ22Y-KsK-gZJY_2MU,17733
86
- brainstate/nn/_elementwise/_dropout_test.py,sha256=9i2ZW5by0S9zfVHmZKLN0WpI1bXH6h9-QLXamG6lVXA,4432
87
- brainstate/nn/_elementwise/_elementwise.py,sha256=yO6BukJFLfnICPELEFp2kfutFM8Jeg7TaERXFp-aNrk,33304
88
- brainstate/nn/_elementwise/_elementwise_test.py,sha256=_dd9eX2ZJ7p24ahuoapCaRTZ0g1boufXMyqHFx1d4WY,5688
89
- brainstate/nn/_event/__init__.py,sha256=OLteeA3d1Kq8yi3XETA-rFYtYpojZRpY1J_h5MpH3rY,919
90
- brainstate/nn/_event/_fixedprob_mv.py,sha256=MpVCiYGiDC8GAuJWtYXKrpzP9yDtnYHolHlwyzoQ1r4,6619
91
- brainstate/nn/_event/_fixedprob_mv_test.py,sha256=qbRBh-MpMtEOsg492gFu2w9-FOP9z_bXapm-Q0gLLYM,3929
92
- brainstate/nn/_event/_linear_mv.py,sha256=KslIdse7KZ7FWm5qcOMC-COM__1rB-sUJmXvlXY11y8,2683
93
- brainstate/nn/_event/_linear_mv_test.py,sha256=ZCM1Zy6mImQfCfdZOGnTwkiLLPXK5yalv1Ts9sWZuPA,3864
94
- brainstate/nn/_interaction/__init__.py,sha256=TTY_SeNrdx4VnUSw6vdyl02OHdS9Qs15cWBp6kjsyNQ,1289
95
- brainstate/nn/_interaction/_conv.py,sha256=QMZR4HRAYe8Nzr3qExp0PWr6wuUp2rh5YxmPq1r1vcY,18461
96
- brainstate/nn/_interaction/_conv_test.py,sha256=2lcUTG7twkyhuyKwuBux-NgU8NU_W4Cp1-G8EyDJ_uk,8862
97
- brainstate/nn/_interaction/_embedding.py,sha256=8HC-J3RhvGGrvqA0-BBaFDk6tmlunPP6bNohjRSQzYo,2151
98
- brainstate/nn/_interaction/_linear.py,sha256=jk765kASgwVG1r-xjoM49Thfa1Cu32mscy7ci79bjDI,14729
99
- brainstate/nn/_interaction/_linear_test.py,sha256=eIS-VCR3QmXB_byO1Uexg65Pv48CBRUA_Je-UGrFVTY,2925
100
- brainstate/nn/_interaction/_normalizations.py,sha256=4yoU04wK21_zk6Egpwb9YN_pSWUH5Qa6hJ1bLxX7wQw,37400
101
- brainstate/nn/_interaction/_normalizations_test.py,sha256=JTqpH265GT0eKw3hXmT0qC8ZM5NkUe98of0uYS7_5Us,2456
102
- brainstate/nn/_interaction/_poolings.py,sha256=2hJDACuHv3CkO-nyyAqVZp7Sa3UFa_ROFGiYmhXWqKk,46982
103
- brainstate/nn/_interaction/_poolings_test.py,sha256=7-jEs_UcMNWm8q6NbrRRX3bTn14jBjGiAX0KBaROng0,7510
104
102
  brainstate/optim/__init__.py,sha256=7Ao0LCtDNAoxSRSXiLLKnd1_4mR2GSExizpN38il-Fo,1195
105
103
  brainstate/optim/_base.py,sha256=P37k8w46iQZZZnFLa5OF83Sb8DLQfYMez9ZRObBqVsE,1835
106
104
  brainstate/optim/_lr_scheduler.py,sha256=0t7kl35MLmc0UcSu587nI28cI3SohYhy_19Al-5dNTM,15289
@@ -126,8 +124,8 @@ brainstate/util/_pretty_table.py,sha256=uJVaamFGQ4nKP8TkEGPWXHpzjMecDo2q1Ah6XtRj
126
124
  brainstate/util/_scaling.py,sha256=U6DM-afPrLejiGqo1Nla7z4YbTBVicctsBEweurr_mk,7524
127
125
  brainstate/util/_struct.py,sha256=7HbbQNrZ3zxYw93MU1bUZ9ZPBKftYOVKuXEochLSErw,17479
128
126
  brainstate/util/filter.py,sha256=skuq51y0P5-N611fQ-zB2QyaJIFqN_WbROzZHv0RgOc,14086
129
- brainstate-0.1.2.dist-info/LICENSE,sha256=VZe9u1jgUL2eCY6ZPOYgdb8KCblCHt8ECdbtJid6e1s,11550
130
- brainstate-0.1.2.dist-info/METADATA,sha256=Mv44muheQeXJ67RF5GQrkSxVWfj4VAZnkse6_7z5OTY,4135
131
- brainstate-0.1.2.dist-info/WHEEL,sha256=bb2Ot9scclHKMOLDEHY6B2sicWOgugjFKaJsT7vwMQo,110
132
- brainstate-0.1.2.dist-info/top_level.txt,sha256=eQbGgKn0ptx7FDWuua0V0wr4K1VHi2iOUCYo3fUQBRA,11
133
- brainstate-0.1.2.dist-info/RECORD,,
127
+ brainstate-0.1.3.dist-info/LICENSE,sha256=VZe9u1jgUL2eCY6ZPOYgdb8KCblCHt8ECdbtJid6e1s,11550
128
+ brainstate-0.1.3.dist-info/METADATA,sha256=PaBKgarOn04Zgm7OY8tI8onrfX3bh0jACHKuarxZpas,4135
129
+ brainstate-0.1.3.dist-info/WHEEL,sha256=bb2Ot9scclHKMOLDEHY6B2sicWOgugjFKaJsT7vwMQo,110
130
+ brainstate-0.1.3.dist-info/top_level.txt,sha256=eQbGgKn0ptx7FDWuua0V0wr4K1VHi2iOUCYo3fUQBRA,11
131
+ brainstate-0.1.3.dist-info/RECORD,,
@@ -1,42 +0,0 @@
1
- # Copyright 2024 BDP Ecosystem Limited. All Rights Reserved.
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
- # ==============================================================================
15
-
16
-
17
- from ._dynamics_neuron import *
18
- from ._dynamics_neuron import __all__ as dyn_neuron_all
19
- from ._dynamics_synapse import *
20
- from ._dynamics_synapse import __all__ as dyn_synapse_all
21
- from ._inputs import *
22
- from ._inputs import __all__ as inputs_all
23
- from ._rate_rnns import *
24
- from ._rate_rnns import __all__ as rate_rnns
25
- from ._readout import *
26
- from ._readout import __all__ as readout_all
27
-
28
- __all__ = (
29
- dyn_neuron_all
30
- + dyn_synapse_all
31
- + inputs_all
32
- + rate_rnns
33
- + readout_all
34
- )
35
-
36
- del (
37
- dyn_neuron_all,
38
- dyn_synapse_all,
39
- inputs_all,
40
- readout_all,
41
- rate_rnns,
42
- )
@@ -1,37 +0,0 @@
1
- # Copyright 2024 BDP Ecosystem Limited. All Rights Reserved.
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
- # ==============================================================================
15
-
16
- from ._dynamics_base import *
17
- from ._dynamics_base import __all__ as dyn_all
18
- from ._projection_base import *
19
- from ._projection_base import __all__ as projection_all
20
- from ._state_delay import *
21
- from ._state_delay import __all__ as state_delay_all
22
- from ._synouts import *
23
- from ._synouts import __all__ as synouts_all
24
-
25
- __all__ = (
26
- dyn_all
27
- + projection_all
28
- + state_delay_all
29
- + synouts_all
30
- )
31
-
32
- del (
33
- dyn_all,
34
- projection_all,
35
- state_delay_all,
36
- synouts_all
37
- )
@@ -1,22 +0,0 @@
1
- # Copyright 2024 BDP Ecosystem Limited. All Rights Reserved.
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
- # ==============================================================================
15
-
16
- from ._dropout import *
17
- from ._dropout import __all__ as dropout_all
18
- from ._elementwise import *
19
- from ._elementwise import __all__ as elementwise_all
20
-
21
- __all__ = dropout_all + elementwise_all
22
- del dropout_all, elementwise_all
@@ -1,41 +0,0 @@
1
- # Copyright 2024 BDP Ecosystem Limited. All Rights Reserved.
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
- # ==============================================================================
15
-
16
- from ._conv import *
17
- from ._conv import __all__ as conv_all
18
- from ._embedding import *
19
- from ._embedding import __all__ as embed_all
20
- from ._linear import *
21
- from ._linear import __all__ as linear_all
22
- from ._normalizations import *
23
- from ._normalizations import __all__ as normalizations_all
24
- from ._poolings import *
25
- from ._poolings import __all__ as poolings_all
26
-
27
- __all__ = (
28
- conv_all +
29
- linear_all +
30
- normalizations_all +
31
- poolings_all +
32
- embed_all
33
- )
34
-
35
- del (
36
- conv_all,
37
- linear_all,
38
- normalizations_all,
39
- poolings_all,
40
- embed_all
41
- )