MCPcopy Create free account
hub / github.com/Mercury7353/PyBench / get_mp3_duration

Function get_mp3_duration

data/unit_test/tests.py:1465–1467  ·  view source on GitHub ↗
(file_path)

Source from the content-addressed store, hash-verified

1463from mutagen.mp3 import MP3
1464
1465def get_mp3_duration(file_path):
1466 audio = MP3(file_path)
1467 return audio.info.length * 1000 # 持续时间以毫秒为单位
1468
1469def test_task_150(trajectory):
1470 audio_path = "./output/150.mp3"

Callers 1

test_task_150Function · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected