You need to agree to share your contact information to access this dataset

This repository is publicly accessible, but you have to accept the conditions to access its files and content.

Log in or Sign Up to review the conditions and access this dataset content.

⚠️ Work in Progress! SMB: A Multi-Texture Sheet Music Recognition Benchmark ⚠️

Overview

SMB (Sheet Music Benchmark) is a dataset of printed Common Western Modern Notation scores developed at the University of Alicante at the Pattern Recognition and Artificial Intelligence Group.

Dataset Details

  • Image Format: PNG
  • Encoding Formats: RAW Humdrum **kern, **ekern (standarized **kern version)
  • Annotations:
    • Segmentation: Bounding boxes
    • Music encoding (system-level and full-page): Humdrum **kern
  • Use Cases:
    • Optical Music Recognition (OMR): system-level, full-page
    • Image Segmentation: music regions

SMB usage 📖

SMB is publicly available at HuggingFace.

To download from HuggingFace:

  1. Gain access to the dataset and get your HF access token from: https://huggingface.co/settings/tokens.
  2. Install dependencies and login HF:
    • Install Python
    • Run pip install pillow datasets huggingface_hub[cli]
    • Login by huggingface-cli login and paste the HF access token. Check here for details.
  3. Use the following code to load SMB and extract the regions:
from datasets import load_dataset
from PIL import Image, ImageDraw

ds = load_dataset("PRAIG/SMB")

# First image of the train split
data = ds["train"][0]
image = data["image"]

# Create a drawing context
draw = ImageDraw.Draw(image)

for reg in data["regions"]:
    value = reg["bbox"]

    # Calculate positions and dimensions
    box_x = value["x"] / 100 * data["original_width"]
    box_y = value["y"] / 100 * data["original_height"]
    box_width = value["width"] / 100 * data["original_width"]
    box_height = value["height"] / 100 * data["original_height"]

    # Calculate the corners of the box
    top_left = (box_x, box_y)
    top_right = (box_x + box_width, box_y)
    bottom_left = (box_x, box_y + box_height)
    bottom_right = (box_x + box_width, box_y + box_height)

    # Draw the box
    draw.rectangle([top_left, bottom_right], width=3)

# Save the image with boxes
image.save("image.png")

Citation

If you use our work, please cite us:

@preprint{MartinezSevillaPRAIG24,
  author = {Juan C. Martinez{-}Sevilla and
            Noelia Luna{-}Barahona and
            Joan Cerveto{-}Serrano and
            Antonio Rios{-}Vila and
            David Rizo and
            Jorge Calvo{-}Zaragoza},
  title = {A Multi{-}Texture Sheet Music Recognition Benchmark},
  year = {2024}
}
Downloads last month
66