• Stars
    star
    779
  • Rank 56,172 (Top 2 %)
  • Language
    Nix
  • Created over 3 years ago
  • Updated about 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Simple GUI for ByteDance's Piano Transcription with Pedals

Simple GUI for ByteDance's Piano Transcription with Pedals

Test

ByteDance's Piano Transcription is the PyTorch implementation of the piano transcription system, "High-resolution Piano Transcription with Pedals by Regressing Onsets and Offsets Times [1]".

Using this, we can transcribe piano recordings into MIDI files with pedals.

This is a simple GUI and packaging for Windows and Nix on Linux/macOS.

Requirement

  • OS: Windows 7 or later (64-bit), Linux, macOS (Intel/M1)
  • Memory: at least 4G

Only Windows 10, Debian Linux 10, and macOS 12.1 M1 are tested.

How to use on Windows

  1. Download Microsoft Visual C++ Redistributable for Visual Studio 2015, 2017 and 2019 vc_redist_x64.exe and install
  2. Download and unpack PianoTrans-v1.0.7z (1.5GB download, unpack using 7zip)
  3. Close other apps to free memory, need at least 2G free memory
  4. Run PianoTrans.exe in PianoTrans directory
  5. Choose audio/video files, hold CTRL to select multiple files
  6. Result MIDI files are in the same directory as the input files

If you want right click menu, run RightClickMenuRegister.bat, then you can select multiple audio/video files, right click and choose Piano Transcribe.

PianoTrans automatically uses GPU for inference, if you encounter any problem, you can try PianoTrans-CPU.bat to force using CPU.

How to use on Linux/macOS using Nix

