backward.json 1.57 KB
Newer Older
rusty1s's avatar
rusty1s committed
1
2
3
4
5
6
[
  {
    "name": "add",
    "index": [[4, 5, 4, 2, 3], [0, 0, 2, 2, 1]],
    "input": [[2, 0, 1, 4, 3], [0, 2, 1, 3, 4]],
    "dim": 1,
rusty1s's avatar
rusty1s committed
7
    "fill_value": 0,
rusty1s's avatar
rusty1s committed
8
9
10
    "grad": [[10, 20, 30, 40, 50, 60], [15, 25, 35, 45, 55, 65]],
    "expected": [[50, 60, 50, 30, 40], [15, 15, 35, 35, 25]]
  },
rusty1s's avatar
rusty1s committed
11
12
13
14
15
16
17
18
19
  {
    "name": "add",
    "index": [[0, 0], [1, 1], [1, 1], [0, 0]],
    "input": [[5, 2], [2, 5], [4, 3], [1, 3]],
    "dim": 0,
    "fill_value": 0,
    "grad": [[10, 20], [15, 25]],
    "expected": [[10, 20], [15, 25], [15, 25], [10, 20]]
  },
rusty1s's avatar
rusty1s committed
20
21
22
23
24
25
26
27
28
  {
    "name": "mean",
    "index": [[4, 5, 4, 2, 3], [0, 0, 2, 2, 1]],
    "input": [[2, 0, 1, 4, 3], [0, 2, 1, 3, 4]],
    "dim": 1,
    "fill_value": 0,
    "grad": [[10, 20, 30, 40, 50, 60], [15, 25, 35, 45, 55, 65]],
    "expected": [[50, 60, 50, 30, 40], [15, 15, 35, 35, 25]]
  },
rusty1s's avatar
rusty1s committed
29
30
31
32
33
34
35
36
37
  {
    "name": "mean",
    "index": [[0, 0], [1, 1], [1, 1], [0, 0]],
    "input": [[5, 2], [2, 5], [4, 3], [1, 3]],
    "dim": 0,
    "fill_value": 0,
    "grad": [[10, 20], [15, 25]],
    "expected": [[10, 20], [15, 25], [15, 25], [10, 20]]
  },
rusty1s's avatar
rusty1s committed
38
39
40
41
42
  {
    "name": "max",
    "index": [[4, 5, 4, 2, 3], [0, 0, 2, 2, 1]],
    "input": [[2, 0, 1, 4, 3], [0, 2, 1, 3, 4]],
    "dim": 1,
rusty1s's avatar
rusty1s committed
43
    "fill_value": 0,
rusty1s's avatar
rusty1s committed
44
45
    "grad": [[10, 20, 30, 40, 50, 60], [15, 25, 35, 45, 55, 65]],
    "expected": [[50, 60, 0, 30, 40], [0, 15, 0, 35, 25]]
rusty1s's avatar
rusty1s committed
46
47
48
49
50
51
52
53
54
  },
  {
    "name": "max",
    "index": [[0, 0], [1, 1], [1, 1], [0, 0]],
    "input": [[5, 2], [2, 5], [4, 3], [1, 3]],
    "dim": 0,
    "fill_value": 0,
    "grad": [[10, 20], [15, 25]],
    "expected": [[10, 0], [0, 25], [15, 0], [0, 20]]
rusty1s's avatar
rusty1s committed
55
56
  }
]