./audio/py-music21, Python toolkit for computer-aided musical analysis

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]


Branch: CURRENT, Version: 9.3.0, Package name: py312-music21-9.3.0, Maintainer: gutteridge

A python toolkit for computer-aided musical analysis.

music21 is a set of tools for helping scholars and other active listeners
answer questions about music quickly and simply. If you've ever asked yourself
a question like, "I wonder how often Bach does that" or "I wish I knew which
band was the first to use these chords in this order," or "I'll bet we'd know
more about Renaissance counterpoint (or Indian ragas or post-tonal pitch
structures or the form of minuets) if I could write a program to automatically
write more of them," then music21 can help you with your work.

Note this is the "no corpus" version of the distribution. It does not include
any sample scores, unlike the full version. The "no corpus" distribution was
selected for pkgsrc to avoid any potential concerns about copyrighted content.


Required to run:
[print/lilypond] [graphics/py-matplotlib] [devel/py-game] [devel/py-setuptools] [math/py-scipy] [math/py-numpy] [lang/python37]

Required to build:
[pkgtools/cwrappers]

Package options: py-game

Master sites:

Filesize: 5017.34 KB

Version history: (Expand)


CVS history: (Expand)


   2024-11-07 23:49:08 by David H. Gutteridge | Files touched by this commit (3) | Package updated
Log message:
py-music21: update to 9.3.0

What's Changed

    Add W3C Percussion Drum Sample to Music21 corpus by @kir12 in #1610
    Better errors on pitch creation by @mscuthbert in #1616
    Upgrade flake8 to v6 by @mscuthbert in #1617
    Remove useless Pylint disables by @jacobtylerwalls in #1615
    Mini-optimization to updateEndTimes by @TimFelixBeyer in #1619
    Speed up Duration deepcopy by @TimFelixBeyer in #1620
    Mini-optimization to getElementAtOrBefore by @TimFelixBeyer in #1618
    more speed improvements to getElementAtOrBefore by @mscuthbert in #1622
    speed up sortTuple for streams by @TimFelixBeyer in #1624
    Fix OrderedDict tests on Python 3.12 (stringTools.parenthesesMatch) by \ 
@mscuthbert in #1625
    Speed up hasElement by 2x by @TimFelixBeyer in #1621
    Work on noteworthy 1 75 binary reader by @nvuaille in #1247
    SoundParser to a separate file by @mscuthbert in #1627
    Fix #1561: Let makeTies iterate over parts by @TimFelixBeyer in #1571
    Feature/figuredbass object by @mxordn in #1614
    Add Policy on args/keywords by @mscuthbert in #1628
    Speed up contains by 2x and deprecate hasElement by @TimFelixBeyer in #1629
    Roman Numerals: Don't substitute d for 0 in add10 by @malcolmsailor in #1635
    TSV converter bug fix: don't add 'd' prefix to 2-digit added tones like \ 
[add13] by @malcolmsailor in #1634
    Python 3.12 Compatibility by @mscuthbert in #1654
    Fix ugly MusicXML durations & offsets by @TimFelixBeyer in #1632
    Improve commonName for enharmonic equivalent to minor seventh chords by \ 
@vanderstel in #1656
    check if HOME directory is writeable in getSettingsPath by @Leo1998 in #1657
    Fix argument annotation in converter.parse() signature by @jacobtylerwalls \ 
in #1665
    Fix #1663 by @TimFelixBeyer in #1664
    fix one incorrect doc by @mscuthbert in #1676
    Add Webern, Dormi Jesu by @mscuthbert in #1675
    Avoid testing truth value of ElementTree.Element by @jacobtylerwalls in #1666
    Simplify code and speed up for loops by @TimFelixBeyer in #1631
    Verticality.makeElement unpitched aware by @mscuthbert in #1678
    Styleguide Change - Union types by @mscuthbert in #1679
    In conversion from musicXML, allow multiple {Fret/String}Indications for \ 
chord. by @seffka in #1673
    Unpitched/Percussion export improvements by @mscuthbert in #1682
    Volume constructor to keyword only by @mscuthbert in #1681
    Avoid calling hyphenToCamelCase twice per note by @alexandermorgan in #1683
    Harmony parsing errors with doubled characters by @TimFelixBeyer in #1688
    Fix pylint recommendations by @TimFelixBeyer in #1694
    iterateAllVoiceLeadingQuartets() by @mscuthbert in #1701
    Add 'fa up' notehead type by @TimFelixBeyer in #1699
    Small spelling edits etc. by @mscuthbert in #1704
    A few ChordSymbol fixes by @gregchapman-dev in #1702
    Correct scale caching mechanism. by @TimFelixBeyer in #1692
    Simplify ChordBase duration creation by @TimFelixBeyer in #1691
    Small simplifications and speed-ups by @TimFelixBeyer in #1693
    Make _dissonanceScore independent of octaves by @TimFelixBeyer in #1695
    A few leadsheet-related fixes by @gregchapman-dev in #1708
    Cleanup on TSV-DCML Converter by @mscuthbert in #1716
    Respond to Changing Dev systems; Pin Numpy to <2.0 by @mscuthbert in #1723
    Update README.md -- new links by @mscuthbert in #1731
    Export stem styles on notes with implicit stem directions by \ 
