# Event based version of rate based homeostasis

**URL:** https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176
**Category:** Science, Projects, and Showcases
**Created:** [5 October 2020 14:36 UTC](https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176 "2020-10-05T14:36:36Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![schmitts](https://yyz2.discourse-cdn.com/free1/user_avatar/brian.discourse.group/schmitts/32/191_2.png) [@schmitts](https://brian.discourse.group/u/schmitts)
#### Post date: [5 October 2020 14:36 UTC](https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176/1 "2020-10-05T14:36:37Z")

</div>

Hi!

Cf. [https://github.com/brian-team/brian2/issues/1241;](https://github.com/brian-team/brian2/issues/1241;) does anybody know about comparisons of event based versions of rate based homeostasis?

Thanks,

Sebastian

---

<div class="post-metadata">

### Author: ![kernfel](https://yyz2.discourse-cdn.com/free1/user_avatar/brian.discourse.group/kernfel/32/15_2.png) [@kernfel](https://brian.discourse.group/u/kernfel)
#### Post date: [6 October 2020 02:05 UTC](https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176/2 "2020-10-06T02:05:20Z")

</div>

I have nothing to add myself, I just want to avoid your question falling to the wayside due to the broken link. Thus, for completeness:  
[Fixed link to the issue](https://github.com/brian-team/brian2/issues/1241)

> [@schmitts](#):
>
> Hi!
> 
> I’m looking for an example for homeostatic plasticity to stabilize firing rates. Is there a notion for firing rates available that can be used to formulate a weight update rule?
> 
> Thanks,
> 
> Sebastian

> [@mstimberg](#):
>
> In spiking networks, there is no direct firing rate variable that is available. What you’d typically do is to use a variable that increases with each spike (via the `reset` statement) and decays over time. Another option is to low-pass filter the membrane potential and to use this as a proxy for the firing rate (see e.g. the [Clopath et al. (2010) example](https://brian2.readthedocs.io/en/stable/examples/frompapers.Clopath_et_al_2010_homeostasis.html)).

---

<div class="post-metadata">

### Author: ![schmitts](https://yyz2.discourse-cdn.com/free1/user_avatar/brian.discourse.group/schmitts/32/191_2.png) [@schmitts](https://brian.discourse.group/u/schmitts)
#### Post date: [6 October 2020 06:21 UTC](https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176/3 "2020-10-06T06:21:00Z")

</div>

Thanks for the heads up!

---

<div class="post-metadata">

### Author: ![mstimberg](https://yyz2.discourse-cdn.com/free1/user_avatar/brian.discourse.group/mstimberg/32/11_2.png) [@mstimberg](https://brian.discourse.group/u/mstimberg)
#### Post date: [8 October 2020 15:20 UTC](https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176/4 "2020-10-08T15:20:58Z")

</div>

Hi again. Not sure this is exactly what you are looking for, but [Zenke et al. (2013)](https://journals.plos.org/ploscompbiol/article?id=10.1371/journal.pcbi.1003330) implemented a homoeostatic mechanism with spikes that calculates the firing rate as a low-pass filtered version of the spike rate, like I mentioned in the github issue.

---

<div class="post-metadata">

### Author: ![schmitts](https://yyz2.discourse-cdn.com/free1/user_avatar/brian.discourse.group/schmitts/32/191_2.png) [@schmitts](https://brian.discourse.group/u/schmitts)
#### Post date: [2 August 2021 11:45 UTC](https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176/5 "2021-08-02T11:45:03Z")

</div>

Hi!

I’ve put together an example for spike (event) based homeostasis: [Add example for spike based homeostasis by schmitts · Pull Request #1331 · brian-team/brian2 · GitHub](https://github.com/brian-team/brian2/pull/1331)

Cheers,

Sebastian

---

<div class="post-metadata">

### Author: ![schmitts](https://yyz2.discourse-cdn.com/free1/user_avatar/brian.discourse.group/schmitts/32/191_2.png) [@schmitts](https://brian.discourse.group/u/schmitts)
#### Post date: [8 September 2021 06:24 UTC](https://brian.discourse.group/t/event-based-version-of-rate-based-homeostasis/176/6 "2021-09-08T06:24:37Z")

</div>

It got merged, thanks! [Example: spike\_based\_homeostasis — Brian 2 2.4.2.post0.dev296 documentation](https://brian2.readthedocs.io/en/latest/examples/synapses.spike_based_homeostasis.html)
