File tree 1 file changed +2
-2
lines changed
tensorflow-core/tensorflow-core-api/src/test/java/org/tensorflow
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 22
22
import org .tensorflow .ndarray .Shape ;
23
23
import org .tensorflow .op .Ops ;
24
24
import org .tensorflow .op .core .Placeholder ;
25
- import org .tensorflow .op .math .Sign ;
26
25
import org .tensorflow .proto .DataType ;
27
26
import org .tensorflow .types .TInt32 ;
28
27
@@ -100,7 +99,8 @@ public void createTensorInfoFromOperandWithUnknownShape() {
100
99
public void createTensorInfoFromOperandWithPartiallyUnknownShape () {
101
100
try (Graph g = new Graph ()) {
102
101
var tf = Ops .create (g );
103
- var placeholder = tf .placeholder (TInt32 .class , Placeholder .shape (Shape .of (Shape .UNKNOWN_SIZE , 10 )));
102
+ var shape = Shape .of (Shape .UNKNOWN_SIZE , 10 );
103
+ var placeholder = tf .placeholder (TInt32 .class , Placeholder .shape (shape ));
104
104
var tensorInfo = Signature .Builder .toTensorInfo (placeholder .asOutput ());
105
105
assertFalse (tensorInfo .getTensorShape ().getUnknownRank ());
106
106
assertEquals (2 , tensorInfo .getTensorShape ().getDimCount ());
You can’t perform that action at this time.
0 commit comments