a shortest path approach for staff line detection