ms3


Namems3 JSON
Version 2.4.4 PyPI version JSON
download
home_pagehttps://github.com/johentsch/ms3
SummaryA parser for MuseScore files, serving as data factory for annotated music corpora.
upload_time2024-01-22 04:25:34
maintainer
docs_urlNone
authorJohannes Hentschel
requires_python>=3.10
licenseGPL-3.0-only
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage
            |license| |version| |release|  |size|

.. |license| image:: https://img.shields.io/github/license/johentsch/ms3?color=%230000ff
    :alt: GitHub

.. |release| image:: https://img.shields.io/github/release-date/johentsch/ms3
    :alt: GitHub Release Date

.. |size| image:: https://img.shields.io/github/repo-size/johentsch/ms3
    :alt: GitHub repo size

.. .. |tests| image:: https://img.shields.io/github/workflow/status/johentsch/ms3/run_tests/main?label=tests
    :alt: GitHub Workflow Status (branch)

.. |version| image:: https://img.shields.io/pypi/v/ms3?color=%2300
    :alt: PyPI

.. These are examples of badges you might want to add to your README:
   please update the URLs accordingly

    .. image:: https://readthedocs.org/projects/ms3/badge/?version=latest
        :alt: ReadTheDocs
        :target: https://ms3.readthedocs.io/en/stable/
    .. image:: https://img.shields.io/coveralls/github/<USER>/ms3/main.svg
        :alt: Coveralls
        :target: https://coveralls.io/r/<USER>/ms3
    .. image:: https://img.shields.io/pypi/v/ms3.svg
        :alt: PyPI-Server
        :target: https://pypi.org/project/ms3/
    .. image:: https://pepy.tech/badge/ms3/month
        :alt: Monthly Downloads
        :target: https://pepy.tech/project/ms3


===============================
ms3 - Parsing MuseScore 3 and 4
===============================

..
    Plan to use
    .. include:: ./docs/intro.rst
    failed because of PyPi


Welcome to **ms3**, a Python library for parsing `MuseScore <https://musescore.org/en/download>`__ files.

Statement of need
=================

Here comes a list of functionalities to help you decide if this library could be useful for you.

* parses MuseScore 3 and 4 files, dispensing with lossy conversion to musicXML. The file formats in question are

  * uncompressed ``*.mscx`` files,
  * compressed ``*.mscz`` files,

* extracts and processes the information contained in one or many scores in the form of
  `DataFrames <https://pandas.pydata.org/pandas-docs/stable/user_guide/dsintro.html#dataframe>`__:

  * **notes** (start, duration, pitch etc.) and/or rests,
  * **measures** (time signature, lengths, repeat structure etc.)
  * **labels**, such as

    * guitar/Jazz chord labels
    * arbitrary annotation labels
    * **expanded** harmony labels following the `DCML annotation standard <https://github.com/DCMLab/standards>`__
    * **cadences** (part of the same annotation syntax)
    * **form_labels** (annotation standard currently in press)

  * **chords**, that is, onset positions that have musical markup attached, e.g. dynamics, lyrics, slurs, 8va signs...
  * **metadata** from the respective fields, but also score statistics, such as length, number of notes, etc.

* stores the extracted information in a uniform and interoperable tabular format (``*.tsv``)
* writes information from tabular ``*.tsv`` files into MuseScore files, especially

  * chord and annotation labels
  * metadata
  * header information (title, subtitle, etc.)
  * note coloring

* uses a locally installed or standalone MuseScore executable for

  * batch-converting files to any output format supported by MuseScore (mscz, mscx, mp3, midi, pdf etc.)
  * on-the-fly converting any file that MuseScore can read (including MuseScore 2, cap, capx, midi, and musicxml) to parse it

* offers its functionality via the convenient ``ms3`` commandline interface.

View the `full documentation here <https://ms3.readthedocs.io/>`__.

For a demo video (using an old, pre-1.0.0 version) on YouTube, `click here <https://youtu.be/UBY3wuIS4wc>`__

Installation
============

ms3 requires Python >= 3.10 (type ``python3 --version`` to check). Once you have switched to a virtual environment
that has Python 3.10 installed you can pip-install the library via one of the two commands::

    python3 -m pip install ms3
    pip install ms3

If successful, the installation will make the ``ms3`` commands available in your PATH (try by typing ``ms3``).

Quick demo
==========

Parsing a single score
----------------------

.. code-block:: python

    import ms3
    score = ms3.Score('musescore_file.mscz')

Parsing a corpus
----------------

.. code-block:: python

    import ms3
    corpus = ms3.Corpus('score_directory')
    corpus.parse()

Parsing several corpora
-----------------------

