Audio Loader¶
- modusa.load(path, sr=None, clip=None)[source]¶
Loads audio file from various sources.
import modusa as ms audio_fp = ms.load( "https://www.youtube.com/watch?v=lIpw9-Y_N0g", sr = None, clip=(5, 10))
- Parameters:
path (str) –
Path to the audio
Youtube URL
sr (int | None) –
Sampling rate to load the audio in.
clip (number | tuple[number, number] | None) –
Which segment of the audio you want.
Eg., 10 => First 10 sec, (5, 10) => 5 to 10 second
Default: None => Entire audio.
- Returns:
np.ndarray –
Audio signal.
int –
Sampling rate of the loaded audio signal.
title –
Title of the loaded audio.
Filename without extension or YouTube title.