{"id":13862209,"url":"https://github.com/YatingMusic/compound-word-transformer","last_synced_at":"2025-07-14T11:32:47.182Z","repository":{"id":40199878,"uuid":"317103555","full_name":"YatingMusic/compound-word-transformer","owner":"YatingMusic","description":"Official implementation of compound word transformer (AAAI'21)","archived":false,"fork":false,"pushed_at":"2023-11-27T13:33:38.000Z","size":2165,"stargazers_count":265,"open_issues_count":15,"forks_count":43,"subscribers_count":7,"default_branch":"main","last_synced_at":"2024-08-05T06:05:25.947Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/YatingMusic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-11-30T03:44:52.000Z","updated_at":"2024-07-15T18:02:01.000Z","dependencies_parsed_at":"2024-08-05T06:14:43.116Z","dependency_job_id":null,"html_url":"https://github.com/YatingMusic/compound-word-transformer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YatingMusic%2Fcompound-word-transformer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YatingMusic%2Fcompound-word-transformer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YatingMusic%2Fcompound-word-transformer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YatingMusic%2Fcompound-word-transformer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/YatingMusic","download_url":"https://codeload.github.com/YatingMusic/compound-word-transformer/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225974349,"owners_count":17553938,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-05T06:01:39.449Z","updated_at":"2024-11-22T22:30:42.879Z","avatar_url":"https://github.com/YatingMusic.png","language":"Python","funding_links":[],"categories":["Python","License"],"sub_categories":[],"readme":"# Compound Word Transformer\n\n\nAuthors: [Wen-Yi Hsiao](https://github.com/wayne391), [Jen-Yu Liu](https://github.com/ciaua), [Yin-Cheng Yeh](https://github.com/yyeh26) and [Yi-Hsuan Yang](http://mac.citi.sinica.edu.tw/~yang/)\n\n[**Paper (arXiv)**](https://arxiv.org/abs/2101.02402) | [**Audio demo (Google Drive)**](https://drive.google.com/drive/folders/1G_tTpcAuVpYO-4IUGS8i8XdwoIsUix8o?usp=sharing) | [**Blog**](https://ailabs.tw/human-interaction/compound-word-transformer-generate-pop-piano-music-of-full-song-length/) | [**Colab notebook**](https://colab.research.google.com/drive/1AU8iMhy10WxHj7yt3j8S3FQvvKvgXrr0)\n\nOfficial PyTorch implementation of AAAI2021 paper \"Compound Word Transformer: Learning to Compose Full-Song Musicover Dynamic Directed Hypergraphs\".\n\nWe presented a new variant of the Transformer that can processes multiple consecutive tokens at once at a time step. The proposed method can greatly reduce the length of the resulting sequence and therefore enhance the training and inference efficiency. We employ it to learn to compose expressive Pop piano music of full-song length (involving up to 10K individual to23 kens per song). In this repository, we open source our **Ailabs.tw 1K7** dataset, and the codes for unconditional generation.\n\n\n## Dependencies\n\n* python 3.6\n* Required packages:\n    * madmom\n    * miditoolkit\n    * pytorch-fast-transformers\n \n\n``chorder`` is our in-house rule-based symbolic chord recognition algorithm, which is developed by our former intern - [joshuachang2311](https://github.com/joshuachang2311/chorder). He is also a jazz pianist :musical_keyboard:. \n\n\n## Model\nIn this work, we conduct two scenario of generation:\n* unconditional generation\n    * To see the experimental results and discussion, please refer to [here](https://github.com/YatingMusic/compound-word-transformer/blob/main/workspace/uncond/Experiments.md). \n\n* conditional generation, leadsheet to full midi (ls2midi)\n    * [**Work in progress**] We plan to open source the code associated with this part in the future. \n        * melody extracyion (skyline) \n        * objective metrics\n        * model\n\n## Dataset\nTo prepare your own training data, please refer to [documentaion](https://github.com/YatingMusic/compound-word-transformer/blob/main/dataset/Dataset.md) for further understanding.  \nOr, you can start with our **AIlabs.tw Pop1K7**, which is available [here](https://drive.google.com/file/d/1qw_tVUntblIg4lW16vbpjLXVndkVtgDe/view?usp=sharing).\n\n## Demo: Colab Notebook\n\nThe colab notebook is now available [here](https://colab.research.google.com/drive/1AU8iMhy10WxHj7yt3j8S3FQvvKvgXrr0).  \nThanks our intern [AdarshKumar712](https://github.com/AdarshKumar712) for organizing the codes.\n\n\n## Acknowledgement\n- PyTorch codes for transformer-XL is modified from [kimiyoung/transformer-xl](https://github.com/kimiyoung/transformer-xl).\n- Thanks [Yu-Hua Chen](https://github.com/ss12f32v) and [Hsiao-Tzu Hung](https://github.com/annahung31) for helping organize the codes.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FYatingMusic%2Fcompound-word-transformer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FYatingMusic%2Fcompound-word-transformer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FYatingMusic%2Fcompound-word-transformer/lists"}