hzfan commented on a change in pull request #15325: [Numpy] Numpy vstack
URL: https://github.com/apache/incubator-mxnet/pull/15325#discussion_r303276266
 
 

 ##########
 File path: tests/python/unittest/test_numpy_op.py
 ##########
 @@ -1162,6 +1162,63 @@ def test_np_broadcast_arrays():
     pass
 
 
+@with_seed()
[email protected]_np
+def test_np_vstack():
+    class TestVstack(HybridBlock):
+        def __init__(self):
+            super(TestVstack, self).__init__()
+        
+        def hybrid_forward(self, F, a, *args):
+            return F.np.vstack([a] + list(args))
+    
+    def g(data):
+        return _np.ones_like(data)
+
+    configs = [
+        ((), (), ()),
+        ((2), (2), (2)),
+        ((0), (0), (0)),
+        ((2, 2), (3, 2), (0, 2)),
+        ((2, 3), (1, 3), (4, 3)),
+        ((2, 2, 2), (3, 2, 2), (1, 2, 2)),
+        ((0, 1, 1), (4, 1, 1), (5, 1, 1)),
+        ((2), (0, 2), (2, 2))
+    ]
+    types = ['float16', 'float32', 'float64', 'int8', 'int32', 'int64']
+    for config in configs:
+        for hybridize in [True, False]:
+            for dtype in types:
+                print('config = {}'.format(config))
 
 Review comment:
   removed. @haojin2 

----------------------------------------------------------------
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

Reply via email to