@jacobtylerwalls in #1725
    Improve typing on Meter.Core by @mscuthbert in #1722
    Some Note/TinyNotation typing by @mscuthbert in #1734
    Fix Stream splitByQuarterLengths by @mscuthbert in #1736
    Add Python 3.13 Compatibility by @mscuthbert in #1737
    Remove tons of ellipses by @mscuthbert in #1738
   2024-10-14 08:46:10 by Thomas Klausner | Files touched by this commit (325)
Log message:
*: clean-up after python38 removal
   2023-10-28 21:57:26 by Thomas Klausner | Files touched by this commit (516) | Package updated
Log message:
python/wheel.mk: simplify a lot, and switch to 'installer' for installation

This follows the recommended bootstrap method (flit_core, build, installer).

However, installer installs different files than pip, so update PLISTs
for all packages using wheel.mk and bump their PKGREVISIONs.
   2023-08-02 01:20:57 by Thomas Klausner | Files touched by this commit (158)
Log message:
*: remove more references to Python 3.7
   2023-06-27 01:33:33 by David H. Gutteridge | Files touched by this commit (3) | Package updated
Log message:
py-music21: update to 9.1.0

Music21 v9 (June 2023) is the latest release of music21, a toolkit for \ 
computational music research.

Version 9 contains about 600 new commits and features from the version 8 release \ 
from September 2022. It is the latest and best release in the industry standard \ 
toolkit for doing music research and composition ("traditional" \ 
computation and AI/ML) with musical scores.

As a new Version X release, music21 gains a lot of its power with a few \ 
non-backwards compatible changes that make the system easier to use, faster, and \ 
more up to date. People using music21 in existing environments should read the \ 
change logs to make sure their systems work with it before upgrading.

A big change in music21 is that v9 is compatible with Python 3.10 and 3.11 only. \ 
The version 9 release will be updated to be compatible with at least Python 3.12 \ 
when it is released. Users on Python 3.8 and 3.9 should stick with v8 and those \ 
on older versions should look at the README to see what version will be \ 
installed for their systems.

Two weeks from the release of version 9 (July 1, 2023), Michael Asato Cuthbert, \ 
the lead developer of music21 will take a 6-12-month sabbatical from monitoring \ 
the mailing list, answering questions/issues, and merging PRs in order to focus \ 
on what he does best and what is best for the community: developing core parts \ 
of the system and documenting what already exists. Working with the user \ 
community has been amazing, but given that he only has about 10-15 hours per \ 
week to devote to the project, it often means deviating from efforts that help a \ 
large number of people to instead work through PRs and issues that are important \ 
to a smaller community. This news will probably not be welcomed by some, but the \ 
results should be better for the larger community.
What's Changed

    Music21 v9 is for Python 3.10 and 3.11 only and uses tools and speedups only \ 
available to those versions. Music21 drops its prior policy of supporting \ 
previous 3 versions and now supports the latest 2 versions only (to improve \ 
developer experience).
    Notebook/Jupyter: All pages are now shown on .show(). Compatible with \ 
