Distributed Neural Computation over WSN in Ambient Intelligence