Skip to content

Commit

Permalink
Refactor audio.py into smaller modules (#1144)
Browse files Browse the repository at this point in the history
* Tutorial materials in main readme page

* Refactor audio.py into smaller modules

* Fix missed global variable

* Fix broken import

* Fix accidentally broken tests

* Factor out path/file resolution from actual loading in AudioSource
  • Loading branch information
pzelasko committed Sep 13, 2023
1 parent 58a4292 commit b98521b
Show file tree
Hide file tree
Showing 26 changed files with 2,722 additions and 2,602 deletions.
2,528 changes: 0 additions & 2,528 deletions lhotse/audio.py

This file was deleted.

20 changes: 20 additions & 0 deletions lhotse/audio/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
from .backend import (
get_current_audio_backend,
get_default_audio_backend,
get_ffmpeg_torchaudio_info_enabled,
info,
read_audio,
set_current_audio_backend,
set_ffmpeg_torchaudio_info_enabled,
)
from .recording import Recording
from .recording_set import RecordingSet
from .source import AudioSource
from .utils import (
AudioLoadingError,
DurationMismatchError,
get_audio_duration_mismatch_tolerance,
null_result_on_audio_loading_error,
set_audio_duration_mismatch_tolerance,
suppress_audio_loading_errors,
)
Loading

0 comments on commit b98521b

Please sign in to comment.