INFO('**************************************************************************') # set segment name: segment_name = 'segment_'+ str(i) pool.set('segments.'+segment_name+'.name', segment_name) # set segment scope: pool.set('segments.'+segment_name+'.scope', numpy.array([startTime, endTime])) # compute descriptors: namespace = 'segments.'+segment_name+'.descriptors' segments_namespace.append(namespace) INFO('\tProcess step 2: Low Level') computeLowLevel(input_file, pool, startTime, endTime, namespace) INFO('\tProcess step 3: Mid Level') computeMidLevel(input_file, pool, startTime, endTime, namespace) INFO('\tProcess step 4: High Level') highlevel.compute(pool, namespace) # compute the rest of the descriptors for the entire audio. LowLevel # descriptors were already computed during segmentation startTime = float(opt.startTime) audio_length = pool['metadata.audio_properties.length'] endTime = float(opt.endTime) if endTime > audio_length: endTime = audio_length INFO('**************************************************************************') INFO('processing entire audio from ' + str(startTime) + 's to ' + str(endTime) + 's') INFO('**************************************************************************') INFO('Process step 3: Mid Level') computeMidLevel(input_file, pool, startTime, endTime) INFO('Process step 4: High Level') highlevel.compute(pool)
# set segment name: segment_name = 'segment_'+ str(i) neqPool.set('segments.'+segment_name+'.name', segment_name) eqPool.set('segments.'+segment_name+'.name', segment_name) # set segment scope: neqPool.set('segments.'+segment_name+'.scope', numpy.array([startTime, endTime])) eqPool.set('segments.'+segment_name+'.scope', numpy.array([startTime, endTime])) # compute descriptors: namespace = 'segments.'+segment_name+'.descriptors' segments_namespace.append(namespace) INFO('\tProcess step 2: Low Level') computeLowLevel(input_file, neqPool, eqPool, startTime, endTime, namespace) INFO('\tProcess step 3: Mid Level') computeMidLevel(input_file, neqPool, eqPool, startTime, endTime, namespace) INFO('\tProcess step 4: High Level') highlevel.compute(eqPool, namespace) highlevel.compute(neqPool, namespace) # compute the rest of the descriptors for the entire audio. LowLevel # descriptors were already computed during segmentation startTime = float(opt.startTime) audio_length = neqPool['metadata.audio_properties.length'] endTime = float(opt.endTime) if endTime > audio_length: endTime = audio_length INFO('**************************************************************************') INFO('processing entire audio from ' + str(startTime) + 's to ' + str(endTime) + 's') INFO('**************************************************************************') INFO('Process step 3: Mid Level') computeMidLevel(input_file, neqPool, eqPool, startTime, endTime) INFO('Process step 4: High Level') highlevel.compute(eqPool)
# set segment name: segment_name = 'segment_' + str(i) pool.set('segments.' + segment_name + '.name', segment_name) # set segment scope: pool.set('segments.' + segment_name + '.scope', numpy.array([startTime, endTime])) # compute descriptors: namespace = 'segments.' + segment_name + '.descriptors' segments_namespace.append(namespace) INFO('\tProcess step 2: Low Level') computeLowLevel(input_file, pool, startTime, endTime, namespace) INFO('\tProcess step 3: Mid Level') computeMidLevel(input_file, pool, startTime, endTime, namespace) INFO('\tProcess step 4: High Level') highlevel.compute(pool, namespace) # compute the rest of the descriptors for the entire audio. LowLevel # descriptors were already computed during segmentation startTime = float(opt.startTime) audio_length = pool['metadata.audio_properties.length'] endTime = float(opt.endTime) if endTime > audio_length: endTime = audio_length INFO( '**************************************************************************' ) INFO('processing entire audio from ' + str(startTime) + 's to ' + str(endTime) + 's') INFO( '**************************************************************************' )
# set segment scope: neqPool.set('segments.' + segment_name + '.scope', numpy.array([startTime, endTime])) eqPool.set('segments.' + segment_name + '.scope', numpy.array([startTime, endTime])) # compute descriptors: namespace = 'segments.' + segment_name + '.descriptors' segments_namespace.append(namespace) INFO('\tProcess step 2: Low Level') computeLowLevel(input_file, neqPool, eqPool, startTime, endTime, namespace) INFO('\tProcess step 3: Mid Level') computeMidLevel(input_file, neqPool, eqPool, startTime, endTime, namespace) INFO('\tProcess step 4: High Level') highlevel.compute(eqPool, namespace) highlevel.compute(neqPool, namespace) # compute the rest of the descriptors for the entire audio. LowLevel # descriptors were already computed during segmentation startTime = float(opt.startTime) audio_length = neqPool['metadata.audio_properties.length'] endTime = float(opt.endTime) if endTime > audio_length: endTime = audio_length INFO( '**************************************************************************' ) INFO('processing entire audio from ' + str(startTime) + 's to ' + str(endTime) + 's') INFO( '**************************************************************************'