Skip to content

Commit a46fb8f

Browse files
committed
Test idempotency missing from the previous commit
1 parent 84a2bce commit a46fb8f

File tree

1 file changed

+28
-28
lines changed

1 file changed

+28
-28
lines changed

test/operations/hello_world_op.ml

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ let%expect_test "Pointwise multiplication dims 1" =
3333
Train.printf ~here:[%here] ~with_code:false ~with_grad:false y;
3434
[%expect
3535
{|
36-
HERE: test/operations/hello_world_op.ml:34:21
36+
HERE: test/operations/hello_world_op.ml:33:21
3737
┌────────────────────┐
3838
│[3]: *._y shape 0:1
3939
│┌┬─────────┐ │
@@ -64,7 +64,7 @@ let%expect_test "Matrix multiplication dims 1x1" =
6464
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hey;
6565
[%expect
6666
{|
67-
HERE: test/operations/hello_world_op.ml:66:21
67+
HERE: test/operations/hello_world_op.ml:64:21
6868
┌────────────────────────┐
6969
│[0]: hey shape 1:1->0:1
7070
│┌──────┬──────┐ │
@@ -77,7 +77,7 @@ let%expect_test "Matrix multiplication dims 1x1" =
7777
Train.printf ~here:[%here] ~with_code:false ~with_grad:false y;
7878
[%expect
7979
{|
80-
HERE: test/operations/hello_world_op.ml:79:21
80+
HERE: test/operations/hello_world_op.ml:77:21
8181
┌───────────────────┐
8282
│[6]: +_y shape 0:1
8383
│┌┬─────────┐ │
@@ -99,10 +99,10 @@ let%expect_test "Print tensor too early" =
9999
Tensor.print ~here:[%here] ~force:false ~with_code:false ~with_grad:false `Inline b;
100100
[%expect
101101
{|
102-
HERE: test/operations/hello_world_op.ml:100:21
102+
HERE: test/operations/hello_world_op.ml:98:21
103103
[0]: 1,2,3,4_a shape 0:4| <not-in-yet>
104104

105-
HERE: test/operations/hello_world_op.ml:101:21
105+
HERE: test/operations/hello_world_op.ml:99:21
106106
[1]: 2,3,4,5_b shape 0:4| <not-in-yet>
107107
|}];
108108
let%op c = a *. b in
@@ -111,7 +111,7 @@ let%expect_test "Print tensor too early" =
111111
Train.printf ~here:[%here] c;
112112
[%expect
113113
{|
114-
HERE: test/operations/hello_world_op.ml:113:21
114+
HERE: test/operations/hello_world_op.ml:111:21
115115
┌─────────────────────────────────┐
116116
│[2]: *._c shape 0:4| │
117117
│┌┬──────────────────────────────┐│
@@ -142,7 +142,7 @@ let%expect_test "Print constant tensor" =
142142
Train.printf ~here:[%here] ~with_code:false ~with_grad:false ~style:`Inline hey;
143143
[%expect
144144
{|
145-
HERE: test/operations/hello_world_op.ml:144:21
145+
HERE: test/operations/hello_world_op.ml:142:21
146146
[0]: 1,2,3,4,5..._hey shape 1:3->0:2 [
147147
1.00 , 2.00 , 3.00
148148
; 4.00 , 5.00 , 6.00
@@ -151,7 +151,7 @@ let%expect_test "Print constant tensor" =
151151
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hey;
152152
[%expect
153153
{|
154-
HERE: test/operations/hello_world_op.ml:153:21
154+
HERE: test/operations/hello_world_op.ml:151:21
155155
┌─────────────────────────────────────┐
156156
│[0]: 1,2,3,4,5..._hey shape 1:3->0:2
157157
│┌──────┬──────────────────┐ │
@@ -167,7 +167,7 @@ let%expect_test "Print constant tensor" =
167167
Train.printf ~here:[%here] ~with_code:false ~with_grad:false ~style:`Inline hoo;
168168
[%expect
169169
{|
170-
HERE: test/operations/hello_world_op.ml:169:21
170+
HERE: test/operations/hello_world_op.ml:167:21
171171
[1]: 1,2,3,4,5..._hoo shape 0:2|1:3 [|
172172
[ 1.00 ; 2.00 ; 3.00 ]
173173
; [ 4.00 ; 5.00 ; 6.00 ]
@@ -176,7 +176,7 @@ let%expect_test "Print constant tensor" =
176176
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hoo;
177177
[%expect
178178
{|
179-
HERE: test/operations/hello_world_op.ml:178:21
179+
HERE: test/operations/hello_world_op.ml:176:21
180180
┌────────────────────────────────────┐
181181
│[1]: 1,2,3,4,5..._hoo shape 0:2|1:3
182182
│┌──────┬──────────────────┐ │
@@ -199,7 +199,7 @@ let%expect_test "Print constant tensor" =
199199
Train.printf ~here:[%here] ~with_code:false ~with_grad:false @@ hey2;
200200
[%expect
201201
{|
202-
HERE: test/operations/hello_world_op.ml:201:21
202+
HERE: test/operations/hello_world_op.ml:199:21
203203
┌────────────────────────────────────────────────────────────────┐
204204
│[2]: 1,2,3,4,5..._hey2 shape 1:2,2:3->0:4
205205
│┌──────┬───────────────────────────┬───────────────────────────┐│
@@ -216,7 +216,7 @@ let%expect_test "Print constant tensor" =
216216
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hey2;
217217
[%expect
218218
{|
219-
HERE: test/operations/hello_world_op.ml:218:21
219+
HERE: test/operations/hello_world_op.ml:216:21
220220
┌────────────────────────────────────────────────────────────────┐
221221
│[2]: 1,2,3,4,5..._hey2 shape 1:2,2:3->0:4
222222
│┌──────┬───────────────────────────┬───────────────────────────┐│
@@ -242,7 +242,7 @@ let%expect_test "Print constant tensor" =
242242
Train.printf ~here:[%here] ~with_code:false ~with_grad:false ~style:`Inline hoo2;
243243
[%expect
244244
{|
245-
HERE: test/operations/hello_world_op.ml:244:21
245+
HERE: test/operations/hello_world_op.ml:242:21
246246
[3]: 1,2,3,4,5..._hoo2 shape 0:4|1:2,2:3 [|
247247
[ [ 1.00 ; 2.00 ; 3.00 ] ; [ 4.00 ; 5.00 ; 6.00 ] ]
248248
; [ [ 7.00 ; 8.00 ; 9.00 ] ; [ 10.00 ; 11.00 ; 12.00 ] ]
@@ -253,7 +253,7 @@ let%expect_test "Print constant tensor" =
253253
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hoo2;
254254
[%expect
255255
{|
256-
HERE: test/operations/hello_world_op.ml:255:21
256+
HERE: test/operations/hello_world_op.ml:253:21
257257
┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
258258
│[3]: 1,2,3,4,5..._hoo2 shape 0:4|1:2,2:3
259259
│┌──────┬──────────────────┬───────────────────────────┬───────────────────────────┬───────────────────────────┐│
@@ -277,7 +277,7 @@ let%expect_test "Print constant tensor" =
277277
Train.printf ~here:[%here] ~with_code:false ~with_grad:false ~style:`Inline heyhoo;
278278
[%expect
279279
{|
280-
HERE: test/operations/hello_world_op.ml:279:21
280+
HERE: test/operations/hello_world_op.ml:277:21
281281
[4]: 1,2,3,4,5..._heyhoo shape 0:4,1:2|2:3 [|
282282
[| [ 1.00 ; 2.00 ; 3.00 ] ; [ 4.00 ; 5.00 ; 6.00 ] |]
283283
; [| [ 7.00 ; 8.00 ; 9.00 ] ; [ 10.00 ; 11.00 ; 12.00 ] |]
@@ -288,7 +288,7 @@ let%expect_test "Print constant tensor" =
288288
Train.printf ~here:[%here] ~with_code:false ~with_grad:false heyhoo;
289289
[%expect
290290
{|
291-
HERE: test/operations/hello_world_op.ml:290:21
291+
HERE: test/operations/hello_world_op.ml:288:21
292292
┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
293293
│[4]: 1,2,3,4,5..._heyhoo shape 0:4,1:2|2:3
294294
│┌──────┬──────────────────┬───────────────────────────┬───────────────────────────┬───────────────────────────┐│
@@ -312,7 +312,7 @@ let%expect_test "Print constant tensor" =
312312
Train.printf ~here:[%here] ~with_code:false ~with_grad:false ~style:`Inline heyhoo2;
313313
[%expect
314314
{|
315-
HERE: test/operations/hello_world_op.ml:314:21
315+
HERE: test/operations/hello_world_op.ml:312:21
316316
[5]: 1,31,2,32,3..._heyhoo2 shape 0:4,1:2|2:3,3:2 [|
317317
[|
318318
[ [ 1.00 ; 31.00 ] ; [ 2.00 ; 32.00 ] ; [ 3.00 ; 33.00 ] ]
@@ -335,7 +335,7 @@ let%expect_test "Print constant tensor" =
335335
Train.printf ~here:[%here] ~with_code:false ~with_grad:false heyhoo2;
336336
[%expect
337337
{|
338-
HERE: test/operations/hello_world_op.ml:337:21
338+
HERE: test/operations/hello_world_op.ml:335:21
339339
┌──────────────────────────────────────────────────┐
340340
│[5]: 1,31,2,32,3..._heyhoo2 shape 0:4,1:2|2:3,3:2
341341
│┌──────┬──────────────────┬──────────────────┐ │
@@ -376,7 +376,7 @@ let%expect_test "Print constant tensor" =
376376
Train.printf ~here:[%here] ~with_code:false ~with_grad:false ~style:`Inline heyhoo3;
377377
[%expect
378378
{|
379-
HERE: test/operations/hello_world_op.ml:378:21
379+
HERE: test/operations/hello_world_op.ml:376:21
380380
[6]: 1,31,2,32,3..._heyhoo3 shape 0:2,1:2|2:2,3:3,4:2 [|
381381
[|
382382
[
@@ -403,7 +403,7 @@ let%expect_test "Print constant tensor" =
403403
Train.printf ~here:[%here] ~with_code:false ~with_grad:false heyhoo3;
404404
[%expect
405405
{|
406-
HERE: test/operations/hello_world_op.ml:405:21
406+
HERE: test/operations/hello_world_op.ml:403:21
407407
┌──────────────────────────────────────────────────────┐
408408
│[6]: 1,31,2,32,3..._heyhoo3 shape 0:2,1:2|2:2,3:3,4:2
409409
│┌──────┬───────────────┬──────────────────┐ │
@@ -449,7 +449,7 @@ let%expect_test "Print constant tensor" =
449449
Train.printf ~here:[%here] ~with_code:false ~with_grad:false ~style:`Inline heyhoo4;
450450
[%expect
451451
{|
452-
HERE: test/operations/hello_world_op.ml:451:21
452+
HERE: test/operations/hello_world_op.ml:449:21
453453
[7]: 1,31,2,32,3..._heyhoo4 shape 0:2|4:2->1:2,2:2,3:3 [|
454454
[
455455
[
@@ -476,7 +476,7 @@ let%expect_test "Print constant tensor" =
476476
Train.printf ~here:[%here] ~with_code:false ~with_grad:false heyhoo4;
477477
[%expect
478478
{|
479-
HERE: test/operations/hello_world_op.ml:478:21
479+
HERE: test/operations/hello_world_op.ml:476:21
480480
┌───────────────────────────────────────────────────────┐
481481
│[7]: 1,31,2,32,3..._heyhoo4 shape 0:2|4:2->1:2,2:2,3:3
482482
│┌──────┬───────────────┬──────────────────┐ │
@@ -526,7 +526,7 @@ let%expect_test "Matrix multiplication dims 2x3" =
526526
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hey;
527527
[%expect
528528
{|
529-
HERE: test/operations/hello_world_op.ml:529:21
529+
HERE: test/operations/hello_world_op.ml:526:21
530530
┌────────────────────────┐
531531
│[0]: hey shape 1:2->0:3
532532
│┌──────┬────────────┐ │
@@ -541,7 +541,7 @@ let%expect_test "Matrix multiplication dims 2x3" =
541541
Train.printf ~here:[%here] ~with_code:false ~with_grad:false y;
542542
[%expect
543543
{|
544-
HERE: test/operations/hello_world_op.ml:544:21
544+
HERE: test/operations/hello_world_op.ml:541:21
545545
┌──────────────────────────────┐
546546
│[6]: +_y shape 0:3
547547
│┌┬───────────────────────────┐│
@@ -573,7 +573,7 @@ let%expect_test "Big matrix" =
573573
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hey;
574574
[%expect
575575
{|
576-
HERE: test/operations/hello_world_op.ml:577:21
576+
HERE: test/operations/hello_world_op.ml:573:21
577577
┌──────────────────────────────────────────────────┐
578578
│[0]: hey shape 1:21->0:21
579579
│┌──────┬─────────────────────────────────────────┐│
@@ -590,7 +590,7 @@ let%expect_test "Big matrix" =
590590
Train.printf ~here:[%here] ~with_code:false ~with_grad:false y;
591591
[%expect
592592
{|
593-
HERE: test/operations/hello_world_op.ml:594:21
593+
HERE: test/operations/hello_world_op.ml:590:21
594594
┌────────────────────────────────────────────┐
595595
│[5]: + shape 0:21
596596
│┌┬─────────────────────────────────────────┐│
@@ -623,7 +623,7 @@ let%expect_test "Very big tensor" =
623623
Train.printf ~here:[%here] ~with_code:false ~with_grad:false hey;
624624
[%expect
625625
{|
626-
HERE: test/operations/hello_world_op.ml:628:21
626+
HERE: test/operations/hello_world_op.ml:623:21
627627
┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
628628
│[0]: r6x10x11x7x8x9 shape 0:6|3:7,4:8,5:9->1:10,2:11
629629
│┌──────┬─────────────────────────────────────────┬─────────────────────────────────────────┬──────┬─────────────────────────────────────────┬─────────────────────────────────────────┐│
@@ -761,7 +761,7 @@ let%expect_test "Very big tensor" =
761761
(* Disable line wrapping for viewing the output. In VSCode: `View: Toggle Word Wrap`. *)
762762
[%expect
763763
{|
764-
HERE: test/operations/hello_world_op.ml:765:21
764+
HERE: test/operations/hello_world_op.ml:760:21
765765
┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
766766
│[6]: -_hoo shape 0:6|1:10,2:11
767767
│┌──────┬─────────────────────────────────────────┬─────────────────────────────────────────┬──────┬─────────────────────────────────────────┬─────────────────────────────────────────┐│

0 commit comments

Comments
 (0)