asigalov61
commited on
Update README.md
Browse files
README.md
CHANGED
@@ -276,8 +276,6 @@ model = mpt.load_model()
|
|
276 |
|
277 |
# Generate single chord
|
278 |
output_tokens = mpt.generate_chord(model)
|
279 |
-
|
280 |
-
print(output_tokens)
|
281 |
```
|
282 |
|
283 |
### Chords progressions
|
@@ -307,8 +305,6 @@ output_tokens = mpt.generate(model, chords_tokens, num_gen_tokens=32, return_pri
|
|
307 |
|
308 |
# Convert output tokens batch # 0 back to the chords list
|
309 |
chords_list = mpt.chords_tokens_to_chords(output_tokens[0])
|
310 |
-
|
311 |
-
print(chords_list)
|
312 |
```
|
313 |
|
314 |
### Chords texturing
|
@@ -500,7 +496,12 @@ sample_notes_list = [
|
|
500 |
]
|
501 |
|
502 |
# Use notes_list_to_tokens_chords_pitches function to convert the notes list
|
503 |
-
|
|
|
|
|
|
|
|
|
|
|
504 |
```
|
505 |
|
506 |
***
|
@@ -527,10 +528,10 @@ tim_model = mpt.load_model('timings inpainting - 2 epochs')
|
|
527 |
# Dev models parameters can be accessed like so
|
528 |
|
529 |
# Max sequence length
|
530 |
-
|
531 |
|
532 |
# Max number of tokens
|
533 |
-
|
534 |
```
|
535 |
|
536 |
### Generation
|
|
|
276 |
|
277 |
# Generate single chord
|
278 |
output_tokens = mpt.generate_chord(model)
|
|
|
|
|
279 |
```
|
280 |
|
281 |
### Chords progressions
|
|
|
305 |
|
306 |
# Convert output tokens batch # 0 back to the chords list
|
307 |
chords_list = mpt.chords_tokens_to_chords(output_tokens[0])
|
|
|
|
|
308 |
```
|
309 |
|
310 |
### Chords texturing
|
|
|
496 |
]
|
497 |
|
498 |
# Use notes_list_to_tokens_chords_pitches function to convert the notes list
|
499 |
+
output = mpt.notes_list_to_tokens_chords_pitches(sample_notes_list)
|
500 |
+
|
501 |
+
input_tokens = output[0]
|
502 |
+
chords_tokens = output[1]
|
503 |
+
pitches_list = output[2]
|
504 |
+
chords_list = output[3]
|
505 |
```
|
506 |
|
507 |
***
|
|
|
528 |
# Dev models parameters can be accessed like so
|
529 |
|
530 |
# Max sequence length
|
531 |
+
default_model.max_seq_len
|
532 |
|
533 |
# Max number of tokens
|
534 |
+
default_model.pad_value
|
535 |
```
|
536 |
|
537 |
### Generation
|