Skip to content

Commit

Permalink
Don't need these logging statements
Browse files Browse the repository at this point in the history
  • Loading branch information
WyattBlue committed Jun 5, 2024
1 parent 59f158e commit 8502ea3
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 11 deletions.
7 changes: 1 addition & 6 deletions auto_editor/analyze.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,8 +170,6 @@ def media_length(self) -> int:
# If there's no audio, get length in video metadata.
import av

av.logging.set_level(av.logging.PANIC)

with av.open(f"{self.src.path}") as cn:
if len(cn.streams.video) < 1:
self.log.error("Could not get media duration")
Expand Down Expand Up @@ -344,13 +342,10 @@ def cleanhtml(raw_html: str) -> str:
def motion(self, s: int, blur: int, width: int) -> NDArray[np.float64]:
import av

av.logging.set_level(av.logging.PANIC)

mobj = {"stream": s, "width": width, "blur": blur}

if s >= len(self.src.videos):
raise LevelError(f"motion: video stream '{s}' does not exist.")

mobj = {"stream": s, "width": width, "blur": blur}
if (arr := self.read_cache("motion", mobj)) is not None:
return arr

Expand Down
2 changes: 0 additions & 2 deletions auto_editor/ffwrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,6 @@ def __repr__(self) -> str:
def initFileInfo(path: str, log: Log) -> FileInfo:
import av

av.logging.set_level(av.logging.PANIC)

try:
cont = av.open(path, "r")
except av.error.InvalidDataError:
Expand Down
3 changes: 0 additions & 3 deletions auto_editor/render/video.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@
from auto_editor.utils.types import Args


av.logging.set_level(av.logging.PANIC)


@dataclass(slots=True)
class VideoFrame:
index: int
Expand Down

0 comments on commit 8502ea3

Please sign in to comment.