.. code-block:: python

    import ms3
    corpora = ms3.Parse('my_research_corpora')
    corpora.parse()


.. _pyscaffold-notes:

Making Changes & Contributing
=============================

This project uses `pre-commit <https://pre-commit.com/>`__ to ensure code quality. If you are a developer,
please make sure to install it before making any changes::

    cd ms3
    pip install -e ".[dev]" # includes "pip install pre-commit"
    pre-commit install


Acknowledgements
================

Development of this software tool was supported by the Swiss National Science Foundation within the project “Distant
Listening – The Development of Harmony over Three Centuries (1700–2000)” (Grant no. 182811). This project is being
conducted at the Latour Chair in Digital and Cognitive Musicology, generously funded by Mr. Claude Latour.

.. image:: https://img.shields.io/badge/-PyScaffold-005CA0?logo=pyscaffold
    :alt: Project generated with PyScaffold
    :target: https://pyscaffold.org/

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/johentsch/ms3",
    "name": "ms3",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": "",
    "keywords": "",
    "author": "Johannes Hentschel",
    "author_email": "johannes.hentschel@epfl.ch",
    "download_url": "https://files.pythonhosted.org/packages/7a/0a/9214387c2f0bea0bb1529876fdc309390d70328bc490b5e8fd4929193e66/ms3-2.4.4.tar.gz",
    "platform": "any",
    "description": "|license| |version| |release|  |size|\n\n.. |license| image:: https://img.shields.io/github/license/johentsch/ms3?color=%230000ff\n    :alt: GitHub\n\n.. |release| image:: https://img.shields.io/github/release-date/johentsch/ms3\n    :alt: GitHub Release Date\n\n.. |size| image:: https://img.shields.io/github/repo-size/johentsch/ms3\n    :alt: GitHub repo size\n\n.. .. |tests| image:: https://img.shields.io/github/workflow/status/johentsch/ms3/run_tests/main?label=tests\n    :alt: GitHub Workflow Status (branch)\n\n.. |version| image:: https://img.shields.io/pypi/v/ms3?color=%2300\n    :alt: PyPI\n\n.. These are examples of badges you might want to add to your README:\n   please update the URLs accordingly\n\n    .. image:: https://readthedocs.org/projects/ms3/badge/?version=latest\n        :alt: ReadTheDocs\n        :target: https://ms3.readthedocs.io/en/stable/\n    .. image:: https://img.shields.io/coveralls/github/<USER>/ms3/main.svg\n        :alt: Coveralls\n        :target: https://coveralls.io/r/<USER>/ms3\n    .. image:: https://img.shields.io/pypi/v/ms3.svg\n        :alt: PyPI-Server\n        :target: https://pypi.org/project/ms3/\n    .. image:: https://pepy.tech/badge/ms3/month\n        :alt: Monthly Downloads\n        :target: https://pepy.tech/project/ms3\n\n\n===============================\nms3 - Parsing MuseScore 3 and 4\n===============================\n\n..\n    Plan to use\n    .. include:: ./docs/intro.rst\n    failed because of PyPi\n\n\nWelcome to **ms3**, a Python library for parsing `MuseScore <https://musescore.org/en/download>`__ files.\n\nStatement of need\n=================\n\nHere comes a list of functionalities to help you decide if this library could be useful for you.\n\n* parses MuseScore 3 and 4 files, dispensing with lossy conversion to musicXML. The file formats in question are\n\n  * uncompressed ``*.mscx`` files,\n  * compressed ``*.mscz`` files,\n\n* extracts and processes the information contained in one or many scores in the form of\n  `DataFrames <https://pandas.pydata.org/pandas-docs/stable/user_guide/dsintro.html#dataframe>`__:\n\n  * **notes** (start, duration, pitch etc.) and/or rests,\n  * **measures** (time signature, lengths, repeat structure etc.)\n  * **labels**, such as\n\n    * guitar/Jazz chord labels\n    * arbitrary annotation labels\n    * **expanded** harmony labels following the `DCML annotation standard <https://github.com/DCMLab/standards>`__\n    * **cadences** (part of the same annotation syntax)\n    * **form_labels** (annotation standard currently in press)\n\n  * **chords**, that is, onset positions that have musical markup attached, e.g. dynamics, lyrics, slurs, 8va signs...\n  * **metadata** from the respective fields, but also score statistics, such as length, number of notes, etc.\n\n* stores the extracted information in a uniform and interoperable tabular format (``*.tsv``)\n* writes information from tabular ``*.tsv`` files into MuseScore files, especially\n\n  * chord and annotation labels\n  * metadata\n  * header information (title, subtitle, etc.)\n  * note coloring\n\n* uses a locally installed or standalone MuseScore executable for\n\n  * batch-converting files to any output format supported by MuseScore (mscz, mscx, mp3, midi, pdf etc.)\n  * on-the-fly converting any file that MuseScore can read (including MuseScore 2, cap, capx, midi, and musicxml) to parse it\n\n* offers its functionality via the convenient ``ms3`` commandline interface.\n\nView the `full documentation here <https://ms3.readthedocs.io/>`__.\n\nFor a demo video (using an old, pre-1.0.0 version) on YouTube, `click here <https://youtu.be/UBY3wuIS4wc>`__\n\nInstallation\n============\n\nms3 requires Python >= 3.10 (type ``python3 --version`` to check). Once you have switched to a virtual environment\nthat has Python 3.10 installed you can pip-install the library via one of the two commands::\n\n    python3 -m pip install ms3\n    pip install ms3\n\nIf successful, the installation will make the ``ms3`` commands available in your PATH (try by typing ``ms3``).\n\nQuick demo\n==========\n\nParsing a single score\n----------------------\n\n.. code-block:: python\n\n    import ms3\n    score = ms3.Score('musescore_file.mscz')\n\nParsing a corpus\n----------------\n\n.. code-block:: python\n\n    import ms3\n    corpus = ms3.Corpus('score_directory')\n    corpus.parse()\n\nParsing several corpora\n-----------------------\n\n.. code-block:: python\n\n    import ms3\n    corpora = ms3.Parse('my_research_corpora')\n    corpora.parse()\n\n\n.. _pyscaffold-notes:\n\nMaking Changes & Contributing\n=============================\n\nThis project uses `pre-commit <https://pre-commit.com/>`__ to ensure code quality. If you are a developer,\nplease make sure to install it before making any changes::\n\n    cd ms3\n    pip install -e \".[dev]\" # includes \"pip install pre-commit\"\n    pre-commit install\n\n\nAcknowledgements\n================\n\nDevelopment of this software tool was supported by the Swiss National Science Foundation within the project \u201cDistant\nListening \u2013 The Development of Harmony over Three Centuries (1700\u20132000)\u201d (Grant no. 182811). This project is being\nconducted at the Latour Chair in Digital and Cognitive Musicology, generously funded by Mr. Claude Latour.\n\n.. image:: https://img.shields.io/badge/-PyScaffold-005CA0?logo=pyscaffold\n    :alt: Project generated with PyScaffold\n    :target: https://pyscaffold.org/\n",
    "bugtrack_url": null,
    "license": "GPL-3.0-only",
    "summary": "A parser for MuseScore files, serving as data factory for annotated music corpora.",
    "version": "2.4.4",
    "project_urls": {
        "Documentation": "https://ms3.readthedocs.io/",
        "Homepage": "https://github.com/johentsch/ms3"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7c4c5575e283d406deed44013315df64e4be55897db56d11b36aeb023509d879",
                "md5": "64525c49be1cb9d87b54c4d72d38891e",
                "sha256": "ded4b9678072ced726e9e4573c87a6f4858f946307553653f5a3c520743bdd1b"
            },
            "downloads": -1,
            "filename": "ms3-2.4.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "64525c49be1cb9d87b54c4d72d38891e",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 341819,
            "upload_time": "2024-01-22T04:25:31",
            "upload_time_iso_8601": "2024-01-22T04:25:31.495314Z",
            "url": "https://files.pythonhosted.org/packages/7c/4c/5575e283d406deed44013315df64e4be55897db56d11b36aeb023509d879/ms3-2.4.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7a0a9214387c2f0bea0bb1529876fdc309390d70328bc490b5e8fd4929193e66",
                "md5": "e25e7ae2f1de4a9aa29a0473a1b0ea29",
                "sha256": "c06fe0305641e3cb691c96b9bdfd5be0e6cb6004ecb7257b3b1de27d75241621"
            },
            "downloads": -1,
            "filename": "ms3-2.4.4.tar.gz",
            "has_sig": false,
            "md5_digest": "e25e7ae2f1de4a9aa29a0473a1b0ea29",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 10002750,
            "upload_time": "2024-01-22T04:25:34",
            "upload_time_iso_8601": "2024-01-22T04:25:34.774910Z",
            "url": "https://files.pythonhosted.org/packages/7a/0a/9214387c2f0bea0bb1529876fdc309390d70328bc490b5e8fd4929193e66/ms3-2.4.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-22 04:25:34",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "johentsch",
    "github_project": "ms3",
    "travis_ci": false,
    "coveralls": true,
    "github_actions": true,
    "tox": true,
    "lcname": "ms3"
}
        
Elapsed time: 0.18707s