Skip to content
Snippets Groups Projects

feat: Reset to zero for Leaky

Merged Jerome Hue requested to merge jeromeh/aidge_core:leaky-reset into dev
1 unresolved thread
1 file
+ 13
0
Compare changes
  • Side-by-side
  • Inline
@@ -400,6 +400,18 @@ void declare_LSTMOp(py::module &m) {
)mydelimiter");
}
void declare_LeakyResetEnum(py::module &m) {
py::enum_<LeakyReset>(m, "leaky_reset", R"doc(
Enumeration for the Leaky neuron reset mode.
Subtraction: Membrane potential is subtracted by threshold upon spiking.
ToZero : Membrane potential is forced to 0 upon spiking.
)doc")
.value("subtraction", LeakyReset::Subtraction)
.value("to_zero", LeakyReset::ToZero)
.export_values();
}
void declare_LeakyOp(py::module &m) {
m.def("Leaky", &Leaky,
@@ -441,6 +453,7 @@ void init_MetaOperatorDefs(py::module &m) {
declare_PaddedMaxPoolingOp<2>(m);
// declare_PaddedMaxPoolingOp<3>(m);
declare_LSTMOp(m);
declare_LeakyResetEnum(m);
declare_LeakyOp(m);
py::class_<MetaOperator_Op, std::shared_ptr<MetaOperator_Op>, OperatorTensor>(m, "MetaOperatorOp", py::multiple_inheritance())
Loading