Memristor networks for real-time neural activity analysis