ffmpeg-normalize 1.37.3__tar.gz → 1.37.5__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (17) hide show
  1. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/PKG-INFO +1 -1
  2. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/pyproject.toml +6 -13
  3. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/_media_file.py +2 -2
  4. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/_streams.py +8 -6
  5. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/LICENSE.md +0 -0
  6. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/README.md +0 -0
  7. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/__init__.py +0 -0
  8. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/__main__.py +0 -0
  9. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/_cmd_utils.py +0 -0
  10. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/_errors.py +0 -0
  11. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/_ffmpeg_normalize.py +0 -0
  12. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/_logger.py +0 -0
  13. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/_presets.py +0 -0
  14. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/data/presets/music.json +0 -0
  15. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/data/presets/podcast.json +0 -0
  16. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/data/presets/streaming-video.json +0 -0
  17. {ffmpeg_normalize-1.37.3 → ffmpeg_normalize-1.37.5}/src/ffmpeg_normalize/py.typed +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ffmpeg-normalize
3
- Version: 1.37.3
3
+ Version: 1.37.5
4
4
  Summary: Normalize audio via ffmpeg
5
5
  Keywords: ffmpeg,normalize,audio
6
6
  Author: Werner Robitza
@@ -1,10 +1,10 @@
1
1
  [build-system]
2
- requires = ["uv_build>=0.8.14,<0.9.0"]
2
+ requires = ["uv_build>=0.8.14,<1.0.0"]
3
3
  build-backend = "uv_build"
4
4
 
5
5
  [project]
6
6
  name = "ffmpeg-normalize"
7
- version = "1.37.3"
7
+ version = "1.37.5"
8
8
  description = "Normalize audio via ffmpeg"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -52,19 +52,12 @@ package-data = {"ffmpeg_normalize" = ["data/**/*.json"]}
52
52
  dev = [
53
53
  "pytest>=8.1.1,<9",
54
54
  "ruff>=0.12.11",
55
- "mypy>=1.0.0",
56
55
  "types-tqdm",
57
56
  "shtab>=1.7.0",
57
+ "ty>=0.0.24",
58
58
  ]
59
59
 
60
- [tool.mypy]
61
- python_version = "3.13"
62
- ignore_missing_imports = true
63
- exclude = ["build"]
64
- namespace_packages = false
65
- no_implicit_optional = true
66
- check_untyped_defs = true
67
- warn_return_any = true
68
- warn_unused_ignores = true
69
- show_error_codes = true
60
+ [tool.ty.rules]
61
+ invalid-argument-type = "warn"
62
+ too-many-positional-arguments = "warn"
70
63
 
@@ -888,8 +888,8 @@ class MediaFile:
888
888
  continue
889
889
  if pass2_stats["normalization_type"] == "dynamic":
890
890
  _logger.warning(
891
- "You specified linear normalization, but the loudnorm filter reverted to dynamic normalization. "
892
- "This may lead to unexpected results."
891
+ f"{self.input_file}: You specified linear normalization, but the loudnorm filter reverted to dynamic normalization. "
892
+ "This may lead to unexpected results. "
893
893
  "Consider your input settings, e.g. choose a lower target level or higher target loudness range."
894
894
  )
895
895
 
@@ -201,7 +201,7 @@ class AudioStream(MediaStream):
201
201
  return f"pcm_s{self.bit_depth}le"
202
202
  else:
203
203
  _logger.warning(
204
- f"Unsupported bit depth {self.bit_depth}, falling back to pcm_s16le"
204
+ f"{self.media_file.input_file}: Unsupported bit depth {self.bit_depth}, falling back to pcm_s16le"
205
205
  )
206
206
  return "pcm_s16le"
207
207
 
@@ -483,7 +483,7 @@ class AudioStream(MediaStream):
483
483
 
484
484
  if float(self.loudness_statistics["ebu_pass1"]["input_i"]) > 0:
485
485
  _logger.warning(
486
- "Input file had measured input loudness greater than zero "
486
+ f"{self.media_file.input_file}: Input file had measured input loudness greater than zero "
487
487
  f"({self.loudness_statistics['ebu_pass1']['input_i']}), capping at 0"
488
488
  )
489
489
  self.loudness_statistics["ebu_pass1"]["input_i"] = 0
@@ -497,7 +497,7 @@ class AudioStream(MediaStream):
497
497
  input_lra = self.loudness_statistics["ebu_pass1"]["input_lra"]
498
498
  if input_lra < 1 or input_lra > 50:
499
499
  _logger.warning(
500
- "Input file had measured loudness range outside of [1,50] "
500
+ f"{self.media_file.input_file}: Input file had measured loudness range outside of [1,50] "
501
501
  f"({input_lra}), capping to allowed range"
502
502
  )
503
503
 
@@ -527,7 +527,7 @@ class AudioStream(MediaStream):
527
527
  and not will_use_dynamic_mode
528
528
  ):
529
529
  _logger.warning(
530
- f"Input file had loudness range of {self.loudness_statistics['ebu_pass1']['input_lra']}. "
530
+ f"{self.media_file.input_file}: Input file had loudness range of {self.loudness_statistics['ebu_pass1']['input_lra']}. "
531
531
  f"This is larger than the loudness range target ({self.media_file.ffmpeg_normalize.loudness_range_target}). "
532
532
  "Normalization will revert to dynamic mode. Choose a higher target loudness range if you want linear normalization. "
533
533
  "Alternatively, use the --keep-loudness-range-target or --keep-lra-above-loudness-range-target option to keep the target loudness range from "
@@ -552,7 +552,7 @@ class AudioStream(MediaStream):
552
552
  if safe_target < self.ffmpeg_normalize.target_level:
553
553
  target_level = safe_target
554
554
  _logger.warning(
555
- f"Using loudness target {target_level} because --auto-lower-loudness-target given.",
555
+ f"{self.media_file.input_file}: Using loudness target {target_level} because --auto-lower-loudness-target given.",
556
556
  )
557
557
 
558
558
  stats = self.loudness_statistics["ebu_pass1"]
@@ -654,6 +654,8 @@ class AudioStream(MediaStream):
654
654
 
655
655
  clip_amount = self.loudness_statistics["max"] + adjustment
656
656
  if clip_amount > 0:
657
- _logger.warning(f"Adjusting will lead to clipping of {clip_amount} dB")
657
+ _logger.warning(
658
+ f"{self.media_file.input_file}: Adjusting will lead to clipping of {clip_amount} dB"
659
+ )
658
660
 
659
661
  return f"volume={adjustment}dB"