Jupyter 7.0beta and JupyterLab. MIDI improvements (@mscuthbert in #1592)
    Added to corpus: (1) Queen Liliuokalani’s Aloha Oe, (2) J.R. Johnson’s \ 
Lift Every Voice And Sing (3) Vincente Lusitano’s madrigal Allor che Ignuda \ 
– part of a larger project to make the music21 corpus more representative.
    Lots more typing! Use music21 in a modern IDE to see it. Uses Python 3.10 \ 
TypeGuards. Add common.classTools.holdsType([‘a’, ‘b’], str) which \ 
asserts that everything in a collection has the same type. (@mscuthbert in \ 
#1447). converter and corpus are fully typed.
    Docs! Documentation of equality explained better. braille, corpus, converter \ 
much improved. (1) Much better aesthetics and utility @mscuthbert in #1455 and \ 
#1452). (2) Add “developerReference/startingOver” – mistakes made in \ 
designing music21 that are too late to fix, but the next generation of software \ 
should not emulate. (3) add docs about abcFormat support (@mscuthbert in #1484). \ 
(4) coreInsert (@mscuthbert in #1549). (5) layout (@mscuthbert in #1554). (6) \ 
clercqTemperley (RS100 dataset) format (#1558)
    RomanText and related formats: (1) Repeats in RT and TSV are improved \ 
(@malcolmsailor in #1434, #1435, #1503) (2) anacrusis support (@mscuthbert in \ 
#1532) (3) measure numbers on ClercqTemperley (@mscuthbert in #1558)
    harmony: (1) RomanNumerals and ChordSymbols with front accidentals (flat II, \ 
sharp IV, etc.) now take their 7ths, 9ths, etc. from the underlying keys \ 
(@mscuthbert w/ thanks to @malcolmsailor in #1439), (2) RomanNumeral’s \ 
writeAsChord works properly (@mscuthbert in #1445)
    and (3) transpose properly (@malcolmsailor in #1414). (4) \ 
roman.RomanNumeral(2, ‘C’) will now give d-minor, not d-major \ 
(@jacobtylerwalls in #1481), (5) preferSecondaryDominants implements V/x \ 
(@MarkGotham in #796).
    MusicXML improvements: (1) TempoText is exported (@gregchapman-dev in #1437)
    (2) harmony/numeral figures are MusicXML 4.0 compatible (@mscuthbert in \ 
#1445) (3) Preserve multiple fingerings on chords in musicxml import \ 
(@jacobtylerwalls in #1475) (4) Translate "implicit" attribute of \ 
MusicXML measures (@jacobtylerwalls in #1493) (5) Synchronize Measure IDs on \ 
Musicxml out (@rigaux in #1490) (6) MusicXML sound tag finds metronome marks \ 
(@TimFelixBeyer in #1579) (7) Add MusicXML security warning (@mscuthbert in \ 
#1584)
    Speed/Performance improvements on (1) deepcopy (@mscuthbert in #1464) (2) \ 
ABC (@mscuthbert in #1461) (3) LanguageDetector (@mscuthbert in #1456) (4) \ 
quantize() (@TimFelixBeyer in #1594) (5) use deques instead of pop(0) #1466, (6) \ 
searching/MetadataBundles cache in tests (@mscuthbert in #1511)
    (7) findGaps() on gapless streams (@jacobtylerwalls in #1515) (8) \ 
ChordSymbols (@jacobtylerwalls in #1527)
    Braille – add segment.BrailleElementGrouping. Good amount of refactoring. \ 
(@mscuthbert in #1495)
    Converter/Corpus: converter.toData – like .write or .show but gives the \ 
raw data as a string or byte by @mscuthbert in #1451
    Frozen/Immutable objects can be created now; this will allow for creating, \ 
for instance, one default 4/4 meter that cannot be changed but used as a default \ 
in many places. common.FrozenObject and duration.FrozenDuration (@mscuthbert in \ 
#1460)
    New subConverters register above default subConverters, so it is now \ 
possible to develop a subConverter like Greg’s converter21 project that \ 
handles a format music21 supports but do it differently or better. (@mscuthbert \ 
in #1520)
    Ornaments/Expressions (all by @gregchapman-dev) – (1) ornament accidentals \ 
have a great new system and are aware of their measure and key context (#1545) \ 
(2) Mordents get placement like Turn and Trill (#1516) (3) Support for delayed \ 
turns (#1533)
    Spanners: (1) Spanner.fill() – say you’ve set a slur to just include the \ 
first and last notes. .fill() will find all the intermediate notes. \ 
(@gregchapman-dev in #1486) (2) spanner.SpannerAnchor class allows a spanner to \ 
start and stop at a point where there is no other Music21Object at the offset \ 
(like a whole note crescendo that begins on beat 2 and ends on beat 3) \ 
(@gregchapman-dev in #1479). (3) Guitar: Hammer-on and Pull-off as Spanners \ 
(@louisbigo in #1142)
    Streams – (1) new module stream.tools and stream.tools.removeDuplicates \ 
(e.g. keys, clefs, by @MarkGotham in #1454) . (2) \ 
stream.makeNotation.saveAccidentalDisplayStatus() context manager for restoring \ 
pitches’ accidentalDisplayStatus after a manipulation (like transposition by \ 
octave) @gregchapman-dev. (3) stream.makeNotation.makeOrnamentalAccidentals \ 
(#1545)
    Percussion: (1) Implement useful PercussionChord.pitches property \ 
(@jacobtylerwalls in #1547), (2) Ignore Unpitched objects in key analysis \ 
(@jacobtylerwalls in #1543, (3) Search support (@mscuthbert in #1597)
    MIDI: (1) Minimize gaps produced by quantization algorithm (@jacobtylerwalls \ 
in #1540) (2) fix jupyter/colab MIDI (@mscuthbert in #1565) (3) Increase default \ 
MIDI ticksPerQuarter for higher accuracy of tuplets (@TimFelixBeyer in #1577)
    ABC: set version from I:abc-version information (@mscuthbert in #1589)
    pitch module gets: isValidAccidentalName, standardizeAccidentalName.

Bug fixes

    Ottava transposition bugs (in m21 and in musicxml output) (@gregchapman-dev \ 
in #1486)
    diminished and half-diminished 11th chord types were incorrect \ 
(@jacobtylerwalls in #1497)
    Avoid creating duplicative ChordStepModifications (@jacobtylerwalls in #1509)
    Zero quarterLengths will not be represented as Fraction(0, 1)
    MIDI: (1) Don't set status byte on Meta Message (@TimFelixBeyer in #1575) \ 
(2) unknown meta message still parses (@TimFelixBeyer in #1573)
    Fix stripTies when accidentals are natural & none (@TimFelixBeyer in #1556)
    Scores could previously change after .write()(@TimFelixBeyer in #1560)
    requests should have been in the minimum requirements (@jacobtylerwalls in #1568)
    Prevent doubly-flatted sevenths in chord symbols (@jacobtylerwalls in #1572)

Incompatible Changes not mentioned above:

    Equality: == or __eq__ comparison on many objects has changed. – it is now \ 
based on a class hierarchy where the object needs to be equal in all of its \ 
super-classes (@mscuthbert in #1466 and #1459).
    For time signatures: (@MarkGotham in #1457). For ChordStepModification \ 
(@jacobtylerwalls in #1482). An exception is made for RomanNumerals which do not \ 
need to have pitches in the same octave (like their chord.Chord superclass \ 
requires)
    schumann folder is moved to schumann_robert to match (equally amazing) \ 
schumann_clara.
    subConverter is consistently spelled with capital C in all contexts. Before \ 
it was a mismash of capital C and lowercase C. (in #1592)
    Full Measure Rests taken into account Finale usage of the measure=”yes” \ 
tag on pickups (@mscuthbert in #1595)
    All Music21Objects must be hashable and default instantiate (@mscuthbert in \ 
#1467)
    Duration, volume, and StreamStatus all keep string references to clients \ 
(major change if you were playing with _client private variables. Only a public \ 
change if you were counting on garbage collection to run more often)
    contextSites that are derived fixes a bug.
    Developers using the private _deepcopySubclassable should know that \ 
“removeFromIgnore” has been removed for performance reasons.
    Spanner.prePostObjectSpanners is renamed “relatedSpanners()”
    A number of cases where an attribute which is usually a string started with \ 
None now start with ‘’ instead (typing improvement)
    Refactors to ipython21 and the IPython (now Jupyter), MIDI, MusicXML \ 
subconverters in #1592.

Removals

    Music21Exception subclasses not used in the system are removed. Reduce 172 \ 
Exceptions to 154 (@mscuthbert in #1465)
    musicxml.xmlToM21.textNotNone – use new strippedText() and check for False.
    Already marked for deprecation and removed: common.cleanupFloat() (use \ 
opFrac), common.euclidGCD (use math.gcd), Metadata.setWorkId (use md.uniqueName \ 
= value), VoiceLeadingQuartet.color() (assign colors to individual notes with \ 
.style.color), (#1440)

Deprecations

    Spanner.numberRange replaces Spanner.getNumberList() — they do the same \ 
thing. (#1447)
    romanText.clercqTemperley – toScore() – call toPart() instead since that \ 
is what it does.
    scale.next() – use scale.nextPitch() instead – since it shadows \ 
Music21Object.next()

New Contributors

    @sararocks made her first contribution in #1472
    @rigaux made their first contribution in #1490
    @TimFelixBeyer made his first contribution in #1560
   2023-05-16 18:46:07 by David H. Gutteridge | Files touched by this commit (3) | Package updated
Log message:
py-music21: update to 8.3.0

Music21 v8.3 is a maintenance release that fixes a few bugs in \ 
romanText/translate (thanks @malcolmsailor) already in v9alpha, but also fixes a \ 
change in the Github.io version of music21j that broke .show('midi') inside \ 
Jupyter notebooks.
What's Changed

    Fixes bug in repeat tests in romanText/translate.py; handles empty measures \ 
by @malcolmsailor in #1434
    Fix mypy with github by @mscuthbert in #1438
    Romantext writer handle repeat bars and measure suffixes like m1a by \ 
@malcolmsailor in #1435
    No transpose altered 7,9,11,13 in bII7; chord.tools by @mscuthbert in #1439
    Backport 1565 to m21 v8 by @mscuthbert in #1567
   2023-05-16 00:05:11 by Thomas Klausner | Files touched by this commit (1)
Log message:
py-music21: py-guppy3 now supports python 3.11, so this might too
   2023-03-12 03:49:45 by David H. Gutteridge | Files touched by this commit (1)
Log message:
py-music21: s/BUILD_DEPENDS/TOOL_DEPENDS/