Robust Automatic Recognition Of Birdsongs And Human Speech: A Template-Based Approach