|
4 | 4 | Date: 2024-02-29 |
5 | 5 | version: |
6 | 6 | LastEditors: Dan64 |
7 | | -LastEditTime: 2025-02-12 |
| 7 | +LastEditTime: 2025-02-14 |
8 | 8 | ------------------------------------------------------------------------------- |
9 | 9 | Description: |
10 | 10 | ------------------------------------------------------------------------------- |
@@ -621,8 +621,9 @@ def HAVC_deepex(clip: vs.VideoNode = None, clip_ref: vs.VideoNode = None, method |
621 | 621 | # ------------------------------------------------------------------------------------------------------------------ |
622 | 622 | # SPECIAL MANAGEMENT OF DeepRemaster (ex_model = 2) |
623 | 623 | if method in (0, 1, 2) and ex_model == 2: |
624 | | - return HAVC_restore_video(clip, clip_ref, method, render_speed, ex_model, ref_merge, ref_weight, sc_threshold, |
625 | | - sc_frequency, ref_norm, max_memory_frames, render_vivid, encode_mode) |
| 624 | + HAVC_LogMessage(MessageType.EXCEPTION, |
| 625 | + "HAVC_deepex: DeepRemaster cannot be used with methods: 0, 1, 2 (HAVC)") |
| 626 | + |
626 | 627 | # SPECIAL MANAGEMENT OF METHOD=(5,6) |
627 | 628 | if method in (5, 6): |
628 | 629 | return HAVC_restore_video(clip, clip_ref, method, render_speed, ex_model, ref_merge, ref_weight, ref_thresh, |
@@ -835,8 +836,8 @@ def HAVC_restore_video(clip: vs.VideoNode = None, clip_ref: vs.VideoNode = None, |
835 | 836 | # disable packages warnings |
836 | 837 | disable_warnings() |
837 | 838 |
|
838 | | - if method not in (0, 1, 2, 5, 6): |
839 | | - HAVC_LogMessage(MessageType.EXCEPTION, "HAVC: Video restore is supported on with methods: 0, 1, 2, 5, 6") |
| 839 | + if method not in (5, 6): |
| 840 | + HAVC_LogMessage(MessageType.EXCEPTION, "HAVC: Video restore is supported only with methods: 5, 6") |
840 | 841 |
|
841 | 842 | if not isinstance(clip, vs.VideoNode): |
842 | 843 | HAVC_LogMessage(MessageType.EXCEPTION, "HAVC_deepex: this is not a clip") |
@@ -1484,29 +1485,6 @@ def HAVC_export_reference_frames(clip: vs.VideoNode, sc_framedir: str = "./", re |
1484 | 1485 | ------------------------------------------------------------------------------------------------------------------------ |
1485 | 1486 | """ |
1486 | 1487 |
|
1487 | | - |
1488 | | -def _colorizer_stable(clip: vs.VideoNode = None, do_model: int = 0, deoldify_rf: int = 22, |
1489 | | - mweight: float = 0.5) -> vs.VideoNode: |
1490 | | - clip_colored = HAVC_colorizer(clip=clip, method=0, deoldify_p=[do_model, deoldify_rf, 1, 0]) |
1491 | | - |
1492 | | - # the adjustment force DeepRemaster to return a clip brown colored |
1493 | | - clip_ref = havc_utils.adjust_rgb(rgb=clip_colored, rb=30.0, gb=10.0, bb=-20.0) |
1494 | | - |
1495 | | - clip_brown = HAVC_restore_video(clip, clip_ref, render_speed="medium", ex_model=2, ref_merge=0, ref_thresh=0.10, |
1496 | | - ref_freq=5, max_memory_frames=6, render_vivid=False, ref_norm=False) |
1497 | | - |
1498 | | - # adjusting output color from: RGB24 to YUV420P8 |
1499 | | - clip_colored = vs.core.resize.Bicubic(clip=clip_colored, format=vs.YUV420P8, matrix_s="709", range_s="full") |
1500 | | - clip_brown = vs.core.resize.Bicubic(clip=clip_brown, format=vs.YUV420P8, matrix_s="709", range_s="full") |
1501 | | - |
1502 | | - clip_stable = vs.core.std.Merge(clipa=clip_brown, clipb=clip_colored, weight=mweight) |
1503 | | - |
1504 | | - # adjusting output color from: YUV420P8 to RGB24 |
1505 | | - clip_stable = core.resize.Bicubic(clip=clip_stable, format=vs.RGB24, matrix_in_s="709", range_s="full") |
1506 | | - |
1507 | | - return clip_stable |
1508 | | - |
1509 | | - |
1510 | 1488 | """ |
1511 | 1489 | ------------------------------------------------------------------------------- |
1512 | 1490 | Author: Dan64 |
|
0 commit comments