We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a8078bb commit a34d85dCopy full SHA for a34d85d
python/paddle/fluid/tests/unittests/test_egr_string_tensor_api.py
@@ -41,7 +41,7 @@ def test_constructor_with_args(self):
41
self.assertEqual(ST2.name, "ST2")
42
self.assertEqual(ST2.shape, shape)
43
np.testing.assert_array_equal(
44
- ST2.numpy(), np.empty(shape, dtype=np.unicode_)
+ ST2.numpy(), np.empty(shape, dtype=np.str_)
45
)
46
47
ST3 = core.eager.StringTensor(self.str_arr, "ST3") # constructor 3
@@ -74,7 +74,7 @@ def test_constructor_with_kwargs(self):
74
self.assertEqual(ST1.name, "ST1")
75
self.assertEqual(ST1.shape, shape)
76
77
- ST1.numpy(), np.empty(shape, dtype=np.unicode_)
+ ST1.numpy(), np.empty(shape, dtype=np.str_)
78
79
80
ST2 = core.eager.StringTensor(self.str_arr, name="ST2") # constructor 3
0 commit comments