auto-editor 24.30.1__py3-none-any.whl → 24.31.1__py3-none-any.whl

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.
auto_editor/__init__.py CHANGED
@@ -1,2 +1,2 @@
1
- __version__ = "24.30.1"
2
- version = "24w30a"
1
+ __version__ = "24.31.1"
2
+ version = "24w31a"
auto_editor/lang/palet.py CHANGED
@@ -620,42 +620,36 @@ def make_array(dtype: Sym, size: int, v: int = 0) -> np.ndarray:
620
620
  raise MyError(f"number too large to be converted to {dtype}")
621
621
 
622
622
 
623
- def minclip(oarr: BoolList, _min: int) -> BoolList:
623
+ def minclip(oarr: BoolList, _min: int, /) -> BoolList:
624
624
  arr = np.copy(oarr)
625
625
  mut_remove_small(arr, _min, replace=1, with_=0)
626
626
  return arr
627
627
 
628
628
 
629
- def mincut(oarr: BoolList, _min: int) -> BoolList:
629
+ def mincut(oarr: BoolList, _min: int, /) -> BoolList:
630
630
  arr = np.copy(oarr)
631
631
  mut_remove_small(arr, _min, replace=0, with_=1)
632
632
  return arr
633
633
 
634
634
 
635
- def maxclip(oarr: BoolList, _min: int) -> BoolList:
635
+ def maxclip(oarr: BoolList, _min: int, /) -> BoolList:
636
636
  arr = np.copy(oarr)
637
637
  mut_remove_large(arr, _min, replace=1, with_=0)
638
638
  return arr
639
639
 
640
640
 
641
- def maxcut(oarr: BoolList, _min: int) -> BoolList:
641
+ def maxcut(oarr: BoolList, _min: int, /) -> BoolList:
642
642
  arr = np.copy(oarr)
643
643
  mut_remove_large(arr, _min, replace=0, with_=1)
644
644
  return arr
645
645
 
646
646
 
647
- def margin(a: int, b: Any, c: Any = None) -> BoolList:
648
- if c is None:
649
- check_args("margin", [a, b], (2, 2), (is_int, is_boolarr))
650
- oarr = b
651
- start, end = a, a
652
- else:
653
- check_args("margin", [a, b, c], (3, 3), (is_int, is_int, is_boolarr))
654
- oarr = c
655
- start, end = a, b
656
-
647
+ def margin(oarr: BoolList, start: int, end: int | None = None, /) -> BoolList:
657
648
  arr = np.copy(oarr)
658
- mut_margin(arr, start, end)
649
+ if end is None:
650
+ mut_margin(arr, start, start)
651
+ else:
652
+ mut_margin(arr, start, end)
659
653
  return arr
660
654
 
661
655
 
