diff --git a/inference_codeformer.py b/inference_codeformer.py index 65ae10e0..0de7b48f 100644 --- a/inference_codeformer.py +++ b/inference_codeformer.py @@ -38,7 +38,8 @@ if not torch.cuda.is_available(): # CPU import warnings warnings.warn('The unoptimized RealESRGAN is slow on CPU. We do not use it. ' - 'If you really want to use it, please modify the corresponding codes.') + 'If you really want to use it, please modify the corresponding codes.', + category=RuntimeWarning) bg_upsampler = None else: from basicsr.archs.rrdbnet_arch import RRDBNet