From 7966e7d534763145894e51a951f7ae26140bda3b Mon Sep 17 00:00:00 2001 From: mulfordjc Date: Thu, 26 Mar 2015 15:54:13 -0400 Subject: [PATCH] Changed to compute by segments instead of beats --- beatshift.py | 2 +- songmix.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/beatshift.py b/beatshift.py index 4081385..ef8228c 100644 --- a/beatshift.py +++ b/beatshift.py @@ -27,7 +27,7 @@ def main(input_filename, start_beat, shift_length, shift_magnitude, output_filen beat_count = 0 audiofile = audio.LocalAudioFile(input_filename) - beats = audiofile.analysis.beats + beats = audiofile.analysis.segments collect = [] for beat in beats: diff --git a/songmix.py b/songmix.py index ce53d00..d29c198 100644 --- a/songmix.py +++ b/songmix.py @@ -34,7 +34,7 @@ def main(first_filename, second_filename, start_beat, shift_length, second_start beat_count = 0 audiofile1 = audio.LocalAudioFile(first_filename) - beats1 = audiofile1.analysis.beats + beats1 = audiofile1.analysis.segments collect = [] while (beat_count < start_beat + shift_length and beat_count < len(beats1)): @@ -53,7 +53,7 @@ def main(first_filename, second_filename, start_beat, shift_length, second_start beat_count = second_start audiofile2 = audio.LocalAudioFile(second_filename) - beats2 = audiofile2.analysis.beats + beats2 = audiofile2.analysis.segments while (beat_count < len(beats2)): beat_audio = beats2[beat_count].render()