We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e494084 commit aed7147Copy full SHA for aed7147
com.ibm.wala.cast.python.test/data/tf2_test_add.py
@@ -6,6 +6,19 @@ def f(a):
6
7
8
x = [1, 2, 3, 4, 5]
9
+assert isinstance(x, list)
10
+assert all(isinstance(i, int) for i in x)
11
+assert tf.convert_to_tensor(x).dtype == tf.int32
12
+assert tf.convert_to_tensor(x).shape == (5,)
13
+
14
y = 1
15
+assert isinstance(y, int)
16
+assert tf.convert_to_tensor(y).dtype == tf.int32
17
+assert tf.convert_to_tensor(y).shape == ()
18
19
z = tf.add(x, y)
20
+assert isinstance(z, tf.Tensor)
21
+assert z.dtype == tf.int32
22
+assert z.shape == (5,)
23
24
f(z)
0 commit comments