@@ -1741,6 +1735,8 @@ env.update({
1741
1735
  "round": Proc("round", round, (1, 1), is_real),
1742
1736
  "max": Proc("max", lambda *v: max(v), (1, None), is_real),
1743
1737
  "min": Proc("min", lambda *v: min(v), (1, None), is_real),
1738
+ "max-seq": Proc("max-seq", max, (1, 1), is_sequence),
1739
+ "min-seq": Proc("min-seq", min, (1, 1), is_sequence),
1744
1740
  "mod": Proc("mod", mod, (2, 2), is_int),
1745
1741
  "modulo": Proc("modulo", mod, (2, 2), is_int),
1746
1742
  # symbols
@@ -1796,7 +1792,7 @@ env.update({
1796
1792
  "bool-array": Proc(
1797
1793
  "bool-array", lambda *a: np.array(a, dtype=np.bool_), (1, None), is_nat
1798
1794
  ),
1799
- "margin": Proc("margin", margin, (2, 3)),
1795
+ "margin": Proc("margin", margin, (2, 3), is_boolarr, is_int),
1800
1796
  "mincut": Proc("mincut", mincut, (2, 2), is_boolarr, is_nat),
1801
1797
  "minclip": Proc("minclip", minclip, (2, 2), is_boolarr, is_nat),
1802
1798
  "maxcut": Proc("maxcut", maxcut, (2, 2), is_boolarr, is_nat),
@@ -185,6 +185,8 @@ def display_str(val: object) -> str:
185
185
  return f"{val.real}{join}{val.imag}i"
186
186
  if type(val) is np.bool_:
187
187
  return "1" if val else "0"
188
+ if type(val) is np.float64 or type(val) is np.float32:
189
+ return f"{float(val)}"
188
190
  if type(val) is Fraction:
189
191
  return f"{val.numerator}/{val.denominator}"
190
192
 
auto_editor/output.py CHANGED
@@ -227,7 +227,7 @@ def mux_quality_media(
227
227
  cmd.extend(["-color_range", f"{color_range}"])
228
228
  if colorspace in (0, 1) or (colorspace >= 3 and colorspace < 16):
229
229
  cmd.extend(["-colorspace", f"{colorspace}"])
230
- if color_prim in (0, 1) or (color_prim >= 4 and color_prim < 17):
230
+ if color_prim == 1 or (color_prim >= 4 and color_prim < 17):
231
231
  cmd.extend(["-color_primaries", f"{color_prim}"])
232
232
  if color_trc == 1 or (color_trc >= 4 and color_trc < 22):
233
233
  cmd.extend(["-color_trc", f"{color_trc}"])
@@ -628,11 +628,11 @@ def main(sys_args: list[str] | None = None):
628
628
  ("(string #\\a #\\b)", "ab"),
629
629
  ("(string #\\a #\\b #\\c)", "abc"),
630
630
  (
631
- "(margin 0 (bool-array 0 0 0 1 0 0 0))",
631
+ "(margin (bool-array 0 0 0 1 0 0 0) 0)",
632
632
  np.array([0, 0, 0, 1, 0, 0, 0], dtype=np.bool_),
633
633
  ),
634
634
  (
635
- "(margin -2 2 (bool-array 0 0 1 1 0 0 0))",
635
+ "(margin (bool-array 0 0 1 1 0 0 0) -2 2)",
636
636
  np.array([0, 0, 0, 0, 1, 1, 0], dtype=np.bool_),
637
637
  ),
638
638
  ("(equal? 3 3)", True),
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: auto-editor
3
- Version: 24.30.1
3
+ Version: 24.31.1
4
4
  Summary: Auto-Editor: Effort free video editing!
5
5
  Author-email: WyattBlue <wyattblue@auto-editor.com>
6
6
  License: Unlicense
@@ -1,11 +1,11 @@
1
- auto_editor/__init__.py,sha256=2eo38rUAsDC2UUJAIJ4AZoh26SJrz93bjEMG1PMKUnQ,43
1
+ auto_editor/__init__.py,sha256=fE5TG5waO4ycosUA6qLxyCtCX3by5wAgPN6aiaae268,43
2
2
  auto_editor/__main__.py,sha256=nkb8N_bxF_qld53LWo4c6Y0n9NDRdsPfANpVF1RD1cQ,9863
3
3
  auto_editor/analyze.py,sha256=6siPLoYwEjvbAzPfKZWDEcqtGXIM8n9qNveyCCYLAgI,11769
4
4
  auto_editor/edit.py,sha256=yZFLoWqfC2QFEdibp7AlKXMRB-6jHwNDpTW2SlN-4Is,11325
5
5
  auto_editor/ffwrapper.py,sha256=jga7-HbQnC4w21qZk4aY4kwLT7UPqkGn6NJPFM5Qssc,7811
6
6
  auto_editor/help.py,sha256=BFiP7vBz42TUzum4-zaQIrV1OY7kHeN0pe0MPE0T5xw,7997
7
7
  auto_editor/make_layers.py,sha256=AzfxRkm9ZFjeVwdh3jFT_5_YvVaUMtphVKDtIaDI5bo,8900
8
- auto_editor/output.py,sha256=OpZG3SvDRumKoU-fZOA-8-hc9pO_uBdO3WTNhDO9LHM,8065
8
+ auto_editor/output.py,sha256=n2WMXS1oRJi3RbtnloYTlPROqU9qy-5BVW3l4ZnPNHo,8060
9
9
  auto_editor/preview.py,sha256=CVKtSjcX1dNjbBgsD9PTbRBwRV6dxBLkJ_VIkkBuTUY,3032
10
10
  auto_editor/timeline.py,sha256=JwcS-8AS5vsoTL_m03aosYijScQef4AGa2lyutQ8wbI,7069
11
11
  auto_editor/validate_input.py,sha256=JQt7J5xOBJDp6lnd2sQptpYhf7Z_hyxNEzLsE9E7LKU,2596
@@ -20,10 +20,10 @@ auto_editor/formats/utils.py,sha256=GIZw28WHuCIaZ_zMI0v6Kxbq0QaIpbLsdSegdYwQxQ8,
20
20
  auto_editor/lang/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
21
21
  auto_editor/lang/json.py,sha256=OsNcYlfEj8ZLlzLK-gkLcrCCKI7mJz9rpe-6XLr4f9U,9231
22
22
  auto_editor/lang/libmath.py,sha256=z33A161Oe6vYYK7R6pgYjdZZe63dQkN38Qf36TL3prg,847
23
- auto_editor/lang/palet.py,sha256=ZlQsKS5TEUDDiPQSXMSXcdoYYibcv6nwwe372IVdQkw,59839
23
+ auto_editor/lang/palet.py,sha256=MIyI0Os0wCgUZaOkyiL-KPb2Bd7JwZtbI26H4m89lwQ,59823
24
24
  auto_editor/lib/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
25
25
  auto_editor/lib/contracts.py,sha256=HxWWMU63_6nKsdIXCDKnlWaYzS0dpN-H3uwCuzZALaM,7353
26
- auto_editor/lib/data_structs.py,sha256=EXNcdMsdmZxMRlpbXmIbRoC-YfGzvPZi7EdBQGwvpP4,6887
26
+ auto_editor/lib/data_structs.py,sha256=xyB6aEcpdB9NNWp_dU3d2ds5Z8zOfHXNX4mNQLh2pNw,6977
27
27
  auto_editor/lib/err.py,sha256=UlszQJdzMZwkbT8x3sY4GkCV_5x9yrd6uVVUzvA8iiI,35
28
28
  auto_editor/render/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
29
29
  auto_editor/render/audio.py,sha256=pUhD4rQZfUnyzKgpuxNxl_2CUGwbkAWo2356HUAW7VM,8835
@@ -36,7 +36,7 @@ auto_editor/subcommands/levels.py,sha256=ymHwAp2l7HScmdTtNAPDEeDfRVY_rRPRigUCDYx
36
36
  auto_editor/subcommands/palet.py,sha256=tbQoRWoT4jR3yu0etGApfprM-oQgXIjC-rIY-QG3nM0,655
37
37
  auto_editor/subcommands/repl.py,sha256=gEVmZduWwnumMe4GLHi72C_IbmdscYwiz7mjigU97Qk,3300
38
38
  auto_editor/subcommands/subdump.py,sha256=af_XBf7kaevqHn1A71z8C-7x8pS5WKD9FE_ugkCw6rk,665
39
- auto_editor/subcommands/test.py,sha256=UcpJp-PMcoUyz6LDD4y2V6EQ9w1ed66fPZr4GpzJReg,25050
39
+ auto_editor/subcommands/test.py,sha256=kafifZmZJrxevehVOyFSObmdNGpSg9HIJPhc731Gayk,25050
40
40
  auto_editor/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
41
41
  auto_editor/utils/bar.py,sha256=RJqkJ8gNr8op_Z-2hh48ExjSonmTPX-RshctK_itv14,3988
42
42
  auto_editor/utils/chunks.py,sha256=J-eGKtEz68gFtRrj1kOSgH4Tj_Yz6prNQ7Xr-d9NQJw,52
@@ -47,9 +47,9 @@ auto_editor/utils/func.py,sha256=H38xO6Wxg1TZILVrx-nCowCzj_mqBUtJuOFp4DV3Hsc,484
47
47
  auto_editor/utils/log.py,sha256=ry-C92PRkJ-c8PQYIs1imk1qigDYfsCoLBYK6CQSP7I,2844
48
48
  auto_editor/utils/subtitle_tools.py,sha256=TjjVPiT8bWzZJcrZjF7ddpgfIsVkLE4LyxXzBswHAGU,693
49
49
  auto_editor/utils/types.py,sha256=zWbU_VkcdP4yHHzKyaSiXu560n5U53i0x5SPkUDsCZU,11570
50
- auto_editor-24.30.1.dist-info/LICENSE,sha256=yiq99pWITHfqS0pbZMp7cy2dnbreTuvBwudsU-njvIM,1210
51
- auto_editor-24.30.1.dist-info/METADATA,sha256=6PQ4JL2l2YioyyknShGetU4rsQ2Czp8EJHZzMsbo7dA,6138
52
- auto_editor-24.30.1.dist-info/WHEEL,sha256=Wyh-_nZ0DJYolHNn1_hMa4lM7uDedD_RGVwbmTjyItk,91
53
- auto_editor-24.30.1.dist-info/entry_points.txt,sha256=-H7zdTw4MqnAcwrN5xTNkGIhzZtJMxS9r6lTMeR9-aA,240
54
- auto_editor-24.30.1.dist-info/top_level.txt,sha256=ky1HUkqq9i034c4CUU_0wBw0xZsxxyGEak1eTbdvpyA,12
55
- auto_editor-24.30.1.dist-info/RECORD,,
50
+ auto_editor-24.31.1.dist-info/LICENSE,sha256=yiq99pWITHfqS0pbZMp7cy2dnbreTuvBwudsU-njvIM,1210
51
+ auto_editor-24.31.1.dist-info/METADATA,sha256=QhgrsPDCOesLJsC420BKailNLFnrpJj6ykc3bGXgPmg,6138
52
+ auto_editor-24.31.1.dist-info/WHEEL,sha256=R0nc6qTxuoLk7ShA2_Y-UWkN8ZdfDBG2B6Eqpz2WXbs,91
53
+ auto_editor-24.31.1.dist-info/entry_points.txt,sha256=-H7zdTw4MqnAcwrN5xTNkGIhzZtJMxS9r6lTMeR9-aA,240
54
+ auto_editor-24.31.1.dist-info/top_level.txt,sha256=ky1HUkqq9i034c4CUU_0wBw0xZsxxyGEak1eTbdvpyA,12
55
+ auto_editor-24.31.1.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (71.1.0)
2
+ Generator: setuptools (72.1.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5