光學樂譜辨識(OMR)是一種將印刷樂譜透過掃描方式,辨識樂譜中的符號、音階和拍子,並可轉換成一種音樂格式(如MIDI)。由於掃描樂譜會有傾斜、顛倒及許多雜訊的影響,因此,將其轉化成音樂格式是具有挑戰性的。本系統中,我們將樂譜掃描影像命名為Mimage,由於M-image 會有傾斜或顛倒的情況,我們提出有效的方法來校正可將其調整為正常(非傾斜或顛倒)的M-image。接著,我們將校正後的樂譜進行五線譜偵測與濾除,將符號定位出來。一般樂譜中,包括臨時記號、譜號、休止符及音符,而音符中又包含連音與非連音。因此,我們辨識方法是透過樣板比對,再加上使用符號的位置、符號關係特性,偵測出樂譜中符號、音階與拍子。在我們實驗中,樂譜辨識率能達到97%,證實我們提出方法是有效且可行的。
Optical Music Recognition (OMR) usually needs some required steps on a scanned image including image segmentation and recognition of symbols, scales, and beats. Its application is often applied for the automatic MIDI play, which is helpful for human learning some songs. The M-image is named in this thesis to represent a printed music score. Some difficulties may occur in OMR due to the effects of skewed, inverted, noise embedded for a M-image. It is therefore our goal to propose an effective approach to overcome these difficulties. First, a skewed or inverted M-image is corrected. Second,the removal of noise is performed and staff lines are detected. Third, music symbols including accidentals, clefs, rest, notes, etc are recognized.Because the notes may be legato or non-legato, a template matching algorithm combined with symbol position and relationship is adopted for identifying symbols, scales and beats. Final, a MIDI grammar used in ABC Music is adopted for creating a MIDI file to confirm our algorithms. Experiments with 35 M-images obtained 97% recognition rate confirm the feasibility of our approach.