pymatchmaker 0.5.0__cp313-cp313-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (73) hide show
  1. docs/source/conf.py +42 -0
  2. matchmaker/__init__.py +44 -0
  3. matchmaker/assets/Bach-fugue_bwv_858.match +1556 -0
  4. matchmaker/assets/Bach-fugue_bwv_858.mid +0 -0
  5. matchmaker/assets/Bach-fugue_bwv_858.mp3 +0 -0
  6. matchmaker/assets/Bach-fugue_bwv_858.musicxml +14490 -0
  7. matchmaker/assets/Bach-fugue_bwv_858_beat_annotations.txt +136 -0
  8. matchmaker/assets/Bach-fugue_bwv_858_note_annotations.txt +522 -0
  9. matchmaker/assets/mozart_k265_var1.match +302 -0
  10. matchmaker/assets/mozart_k265_var1.mid +0 -0
  11. matchmaker/assets/mozart_k265_var1.mp3 +0 -0
  12. matchmaker/assets/mozart_k265_var1.musicxml +3120 -0
  13. matchmaker/assets/mozart_k265_var1_annotations.txt +48 -0
  14. matchmaker/assets/mozart_k265_var1_annotations_trim.txt +17 -0
  15. matchmaker/assets/mozart_k265_var1_short_trim.mp3 +0 -0
  16. matchmaker/assets/simple_mozart_first_two_measures.png +0 -0
  17. matchmaker/assets/simple_mozart_k265_var1.match +99 -0
  18. matchmaker/assets/simple_mozart_k265_var1.mei +256 -0
  19. matchmaker/assets/simple_mozart_k265_var1.mid +0 -0
  20. matchmaker/assets/simple_mozart_k265_var1.mp3 +0 -0
  21. matchmaker/assets/simple_mozart_k265_var1.musicxml +1126 -0
  22. matchmaker/assets/simple_mozart_k265_var1_annotations.txt +16 -0
  23. matchmaker/assets/simple_mozart_k265_var1_beat_annotations.txt +16 -0
  24. matchmaker/assets/simple_mozart_k265_var1_note_annotations.txt +54 -0
  25. matchmaker/base.py +158 -0
  26. matchmaker/dp/__init__.py +22 -0
  27. matchmaker/dp/dannenberg.py +261 -0
  28. matchmaker/dp/direction.py +12 -0
  29. matchmaker/dp/dtw_loop.cp313-win_amd64.pyd +0 -0
  30. matchmaker/dp/dtw_loop.pyx +200 -0
  31. matchmaker/dp/oltw_arzt.py +759 -0
  32. matchmaker/dp/oltw_arzt_multi_fold.py +386 -0
  33. matchmaker/dp/oltw_dixon.py +575 -0
  34. matchmaker/external/__init__.py +176 -0
  35. matchmaker/features/__init__.py +7 -0
  36. matchmaker/features/audio.py +590 -0
  37. matchmaker/features/midi.py +622 -0
  38. matchmaker/features/processor.py +455 -0
  39. matchmaker/io/__init__.py +13 -0
  40. matchmaker/io/audio.py +452 -0
  41. matchmaker/io/mediator.py +194 -0
  42. matchmaker/io/midi.py +489 -0
  43. matchmaker/io/queue.py +31 -0
  44. matchmaker/io/stream.py +120 -0
  45. matchmaker/matchmaker.py +554 -0
  46. matchmaker/methods.yaml +419 -0
  47. matchmaker/prob/__init__.py +9 -0
  48. matchmaker/prob/hmm.py +2065 -0
  49. matchmaker/prob/outer_product_hmm.py +499 -0
  50. matchmaker/prob/outer_product_hmm_audio.py +606 -0
  51. matchmaker/prob/particle_filter_korzeniowski.py +882 -0
  52. matchmaker/prob/skf.py +631 -0
  53. matchmaker/prob/templates/pitch_templates_16000_640.npz +0 -0
  54. matchmaker/prob/viterbi_step.cp313-win_amd64.pyd +0 -0
  55. matchmaker/prob/viterbi_step.pyx +63 -0
  56. matchmaker/registry.py +628 -0
  57. matchmaker/utils/__init__.py +17 -0
  58. matchmaker/utils/audio.py +151 -0
  59. matchmaker/utils/distances.cp313-win_amd64.pyd +0 -0
  60. matchmaker/utils/distances.pxd +11 -0
  61. matchmaker/utils/distances.pyx +228 -0
  62. matchmaker/utils/errors.py +46 -0
  63. matchmaker/utils/eval.py +587 -0
  64. matchmaker/utils/math.py +46 -0
  65. matchmaker/utils/misc.py +406 -0
  66. matchmaker/utils/symbolic.py +510 -0
  67. matchmaker/utils/tempo_models.py +854 -0
  68. matchmaker/utils/typing.py +51 -0
  69. pymatchmaker-0.5.0.dist-info/METADATA +549 -0
  70. pymatchmaker-0.5.0.dist-info/RECORD +73 -0
  71. pymatchmaker-0.5.0.dist-info/WHEEL +5 -0
  72. pymatchmaker-0.5.0.dist-info/licenses/LICENSE +201 -0
  73. pymatchmaker-0.5.0.dist-info/top_level.txt +4 -0
