lhutton1 commented on code in PR #13931:
URL: https://github.com/apache/tvm/pull/13931#discussion_r1099944386
##########
src/relay/backend/contrib/ethosn/codegen.cc:
##########
@@ -190,6 +190,19 @@ void InferTensorsVisitor::VisitExpr_(const CallNode* cn) {
}
}
+void ConstructNetworkVisitor::VisitExpr_(const ConstantNode* cn) {
+ Constant constant = GetRef<Constant>(cn);
+ std::cout << "Traversing constant..." << std::endl;
Review Comment:
Nit: remove prints
##########
tests/python/contrib/test_ethosn/test_addition.py:
##########
@@ -173,6 +173,61 @@ def test_addition_both_inputs_constants(
assert "qnn.add" not in mod.astext(False)
+@requires_ethosn
[email protected]("dtype", ["uint8", "int8"])
[email protected](
+ "lhs_shape,lhs_is_constant,rhs_shape,rhs_is_constant",
+ [
+ ((1, 4, 4, 8), False, (1, 4, 4, 8), True),
+ ((1, 16, 12, 4), True, (1, 16, 12, 4), False),
Review Comment:
It might also be good to test broadcast shapes not covered by
`qnn_add_to_depthwise` e.g. ((1, 4, 4, 8), False, (1, 1, 4, 8), True), I
believe this should be supported?
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]