sweetcocoa susnato commited on
Commit
9ab6752
1 Parent(s): 2d8de50

update_files (#2)

Browse files

- files added (11b15ddffff9cd12297afb0da579eadd43c99321)


Co-authored-by: Susnato Dhar <[email protected]>

README.md CHANGED
@@ -1,12 +1,67 @@
1
  ---
2
- license: mit
3
- metrics:
4
- - accuracy
5
- tags:
6
- - piano cover generation
7
- datasets:
8
- - PSP
9
- references:
10
- - https://arxiv.org/abs/2211.00895
11
  ---
12
- .
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ # For reference on model card metadata, see the spec: https://github.com/huggingface/hub-docs/blob/main/modelcard.md?plain=1
3
+ # Doc / guide: https://huggingface.co/docs/hub/model-cards
4
+ {}
 
 
 
 
 
 
5
  ---
6
+
7
+ # POP2PIANO
8
+
9
+ Pop2Piano, a Transformer network that generates piano covers given waveforms of pop
10
+ music.
11
+ # Model Details
12
+
13
+ Pop2Piano was proposed in the paper [Pop2Piano : Pop Audio-based Piano Cover Generation](https://arxiv.org/abs/2211.00895) by Jongho Choi and Kyogu Lee.
14
+
15
+ Inspired by [T5](https://arxiv.org/abs/1910.10683), Pop2Piano
16
+ is the first model to generate a piano cover directly from pop audio without using melody and
17
+ chord extraction modules.
18
+
19
+ ## Model Sources
20
+
21
+ - [**Original Repository**](https://github.com/sweetcocoa/pop2piano)
22
+ - [**Paper**](https://arxiv.org/abs/2211.00895)
23
+ - [**Demo**]# TODO (after the ongoing PR is merged)
24
+
25
+ # Usage
26
+
27
+ First, install the required packages:
28
+
29
+ ```
30
+ pip install --upgrade transformers
31
+ ```
32
+
33
+ ## Pop music to Piano
34
+
35
+ TODO (after the ongoing PR is merged)
36
+
37
+ ## Example
38
+
39
+ ### Pop Music
40
+
41
+ <audio controls>
42
+ <source src="https://datasets-server.huggingface.co/assets/sweetcocoa/pop2piano_ci/--/sweetcocoa--pop2piano_ci/test/0/audio/audio.mp3" type="audio/mpeg">
43
+ Your browser does not support the audio element.
44
+ </audio>
45
+
46
+ ### Generated MIDI
47
+
48
+ TODO (after the MIDI version is uploaded to the same repo above)
49
+
50
+ ## Tips
51
+
52
+ TODO
53
+
54
+
55
+ # Citation
56
+
57
+ **BibTeX:**
58
+ ```
59
+ @misc{choi2023pop2piano,
60
+ title={Pop2Piano : Pop Audio-based Piano Cover Generation},
61
+ author={Jongho Choi and Kyogu Lee},
62
+ year={2023},
63
+ eprint={2211.00895},
64
+ archivePrefix={arXiv},
65
+ primaryClass={cs.SD}
66
+ }
67
+ ```
config.json CHANGED
@@ -32,5 +32,6 @@
32
  "n_fft":4096,
33
  "hop_length":1024,
34
  "f_min":10.0,
35
- "n_mels":512
 
36
  }
 
32
  "n_fft":4096,
33
  "hop_length":1024,
34
  "f_min":10.0,
35
+ "n_mels":512,
36
+ "composer_vocab_size":21
37
  }
generation_config.json ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "decoder_start_token_id": 0,
3
+ "eos_token_id": 1,
4
+ "pad_token_id": 0,
5
+ "return_dict_in_generate": false,
6
+ "max_length": 256,
7
+ "composer_to_feature_token":{
8
+ "composer1": 2052,
9
+ "composer2": 2053,
10
+ "composer3": 2054,
11
+ "composer4": 2055,
12
+ "composer5": 2056,
13
+ "composer6": 2057,
14
+ "composer7": 2058,
15
+ "composer8": 2059,
16
+ "composer9": 2060,
17
+ "composer10": 2061,
18
+ "composer11": 2062,
19
+ "composer12": 2063,
20
+ "composer13": 2064,
21
+ "composer14": 2065,
22
+ "composer15": 2066,
23
+ "composer16": 2067,
24
+ "composer17": 2068,
25
+ "composer18": 2069,
26
+ "composer19": 2070,
27
+ "composer20": 2071,
28
+ "composer21": 2072
29
+ }
30
+ }
preprocessor_config.json CHANGED
@@ -3,14 +3,17 @@
3
  "start_token_id": 0,
4
  "target_length": 256,
5
  "input_length": 1024,
6
- "n_bars": 2,
7
  "sampling_rate": 22050,
8
- "use_mel": true,
9
  "mel_is_conditioned": true,
10
  "padding_value": 0,
11
  "eos_token_id": 1,
12
  "vocab_size_special": 4,
13
  "vocab_size_note": 128,
14
  "vocab_size_velocity": 2,
15
- "vocab_size_time": 100
 
 
 
 
16
  }
 
3
  "start_token_id": 0,
4
  "target_length": 256,
5
  "input_length": 1024,
6
+ "num_bars": 2,
7
  "sampling_rate": 22050,
 
8
  "mel_is_conditioned": true,
9
  "padding_value": 0,
10
  "eos_token_id": 1,
11
  "vocab_size_special": 4,
12
  "vocab_size_note": 128,
13
  "vocab_size_velocity": 2,
14
+ "vocab_size_time": 100,
15
+ "window_size":4096,
16
+ "hop_length":1024,
17
+ "min_frequency":10.0,
18
+ "feature_size":512
19
  }
pytorch_model.bin CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:922e69a8b08e20231ea8c4e47cfe53c6854e78951938c4e9e74e5f16f43b101a
3
- size 240697027
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4ebff90f182961d1dc7c8cf481289b5c926610fe89993b5b02f1a61fb29dfa45
3
+ size 236483933
tokenizer_config.json ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "tokenizer_class": "Pop2PianoTokenizer",
3
+ "vocab_size_special" : 4,
4
+ "vocab_size_note" : 128,
5
+ "vocab_size_velocity" : 2,
6
+ "vocab_size_time" : 100,
7
+ "num_bars" : 2
8
+ }