docs/source/conf.py ADDED
@@ -0,0 +1,42 @@
1
+ # Configuration file for the Sphinx documentation builder.
2
+ #
3
+ # For the full list of built-in configuration values, see the documentation:
4
+ # https://www.sphinx-doc.org/en/master/usage/configuration.html
5
+
6
+ # -- Project information -----------------------------------------------------
7
+ # https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
8
+ import os
9
+ import sys
10
+
11
+ sys.path.insert(0, os.path.abspath(".."))
12
+
13
+ project = "pymatchmaker"
14
+ copyright = "2024, matchmaker development team"
15
+ author = "matchmaker development team"
16
+ release = "0.5.0"
17
+
18
+ # -- General configuration ---------------------------------------------------
19
+ # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
20
+
21
+ extensions = [
22
+ "sphinx.ext.autodoc",
23
+ "sphinx.ext.autosummary",
24
+ "sphinx.ext.doctest",
25
+ "sphinx.ext.todo",
26
+ "sphinx.ext.coverage",
27
+ "sphinx.ext.mathjax",
28
+ "sphinx.ext.viewcode",
29
+ "myst_parser",
30
+ ]
31
+
32
+ templates_path = ["_templates"]
33
+ exclude_patterns = []
34
+
35
+ myst_url_schemes = ["http", "https", "mailto"]
36
+ myst_enable_extensions = ["colon_fence", "deflist"]
37
+ suppress_warnings = ["myst.xref_missing"]
38
+
39
+ # -- Options for HTML output -------------------------------------------------
40
+ # https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output
41
+
42
+ html_theme = "sphinx_rtd_theme"
matchmaker/__init__.py ADDED
@@ -0,0 +1,44 @@
1
+ #!/usr/bin/python
2
+ # -*- coding: utf-8 -*-
3
+ """
4
+ Matchmaker is a library for real-time music alignment
5
+ """
6
+
7
+ from importlib.metadata import PackageNotFoundError, version
8
+ from pathlib import Path
9
+
10
+ from . import dp, features, io, prob, utils
11
+ from .matchmaker import *
12
+
13
+ __all__ = ["dp", "features", "io", "prob", "utils"]
14
+
15
+ try:
16
+ __version__ = version("pymatchmaker")
17
+ except PackageNotFoundError: # pragma: no cover
18
+ __version__ = "0.5.0"
19
+
20
+ ASSETS_DIR = Path(__file__).parent / "assets"
21
+
22
+ EXAMPLE_PIECES = {
23
+ "simple_mozart": {
24
+ "score": str(ASSETS_DIR / "simple_mozart_k265_var1.musicxml"),
25
+ "midi": str(ASSETS_DIR / "simple_mozart_k265_var1.mid"),
26
+ "audio": str(ASSETS_DIR / "simple_mozart_k265_var1.mp3"),
27
+ "match": str(ASSETS_DIR / "simple_mozart_k265_var1.match"),
28
+ "annotations": str(ASSETS_DIR / "simple_mozart_k265_var1_note_annotations.txt"),
29
+ },
30
+ "bach_fugue": {
31
+ "score": str(ASSETS_DIR / "Bach-fugue_bwv_858.musicxml"),
32
+ "midi": str(ASSETS_DIR / "Bach-fugue_bwv_858.mid"),
33
+ "audio": str(ASSETS_DIR / "Bach-fugue_bwv_858.mp3"),
34
+ "match": str(ASSETS_DIR / "Bach-fugue_bwv_858.match"),
35
+ "annotations": str(ASSETS_DIR / "Bach-fugue_bwv_858_note_annotations.txt"),
36
+ "beat_annotations": str(ASSETS_DIR / "Bach-fugue_bwv_858_beat_annotations.txt"),
37
+ },
38
+ }
39
+
40
+ # Legacy constants
41
+ EXAMPLE_SCORE = str(ASSETS_DIR / "mozart_k265_var1.musicxml")
42
+ EXAMPLE_PERFORMANCE = str(ASSETS_DIR / "mozart_k265_var1.mid")
43
+ EXAMPLE_MATCH = str(ASSETS_DIR / "mozart_k265_var1.match")
44
+ EXAMPLE_AUDIO = str(ASSETS_DIR / "mozart_k265_var1.mp3")