HackerPoet / Composer

Generates video game music using neural networks.
https://youtu.be/UWxfnNXlVy8
1.13k stars 188 forks source link

[Question] How to make the Song longer? #26

Open MrKinauJr opened 5 years ago

MrKinauJr commented 5 years ago

Hello, i really like the music but its kinda short. Any Idea on how to make the Song longer? Like 2 mins?

ahfriedman commented 5 years ago

For the generated songs during training, changing MAX_LENGTH in train.py (128 should be 3-4 mins)

For the live editor, changing num_measures should increase the length of the song.

MrKinauJr commented 5 years ago

i changed all that but it still only saves about 35 seconds. Do i need to change something to save for longer?

ahfriedman commented 5 years ago

What did you change the variables to and how are you generating the files (during training from train.py, live_editor.py etc)?

MrKinauJr commented 5 years ago

Yeah i did change all the variables. I tried making a mod that instandly saves a Song after starting the composer.py . With that Mod i got a 4min Song but without anything in it. If i remove the Mod it just errors out. Traceback (most recent call last): File "composer.py", line 542, in <module> play() File "composer.py", line 521, in play draw_notes(screen, notes_surface) File "composer.py", line 316, in draw_notes pygame.surfarray.blit_array(notes_surface, get_pianoroll_from_notes(current_notes)) File "composer.py", line 299, in get_pianoroll_from_notes measure = np.rot90(notes[ix]) IndexError: index 16 is out of bounds for axis 0 with size 16

Daza99 commented 3 years ago

What about for those who are not programmers? Is there a way to make it play longer within the app itself?