You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/08/26 08:25:41 UTC

[GitHub] [tvm] chengven027-intellif commented on a diff in pull request #12555: [frontend][onnx]fix pad constant value is none

chengven027-intellif commented on code in PR #12555:
URL: https://github.com/apache/tvm/pull/12555#discussion_r955791479


##########
tests/python/frontend/onnx/test_forward.py:
##########
@@ -2027,6 +2027,7 @@ def verify_pad_v11(indata, pads, mode="constant", value=0.0):
     verify_pad_v11(np.random.randn(2, 2).astype(np.float32), [0, 1, 0, 0], "constant", 0.0)
     verify_pad_v11(np.random.randn(2, 3).astype(np.float32), [1, 0, 0, 1], "constant", 0.0)
     verify_pad_v11(np.random.randn(3, 2).astype(np.float32), [0, 0, 1, 0], "constant", 5.0)
+    verify_pad_v11(np.random.randn(3, 2).astype(np.float32), [0, 0, 1, 0], "constant", False)

Review Comment:
   No, But I can't add a test case with `None`.
   First, In the doc `test_forward.py   test_pad`, The `value` is a default number,can't set `None`.
   `def verify_pad_v11(indata, pads, mode="constant", value=0.0)`
   Then, the input node 'constant_value' is a `TensorProto.FLOAT`. not `None` too.
   Can you give me some suggestions to add a test case with 'None'?  Thanks very much. 
     



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org