Skip to content

Commit 3b4df57

Browse files
scripts/vsmlrt.py: suppress warnings in fp16 conversion
1 parent 8b71341 commit 3b4df57

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

scripts/vsmlrt.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
__version__ = "3.22.27"
1+
__version__ = "3.22.28"
22

33
__all__ = [
44
"Backend", "BackendV2",
@@ -29,6 +29,7 @@
2929
import tempfile
3030
import time
3131
import typing
32+
import warnings
3233
import zlib
3334

3435
import vapoursynth as vs
@@ -2388,7 +2389,9 @@ def tensorrt_rtx(
23882389
import onnx
23892390
from onnxconverter_common.float16 import convert_float_to_float16
23902391
model = onnx.load(network_path)
2391-
model = convert_float_to_float16(model, keep_io_types=not fp16_io)
2392+
with warnings.catch_warnings():
2393+
warnings.simplefilter("ignore")
2394+
model = convert_float_to_float16(model, keep_io_types=not fp16_io)
23922395
onnx.save(model, fp16_network_path)
23932396
network_path = fp16_network_path
23942397
elif fp16_io:

0 commit comments

Comments
 (0)