Note: This howto is for Nix on Linux/macOS, if you don't use Nix, you can also follow the upstream install and usage guide for Python pip instead.

  1. Open the terminal
  2. Install and setup Nix:
    sh <(curl -L https://nixos.org/nix/install) --daemon
    mkdir -p ~/.config/nix
    echo 'experimental-features = nix-command flakes' > ~/.config/nix/nix.conf
    See https://nixos.org/download.html for more details
  3. Use Nix to install pianotrans:
    nix profile install github:azuwis/pianotrans
  4. Run pianotrans to open the GUI, choose audio/video files, hold CTRL (โŒ˜ for macOS) to select multiple files

For CLI usage, run pianotrans file1 file2 ....

To upgrade pianotrans, run:

$ nix profile list
0 github:azuwis/pianotrans#defaultPackage.aarch64-linux github:azuwis/pianotrans/e19d5fd12f4295816fad49f6398e2e53ed2d2b7a#defaultPackage.aarch64-linux /nix/store/zdalndvcralish8d43drzslv0p4pm97v-python3.9-pianotrans-0.2.1
# list nix profiles, `0` is pianotrans
$ nix --option tarball-ttl 1 profile upgrade 0
$ nix profile list
0 github:azuwis/pianotrans#defaultPackage.aarch64-linux github:azuwis/pianotrans/e944720dd0dfcc2b87dcc39c1fdaab086eba4ca6#defaultPackage.aarch64-linux /nix/store/rv5iikrdvc7jrc7mqs8mkc21qh2gklhx-python3.9-pianotrans-1.0
# pianotrans upgraded to v1.0

FAQ

Q: Can you improve transcription result?

A: This project is about packaging for https://github.com/bytedance/piano_transcription, as long as it gives you MIDI files, all other issues are out of scope of this project.

You should report to the upstream project here https://github.com/bytedance/piano_transcription/issues

Changelog

[1.0.1] - 2023-02-09

  • Add --cli option to force disable GUI
  • Remove filetypes arg from askopenfilenames to avoid crash
  • Update Nix flake, and remove mido/soundfile/torchlibrosa/piano-transcription-inference overlay, all patches accepted in nixpkgs, this means more dependances can be fetched directly from Nix binary cache, less local builds
  • Add github test workflow

[1.0] - 2022-02-21

  • Support Linux/macOS using Nix
  • All platforms:
    • Add real GUI alongside CLI
    • GUI allow adding files to transcribe queue
  • Windows:
    • Right-click menu supports multiple files (need to re-run RightClickMenuRegister.bat)
    • Update pytorch to 1.10.2

[0.2.1] - 2021-12-23

  • Update pytorch to 1.10.1.
  • Update piano-transcription-inference to 0.0.5

[0.2] - 2021-09-27

  • Update pytorch to 1.9.1.
  • Add PianoTrans-CPU.bat to force using CPU for inference.

[0.1] - 2021-02-02

  • Initial release.

Cite

[1] Qiuqiang Kong, Bochen Li, Xuchen Song, Yuan Wan, and Yuxuan Wang. "High-resolution Piano Transcription with Pedals by Regressing Onsets and Offsets Times." arXiv preprint arXiv:2010.01815 (2020). [pdf]

More Repositories

1

zigbee2mqtt-networkmap

Home Assistant Custom Card to show Zigbee2mqtt network map
JavaScript
165
star
2

.pentadactyl

pentadactyl config files
JavaScript
40
star
3

sphinx_demo

sphinx demo setup with cjk pdf support
Python
16
star
4

nix-config

Nix
12
star
5

kindle-usbnetwork

add http proxy(for tethering) to kindle-usbnetwork from http://www.mobileread.com/forums/showthread.php?t=88004
Shell
11
star
6

magenta_transcribe

Simple GUI for TensorFlow Magenta Onsets and Frames Piano Transcription Tool
PowerShell
8
star
7

xreader

xReader fork from http://code.google.com/p/xreader/
C
4
star
8

erlang-for-dummies-zh-cn

21ๅคฉๅญฆ้€šErlang
Erlang
4
star
9

.vimfx

JavaScript
4
star
10

android_WebToolbox

Play and download Youku video
Java
4
star
11

org

Notes and misc stuff
Shell
3
star
12

torrent-ratio

Go
2
star
13

pianosight

HTML
2
star
14

openwrt-config

Configuration management for OpenWrt
Shell
2
star
15

ruby-gphotos

Use Selenium WebDriver to ease uploading files to Google Photos
Ruby
2
star
16

weather-calendar-feed

Display yr.no weather forecasts with highly customizable Event titles in your Google Calendar, phone or other iCalendar app
PHP
2
star
17

ansible-pc

Ansible playbooks for my personal computors
Jinja
1
star
18

home

~/
Emacs Lisp
1
star
19

openwrt-azuwis

OpenWRT custom feed
Makefile
1
star
20

ruby-lknovel

Ruby script to generate epub from http://lknovel.lightnovel.cn/
Ruby
1
star
21

kindle-dklite

striped version of duokan
Shell
1
star
22

debian_iscsitarget

Debian packaging for iscsitarget
C
1
star
23

mkrdns

fork of mkrdns from mkrdns.org
1
star
24

ubiquity

My ubiquity command
JavaScript
1
star
25

avalanche-rt

avalanche-rt, but without php, need only xml-rpc
JavaScript
1
star
26

piano-vlog

Svelte
1
star
27

cross-notify

Python
1
star
28

awesome

a fork of awesome window manager
1
star
29

mpd

a fork of mpd with patches(id3v1)
1
star
30

bin

~/bin/
Python
1
star
31

android_youku_helper

flash on youku was yesterday
Java
1
star
32

scrap

scrapbook backup
CSS
1
star
33

debian-repo

scripts and config files what help building a custom debian repo
Shell
1
star
34

ansible-openwrt

Shell
1
star
35

windows

misc staff for Windows
PowerShell
1
star
36

fetch-win32-symbols

Fork of http://hg.mozilla.org/users/tmielczarek_mozilla.com/fetch-win32-symbols/
Python
1
star
37

gmailThis

Pentadactyl plugin that helps saving selected content to gmail
JavaScript
1
star
38

emacs.d

My emacs config files
Emacs Lisp
1
star