Spaces:
Running
Running
Update app.py
Browse files
__pycache__/analyze.cpython-310.pyc
CHANGED
Binary files a/__pycache__/analyze.cpython-310.pyc and b/__pycache__/analyze.cpython-310.pyc differ
|
|
__pycache__/process.cpython-310.pyc
CHANGED
Binary files a/__pycache__/process.cpython-310.pyc and b/__pycache__/process.cpython-310.pyc differ
|
|
__pycache__/transcription.cpython-310.pyc
CHANGED
Binary files a/__pycache__/transcription.cpython-310.pyc and b/__pycache__/transcription.cpython-310.pyc differ
|
|
app.py
CHANGED
@@ -327,7 +327,7 @@ def upload_audio():
|
|
327 |
if len(users) > 1:
|
328 |
print("複数人の場合の処理")
|
329 |
matched_times, segments_dir = process.process_multi_audio(reference_paths, audio_path, threshold=0.05)
|
330 |
-
total_audio = segments_dir
|
331 |
# 各メンバーのrateを計算
|
332 |
total_time = sum(matched_times)
|
333 |
rates = [(time / total_time) * 100 if total_time > 0 else 0 for time in matched_times]
|
@@ -337,7 +337,7 @@ def upload_audio():
|
|
337 |
return jsonify({"rates": rates, "user_rates": user_rates}), 200
|
338 |
else:
|
339 |
matched_time, unmatched_time, segments_dir = process.process_audio(reference_paths[0], audio_path, threshold=0.05)
|
340 |
-
total_audio = segments_dir
|
341 |
print("単一ユーザーの処理")
|
342 |
print(total_audio)
|
343 |
total_time = matched_time + unmatched_time
|
|
|
327 |
if len(users) > 1:
|
328 |
print("複数人の場合の処理")
|
329 |
matched_times, segments_dir = process.process_multi_audio(reference_paths, audio_path, threshold=0.05)
|
330 |
+
total_audio = transcripter.merge_segments(segments_dir)
|
331 |
# 各メンバーのrateを計算
|
332 |
total_time = sum(matched_times)
|
333 |
rates = [(time / total_time) * 100 if total_time > 0 else 0 for time in matched_times]
|
|
|
337 |
return jsonify({"rates": rates, "user_rates": user_rates}), 200
|
338 |
else:
|
339 |
matched_time, unmatched_time, segments_dir = process.process_audio(reference_paths[0], audio_path, threshold=0.05)
|
340 |
+
total_audio = transcripter.merge_segments(segments_dir)
|
341 |
print("単一ユーザーの処理")
|
342 |
print(total_audio)
|
343 |
total_time = matched_time + unmatched_time
|