A self-adapting approach for the detection of bursts and network bursts in neuronal cultures