mirror of
https://github.com/rakuri255/UltraSinger.git
synced 2026-11-20 13:07:52 +09:00
- Round bpm
This commit is contained in:
1 parent
8f169f0a6a
commit
ff07455365
2 files changed
+2
-2
No files matched your search
+1
-1
@@ -105,7 +105,7 @@ def get_bpm_from_data(data, sr):
|
||||
onset_env = librosa.onset.onset_strength(y=data, sr=sr)
|
||||
wav_tempo = librosa.beat.tempo(onset_envelope=onset_env, sr=sr)
|
||||
|
||||
print("{} BPM is {}".format(PRINT_ULTRASTAR, print_blue_highlighted_text(str(wav_tempo[0]))))
|
||||
print("{} BPM is {}".format(PRINT_ULTRASTAR, print_blue_highlighted_text(str(round(wav_tempo[0], 2)))))
|
||||
return wav_tempo[0]
|
||||
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ def create_ultrastar_txt_from_automation(transcribed_data, note_numbers, ultrast
|
||||
f.write('#LANGUAGE:' + get_language_name(language) + '\n')
|
||||
f.write('#MP3:' + title + '.mp3\n')
|
||||
f.write('#VIDEO:' + title + '.mp4\n')
|
||||
f.write('#BPM:' + str(ultrastar_bpm) + '\n') # not the real BPM!
|
||||
f.write('#BPM:' + str(round(ultrastar_bpm, 2)) + '\n') # not the real BPM!
|
||||
f.write('#GAP:' + str(int(gap * 1000)) + '\n')
|
||||
|
||||
# Write the singing part
|
||||
|
||||
Reference in new issue
Block a user