Gravar-mail: Template-based Quality Assessment of the Doppler Ultrasound Signal for Fetal Monitoring