Baidu built an A.I. that predicts dangerous crowds and stampedes