修改config备注

This commit is contained in:
YaoFANGUK
2023-12-28 10:59:46 +08:00
parent 0d12922b50
commit 125a06ca50
5 changed files with 154 additions and 136 deletions

View File

@@ -33,8 +33,8 @@ class STTNInpaint:
# 模型输入用的宽和高
self.model_input_width, self.model_input_height = 640, 120
# 2. 设置相连帧数
self.neighbor_stride = config.NEIGHBOR_STRIDE
self.ref_length = config.REFERENCE_LENGTH
self.neighbor_stride = config.STTN_NEIGHBOR_STRIDE
self.ref_length = config.STTN_REFERENCE_LENGTH
def __call__(self, input_frames: List[np.ndarray], input_mask: np.ndarray):
"""
@@ -229,7 +229,7 @@ class STTNVideoInpaint:
)
# 配置可在一次处理中加载的最大帧数
if clip_gap is None:
self.clip_gap = config.MAX_LOAD_NUM
self.clip_gap = config.STTN_MAX_LOAD_NUM
else:
self.clip_gap = clip_gap

View File

@@ -130,7 +130,7 @@ def get_ref_index(mid_neighbor_id, neighbor_ids, length, ref_stride=10, ref_num=
class VideoInpaint:
def __init__(self, sub_video_length=config.MAX_PROCESS_NUM, use_fp16=True):
def __init__(self, sub_video_length=config.PROPAINTER_MAX_LOAD_NUM, use_fp16=True):
self.device = get_device()
self.use_fp16 = use_fp16
self.use_half = True if self.use_fp16 else False