Skip to content

Commit

Permalink
Fix IO audio module
Browse files Browse the repository at this point in the history
  • Loading branch information
druzsan committed May 10, 2024
1 parent 69e8a8d commit 0a0db9e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 0 additions & 1 deletion renumics/spotlight/embeddings/preprocessors.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
from typing import List, cast

import av
import av.audio
import numpy as np
import PIL.Image

Expand Down
3 changes: 2 additions & 1 deletion renumics/spotlight/io/audio.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,8 @@ def get_format_codec(file: FileType) -> Tuple[str, str]:
file = prepare_input_file(file)
with av.open(file, "r") as input_container:
stream = input_container.streams.audio[0]
return input_container.format.name, stream.name # type: ignore
return input_container.format.name, stream.name # type: ignore
assert False # unnecessary, but mypy fails otherwise


def get_waveform(file: FileType) -> np.ndarray:
Expand Down

0 comments on commit 0a0db9e

Please sign in to comment.