masahi commented on a change in pull request #4584: [TOPI] add 3D upsampling Op.
URL: https://github.com/apache/incubator-tvm/pull/4584#discussion_r361622006
##########
File path: python/tvm/relay/op/nn/nn.py
##########
@@ -771,6 +771,58 @@ def upsampling(data,
return _make.upsampling(data, scale_h, scale_w, layout, method,
align_corners)
+def upsampling3d(data,
+ scale_d=1,
+ scale_h=1,
+ scale_w=1,
+ layout="NCDHW",
+ method="nearest_neighbor",
+ coordinate_transformation_mode="half_pixel"):
+ """3D Upsampling.
+
+ This operator takes data as input and does 3D scaling to the given scale
factor.
+ In the default case, where the data_layout is `NCDHW`
+ with data of shape (n, c, d, h, w)
+ out will have a shape (n, c, d*scale_d, h*scale_h, w*scale_w)
+
+ method indicates the algorithm to be used while calculating the out value
+ and method can be one of ("trilinear", "nearest_neighbor")
+
+ Parameters
+ ----------
+ data : tvm.relay.Expr
+ The input data to the operator.
+
+ scale_d : tvm.relay.Expr
+ The scale factor for depth upsampling.
+
+ scale_h : tvm.relay.Expr
+ The scale factor for height upsampling.
+
+ scale_w : tvm.relay.Expr
+ The scale factor for width upsampling.
+
+ layout : str, optional
+ Layout of the input.
+
+ method : str, optional
+ Scale method to used [nearest_neighbor, bilinear, bicubic].
Review comment:
update this doc
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services