We propose a method of music melody matching based on their “continuous” (or “time-frame-based”) pitch contours. Most previous methods using frame-based contours either made limiting assumptions on the locations, musical scale, tempo, and/or rhythm of the queries in relations to the targets, or involved exhaustive dynamic time-warping procedures that were too computation-intensive for use in real scenarios. In the proposed method, variable-scale windowing and wavelet transformations are performed at an initial coarse search stage to efficiently match queries to targets. At the following fine search stage, we apply a novel segmented dynamic time warping (DTW) method for melody contours, computing a more accurate distance between the query and each of the candidate targets with less computation than traditional DTW. The method searches arbitrary target locations and explicitly adjusts for differences in tempo and musical scale between queries and targets as well as rhythmic in...