Data-driven deep learning algorithms for time-varying infection rates of COVID-19 and mitigation measures