Skip to content

Commit 4b2ee64

Browse files
committed
Add unsqueeze function to ndarray. Working with multiple batched images.
1 parent 9593115 commit 4b2ee64

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

examples/torch_model_loading/torch_load.chpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ proc main(args: [] string) {
1414
image = image.resize(224,224);
1515
writeln("Resized image: ", image.shape);
1616

17-
var batchedImage = image.unsqueeze(0);
17+
var batchedImage = ndarray.loadFrom(args[1],3,real(32)).unsqueeze(0);
1818
writeln("Batched image: ", batchedImage.shape);
1919

2020
batchedImage = batchedImage.resize(224,224);

0 commit comments

Comments
 (0)