A C++/Python library to manipulate sheet music data
Project description
Maialib - Music Analysis Library {#mainpage}
This library is a multiplatform set of musical tools that enable musical score analisys and composition in a easy and fast way.
The project core was wrote in C++17
, but it also has a Python
wrapper that allows a greater number of people (ie musicians not trained in IT) to also have in their hands the same power and musical tools available in maialib
.
Advantages
- Easy to use to musicians and musical researchers
- High computer perfomance and fast calculations
- Read and write musical scores (MusicXML file format)
Get Python Package
pip install maialib
Or, if you have a older maialib
version installed on your system, please get the latest version running: pip install maialib --upgrade
Get Started
You can easily import your sheet music (*.xml
file) to Python environment using:
import maialib as ml
myScore = ml.Score('./Beethoven/Symphony_9th.xml')
Now you can explore some maialib
features like:
- Find musical patterns
- Write your own scores from your custom algorithms
- Analyse scores in a musical statistical data perspective
- And much more!
Frequent Asked Questions
1) Where can I find the XML file of a specific musical score?
To import musical scores the file extensions must be: *.xml
, *.mxl
or *.musicxml
You can easily export your music files to these file formats above from score editors, like:
- MuseScore (free!)
- Sibelius
- Finale
- Others
Many MusicXML
files are avaliable for free in the internet for download.
2) What can I do if I don't have a *.xml
file of my target music?
- First, make shure and look at different websites and online repositories trying to find the
*.xml
file - You can find on the internet the desired MIDI file and import it in a score editor (like MuseScore, Sibelius, Finale, etc.) and then export the
MusicXML
file from it - You can use scan the sheet music paper and get a PDF version of it, so:
- You can use a OMR software to try to convert the PDF file into a
*.xml
file - You can pay for other people to type manually note-by-note the PDF into a musical software (link MuseScore, Sibelius, Finale, etc.)
- You can use a OMR software to try to convert the PDF file into a
- You can type manually note-by-note the music paper into a musical software (link MuseScore, Sibelius, Finale, etc.)
Documentation (in development)
This project have 2 documentation levels. One for each user type:
- Level 1 - User documentation: for musicians, musical researchers and non-professional IT people (help me to do that!)
- Level 2 - Developer documentation: A deeper information for professional C++ programmers (Doxygen)
Level 1: Python Tutorial
You can explore maialib
features looking at python-tutorial
folder (link here).
There you will learn how to use and mix maialib
classes and functions to reach your musical goals
If you are starting, please check these 3 basic maialib
Python tutorials:
Level 2: Developer Documentation
Would you like to improve any maialib function?
Are you a C++ developer?
Requirements to build from C++ sources:
- C++17 compatible compiler
- CMake 3.26
- Python 3.8
- Make
- Doxygen (Optional: To build documentation)
- Buildcache (Optional: To accelerate the build process)
- CppCheck (Optional: C++ Static Analyzer)
Are you a Python developer?
Python Dev-only dependencies
pip install pathlib
pip install cpplint
pip install wheel
pip install mypy
# To generate Python stubs
pip install pybind11-stubgen
# Mac users: May be you have to add the coverage and pybind11-stubgen on your `PATH` - /etc/paths
pybind11_mkdoc (github)
sudo apt install clang (pybind11_mkdoc dependency) - Linux/Mac Only
Tested Environments
Operational System | Compilers |
---|---|
Windows 10 x64 | Clang 15.0 (MSYS2) |
Linux Ubuntu 20.04 | GCC 9.3 |
Apple OSX 10.15 | XCode 11.5 (Command Line Tools) |
Quick Start
Build Python module from C++ source
Open a terminal (or CMD in Windows), enter inside of the maialib
folder.
Type: make
to build the Python module
When the build process finishes, type: make install
Done!
Known issues to build from source
All Platforms
- Multiple Python versions installed, like:
Official Python
,Microsoft Python
,MSYS2 Python
and others can direct the build system to choose a wrong version to build and install the library.
To check all Python versions installed on your system, open theTerminal
(orCMD
on Windows) and type: - Linux or Mac: -which python
-which python3
- Windows: -where.exe python
-where.exe python3
Windows-Only
- Disable your antivirus or create a exception (CMake permissions)
Contact
Nycholas Maia - nyckmaia@gmail.com
Contributing
- Fork this project
- Make your custumizations and improvments
- Please, send me a pull request
License
Maialib is licensed under GPLv3 License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for maialib-1.4.6-pp310-pypy310_pp73-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3c12f76406d533770760cd32fd667ab87a6b3fffd3f8f18cce615fdb3a97b591 |
|
MD5 | 5d47bcee979aa3b61afaf3c623c8167d |
|
BLAKE2b-256 | 922b79d10942c90c099ae6a403a4f626f51a21ae33a27375da1c8fa7c3f7fdb6 |
Hashes for maialib-1.4.6-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 922c681d5b9f1f26d5c9c2a869177e4b65f41197851bf89152af9a061a036c8a |
|
MD5 | b4decec94e559f60125978a1398158d6 |
|
BLAKE2b-256 | c31e0fc1b9bd394ac0128b98304db73619c93b69468981931c4aed3c6dff1bb0 |
Hashes for maialib-1.4.6-pp310-pypy310_pp73-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1cb4c4e7d4d4332208e90d471095f5ec4fe267a2405623eddb606efe65d3e12e |
|
MD5 | 7aa80b9c6b50a7c00d0234e227959d12 |
|
BLAKE2b-256 | 7cd160c00ff23da30b81099540ed7036cb0191bae0fd54f7e4541d5ebf95ceb2 |
Hashes for maialib-1.4.6-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ed42a81b3fe111f3b30c1e79071bb99255cf211484e647c45b4e32621a145f4c |
|
MD5 | c4ec1c9a5ff480d52e8ad7a9211ad32c |
|
BLAKE2b-256 | 20e96d3ceca407d14f31b8b201454d1e0e9eeaaddbc089bcc007558158558d9e |
Hashes for maialib-1.4.6-pp39-pypy39_pp73-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ed585cad3dd27352335552c0f40f9cd9aef4a6b868754afbe02d2a705fb88a18 |
|
MD5 | 3bc603398b8fad289aedd186a3348153 |
|
BLAKE2b-256 | e93b8c283edb667dcb41abee3eb0d851672017ff265589ebe1a47e7fd7633fd0 |
Hashes for maialib-1.4.6-pp38-pypy38_pp73-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | cd394d4be14a8e7701c8ed061488712ed10a40b88cee09a0df02646f52cca9f6 |
|
MD5 | 319ca57a7d846c1489a0e96a734a5386 |
|
BLAKE2b-256 | 88c808b819896ca9d7a4ce4e3788041e90f380109c39a02ad15830e958205151 |
Hashes for maialib-1.4.6-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 981c7047fe0929b7e518aca55436d35fb7f400efaca9ba0a32425f9be30c731c |
|
MD5 | 936a0fccbad1a043dda96ad22a8a9a39 |
|
BLAKE2b-256 | 25e05e766b71c61268c801f73729727e4c313f5425e4599c6db12d668e4cf02a |
Hashes for maialib-1.4.6-pp38-pypy38_pp73-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 683b1334969383816aa3289d09b7747ad5ac0fdf55937176d0bb475ec6d8edb5 |
|
MD5 | e99c562ab0cafaec55ce993f040fd761 |
|
BLAKE2b-256 | 723237b3f3cd7437adfd347659a1e63097ae35b546d680a3efd2aa70e18c1043 |
Hashes for maialib-1.4.6-cp312-cp312-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 569c172a0575f015c30f72034400ae64db1038529b201eef09196784b9657f5c |
|
MD5 | ec5a211b67e799ca3f8b211dcd618c28 |
|
BLAKE2b-256 | 531ca5477aafbcc3817acb574c089bfc61ac8a9396a7e82cca98f48bc31d532e |
Hashes for maialib-1.4.6-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd898923c250259edbf8b6b686fd36e0dc0fcf7f15e66aa193cbfba2ce5d0752 |
|
MD5 | da3b89f071628209171971ac697c1647 |
|
BLAKE2b-256 | 1f14295a9736ec57489c793e1093d41f1d85be9907f385f8514d958303323dae |
Hashes for maialib-1.4.6-cp312-cp312-musllinux_1_2_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 797ae5ab4eeb87e77a48fa2edb45acc1f0cb49130a1dc2af5b88628eb7b04f3b |
|
MD5 | 316c7cf8a546f3e2c4d8af47aa401b03 |
|
BLAKE2b-256 | 42c3cfa56ab741ee7cffbbb50749314a1446d458123cf1d55e30628995b7c138 |
Hashes for maialib-1.4.6-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 70fa52c4feb30c98829ee977eeedfa6c7afb10f930c9fc294ab22037854d57c1 |
|
MD5 | 3567733db36fcf3cbd45a30d986e7b25 |
|
BLAKE2b-256 | e20929d041d1fdca4ce30b96bf3f64fe2ddcee47d14bc2625125c00c7939ccd0 |
Hashes for maialib-1.4.6-cp312-cp312-macosx_11_0_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98e356ac066e129d65abd09e220a0f516b5a97382bfc9b4c92b08c0946d954f2 |
|
MD5 | 509845e9415d4d32a8c9a8deda538f41 |
|
BLAKE2b-256 | f31df1ce4ddf3a589e1ce1ca992d8e6405ed3a8b4e25d59a8bd199bd16628ca8 |
Hashes for maialib-1.4.6-cp312-cp312-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0a5a5a016c58218404aef216fb6c92c05adea743af72eb8bb71cd734d6b27ab2 |
|
MD5 | 9ff40edf2b66297d160f2c9cf487283d |
|
BLAKE2b-256 | 47fad5d78deb001096f7438d43556e66abfefb7b25d0f13dd1d42025463d2afa |
Hashes for maialib-1.4.6-cp311-cp311-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1369d4819a00ecc44fb8c1458339f9d45c1ffb1dac4ed8958f23a7998ff89731 |
|
MD5 | 722f1cfaa8a5dc12c8c79d2a6cca827b |
|
BLAKE2b-256 | ed0481abdf34c3df072280f92023480bb045affb6ca6fcc20941fbe96a38ef0c |
Hashes for maialib-1.4.6-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 819efee39116cee2f9285bb83f8e834a67cfcf5016a55a511374d6ac183e4175 |
|
MD5 | 56cc666a54a0b470bc667150b2bbc5fb |
|
BLAKE2b-256 | 0ce1108e916723974339adadc210e722ca170a9263f1cbeecb1c5673099bb36f |
Hashes for maialib-1.4.6-cp311-cp311-musllinux_1_2_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c4f210faa51ac06b04811dd8ffd6ec054385b455ca4146e1cd29c505f1220c5a |
|
MD5 | 4abecf7548036dfdd3d7859115ba312a |
|
BLAKE2b-256 | f2b6e195384804274c4c790253af1bda66df66b969a4fd6f05d6f0ecbd82a82f |
Hashes for maialib-1.4.6-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 64aa9b250b2955630962eb496fc1fe633fc9a3d797a5b00dcb42088039130a62 |
|
MD5 | ddd041df286f4fc0b186f856b3828038 |
|
BLAKE2b-256 | ac792c54a7d1bd84b77d8d1215a8c7b67a3ce9ad086d32ec97e3218fa814d418 |
Hashes for maialib-1.4.6-cp311-cp311-macosx_11_0_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8efd779d9dcad13f64aa48ae88d81dea8de447b2ea9fb2873e63036889d037e7 |
|
MD5 | efbf9fe16f24bec3da4ba35ca6dc12ef |
|
BLAKE2b-256 | 76aa13750627a25793cc5d3937ed030b7159591e08154a33da723ae2e4644128 |
Hashes for maialib-1.4.6-cp311-cp311-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f7a10e0ec2a3e186be2a9951048fd5a56c11492fe33fba150a90cef0da4bb453 |
|
MD5 | 9082def070fd4db3fa89e72ef64beee2 |
|
BLAKE2b-256 | 1682289085e32496a1df3fb90d76b545efde2b642d9198dd449e7618cf3b280a |
Hashes for maialib-1.4.6-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e35621ec96ad7a2487ed7c78ab7919cfe51679d71ceda8da4ecc1bb512df84c5 |
|
MD5 | eca3d4b2d18104740b9f01326b2f07e8 |
|
BLAKE2b-256 | a21ee859b0aefc3faf2d2dd27532a7c1e859efe20eb2c914deaf77d5ed25c1e4 |
Hashes for maialib-1.4.6-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c2a9e56f18aaf62f19c0c87389e4fb59b53fc16ee3afdff388a5ce230fe7f969 |
|
MD5 | b9f8bce14cdb1a98cf03d34c7676f6e7 |
|
BLAKE2b-256 | 21000be5127b347f15feea6438cbe852a7a158b06df13be9615674ef2996f9d0 |
Hashes for maialib-1.4.6-cp310-cp310-musllinux_1_2_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 81b60af4109f9491746d28bb980aa01a9c551a8628fed6ca8e7c73f0aa8e73c8 |
|
MD5 | 86d68cc69970628529efa15212ecc3c3 |
|
BLAKE2b-256 | 8a7badb917add97ac3d354e4c002e7a19ac0f0a6511075af423ee48ee3f2c697 |
Hashes for maialib-1.4.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9c04621c4462650eb2b04d53c103f8392534296bcc06bdaeabbd6a343fee27ec |
|
MD5 | da2bebf7f8c3c6189a03e0a51cb18dfc |
|
BLAKE2b-256 | a4134a940003d2ab1628dfeafeb5c7361ea4c4eef96fbfc48bd3c885c2a08525 |
Hashes for maialib-1.4.6-cp310-cp310-macosx_11_0_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | baf56637b280847dd263343c54ae740e53d4fb03a350c6810a1169832647ea63 |
|
MD5 | 6ba393f789f2f6d6cfa936755f0cb828 |
|
BLAKE2b-256 | a86a7114fba9bf057016d41cd50ea31dad119bbb5e134844bd3be4f67224e4e8 |
Hashes for maialib-1.4.6-cp310-cp310-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc2e8eb02acf7fc6c17e741c65b675ee38ff06527358ea54101671bb230080f9 |
|
MD5 | 7d8da0a6a4b9ac4e5a35a87b008f4475 |
|
BLAKE2b-256 | 6a0a13ee8b5954e4ff9f3354714287dd736e2fe273d8a434403c8d16f125a3b5 |
Hashes for maialib-1.4.6-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | be5d863ea1a7373427d28c9cb9e74267bf31778b709d76a158516f7bbe514c09 |
|
MD5 | 3929f1caa5fc8e0456a81424895f0bc1 |
|
BLAKE2b-256 | 70affde151435023e3caa3b39b7b70e823694e1b71e79a35b953032b695293d4 |
Hashes for maialib-1.4.6-cp39-cp39-musllinux_1_2_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4f6028903165921a4d63c2994bd1e5610eea6a31c1a0eb70518ce7fd4ba59422 |
|
MD5 | fb1803fae1935582fda0cb51ffc7c848 |
|
BLAKE2b-256 | 9ac4555ae09634947ee02466817d2830d844218e30c8b1ffe50fc39f87a87a20 |
Hashes for maialib-1.4.6-cp39-cp39-musllinux_1_2_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4b64337506923bd35e70016155a210b438299ae764006bb65a671e3556e52d1a |
|
MD5 | 59f15b45a424c0f607aa45a22ad8e082 |
|
BLAKE2b-256 | 08d49f203aca3f48ff50497fed20ce1d9c9202b3324bd462f68de2044b71e984 |
Hashes for maialib-1.4.6-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 968c7f60103987f08676f082016dde2cb5b810179f10c10def1a2dd6d8798573 |
|
MD5 | 17393395cbc44e4c1d110ea3718797f2 |
|
BLAKE2b-256 | b0cbe70d13cb802cdc56cb35f22aea91638a5ab73443a73ee2026ef513683ada |
Hashes for maialib-1.4.6-cp39-cp39-macosx_11_0_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4ce92632c9cace7d90089cbae2a5a3edc9440325b93fb1a3aae8de45dfe0a9e3 |
|
MD5 | b48a00e79179a29253ea074d4ddfdb09 |
|
BLAKE2b-256 | 7d1721a51897a4b2c53559f745f874909ce5d472731b972a3f0b86b1dce96698 |
Hashes for maialib-1.4.6-cp39-cp39-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 219d0cde8796b123bd9e7b95accd153dc113f40ed1e8038f259722ae6ab36d8a |
|
MD5 | 8d0105ddb9a8e4fe6420f11629981c41 |
|
BLAKE2b-256 | 0311f8f1e36578981fe910d98b8ed38e211b8975a267c2718171978ba0e23d9e |
Hashes for maialib-1.4.6-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ae7cb01001778abb12e8def06a065edb9d9ae30ecbe0851254bb659c812ea27c |
|
MD5 | f232637609d4282f8b00b3ab8dbfb34d |
|
BLAKE2b-256 | f51b9ab1196aee35dff9980536f41ddb92acd8ebd7046229f1d0cd7afa1374ec |
Hashes for maialib-1.4.6-cp38-cp38-musllinux_1_2_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | cd51040629041ad0c964610f1457bb0ca3a6ace2e71e4089125a3760dcb0e43f |
|
MD5 | 04f6d6dc7686d9d95e32878da86501da |
|
BLAKE2b-256 | eace725687054b48437d3bef8f23e15f498448f0534af41f948d83dcd14b3c66 |
Hashes for maialib-1.4.6-cp38-cp38-musllinux_1_2_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ee2421a809babbdc5c3ba1d64595fbc4ada13346ac55ef551537d6890accd38c |
|
MD5 | 3caa305e200de4faa1358eaaa5d8f49e |
|
BLAKE2b-256 | 05b1bef7d26f0ffd0b1893a06a2b587f5471d2080c7b2d85682014c18a64afa9 |
Hashes for maialib-1.4.6-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c411833f300686c9873a35aa29035a421b7a40b485301c7cc9f89bed8c432c84 |
|
MD5 | 2e8ea43fba7ff0c6afe7138f3a75bad9 |
|
BLAKE2b-256 | 030b9bcc0382a4f3a1e8b4011a3358b8b567a50e8e163d1ff09d00376a5bf7e4 |
Hashes for maialib-1.4.6-cp38-cp38-macosx_11_0_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4d74b1ca2b30c7797c75561a56a6c97d6495cdc612a94294eaac6057e53d03c6 |
|
MD5 | 92902e88dfbe1455f4d467fdabb5bbb4 |
|
BLAKE2b-256 | 594babb53ff80d1ef5ab09558e2f98a7e8c8dfec96fa07ccc962f6aa5fed1480 |
Hashes for maialib-1.4.6-cp38-cp38-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 26afa338d4bef86c7e4948cfdda05b5388fa098808b2b07a571a4fb7c9ba3eb1 |
|
MD5 | a4a66a6888247803ccc1fe01b5548068 |
|
BLAKE2b-256 | b1788997ab6c7a8f9cc93a70782f3c81346f9a0a04e5b66fe2928c2b135777d9 |