Skip to content

Commit 9df637d

Browse files
authored
[New Sample] Add cv samples for models with more than 20 subgraphs (#282)
* Add cv samples for models with more than 20 subgraphs. * Remove redundant subgraphs. * Add cv samples for models with more than 30 subgraphs. * Remove redundant subgraphs. * Remove the failed samples temporarly.
1 parent 32407c9 commit 9df637d

File tree

2,085 files changed

+905658
-5951
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,085 files changed

+905658
-5951
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ef1cff7d6a09085f5a39414177fefe578d79f40af14d0cf5f79e9d5fbd2cd740
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"framework": "paddle",
3+
"model_name": "Cascade-FasterRCNN-ResNet50-FPN",
4+
"num_devices_required": 1,
5+
"num_nodes_required": 1
6+
}
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
class Program_weight_tensor_data_0:
2+
name = "data_0"
3+
shape = []
4+
dtype = "int64"
5+
data = [3]
6+
7+
8+
class Program_weight_tensor_data_1:
9+
name = "data_1"
10+
shape = [512]
11+
dtype = "int64"
12+
min_val = 0
13+
max_val = 511
14+
data = None
15+
16+
17+
class Program_weight_tensor_data_2:
18+
name = "data_2"
19+
shape = [512, 4]
20+
dtype = "float32"
21+
max_val = float("1023.9")
22+
mean = float("564.285")
23+
std = float("272.403")
24+
data = None
25+
26+
27+
class Program_weight_tensor_data_3:
28+
name = "data_3"
29+
shape = [512]
30+
dtype = "int64"
31+
min_val = 0
32+
max_val = 2
33+
data = None
34+
35+
36+
class Program_weight_tensor_data_4:
37+
name = "data_4"
38+
shape = [3, 4]
39+
dtype = "float32"
40+
data = [
41+
399.36,
42+
483.84,
43+
458.24,
44+
542.72,
45+
680.96,
46+
599.04,
47+
747.52,
48+
668.16,
49+
642.56,
50+
606.72,
51+
688.64,
52+
727.04,
53+
]
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
import paddle
2+
3+
4+
class GraphModule(paddle.nn.Layer):
5+
def __init__(self):
6+
super().__init__()
7+
8+
def forward(self, data_0, data_1, data_2, data_3, data_4):
9+
# pd_op.full: (xi64) <- ()
10+
full_0 = paddle._C_ops.full(
11+
[], float("0"), paddle.int64, paddle.framework._current_expected_place()
12+
)
13+
14+
# pd_op.greater_than: (xb) <- (xi64, xi64)
15+
greater_than_0 = paddle._C_ops.greater_than(data_0, full_0)
16+
del data_0
17+
18+
# pd_op.cast: (xi64) <- (xb)
19+
cast_0 = paddle._C_ops.cast(greater_than_0, paddle.int64)
20+
del greater_than_0
21+
22+
# pd_op.not_equal: (xb) <- (xi64, xi64)
23+
not_equal_0 = paddle._C_ops.not_equal(cast_0, full_0)
24+
del cast_0
25+
26+
# pd_op.cast: (xi64) <- (xb)
27+
cast_1 = paddle._C_ops.cast(not_equal_0, paddle.int64)
28+
del not_equal_0
29+
30+
# pd_op.equal: (xb) <- (xi64, xi64)
31+
equal_0 = paddle._C_ops.equal(cast_1, full_0)
32+
del cast_1, full_0
33+
34+
# pd_op.full: (1xi32) <- ()
35+
full_1 = paddle._C_ops.full(
36+
[1], float("0"), paddle.int32, paddle.core.CPUPlace()
37+
)
38+
39+
# pd_op.gather: (-1x4xf32) <- (-1x4xf32, -1xi64, 1xi32)
40+
gather_0 = paddle._C_ops.gather(data_4, data_3, full_1)
41+
del data_3, data_4, full_1
42+
43+
# pd_op.shape64: (1xi64) <- (512xi64)
44+
shape64_0 = paddle._C_ops.shape64(data_1)
45+
del data_1
46+
47+
return gather_0, shape64_0
File renamed without changes.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
d84efc51ae2a7d78f2c99b1540a638f4add520ed84de5d62907935b05a8cf292
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"framework": "paddle",
3+
"model_name": "Cascade-FasterRCNN-ResNet50-FPN",
4+
"num_devices_required": 1,
5+
"num_nodes_required": 1
6+
}
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
class Program_weight_tensor_data_0:
2+
name = "data_0"
3+
shape = [512, 4]
4+
dtype = "float32"
5+
max_val = float("1018.05")
6+
mean = float("439.025")
7+
std = float("231.686")
8+
data = None
9+
10+
11+
class Program_weight_tensor_data_1:
12+
name = "data_1"
13+
shape = [512, 4]
14+
dtype = "float32"
15+
max_val = float("938.986")
16+
mean = float("467.502")
17+
std = float("224.196")
18+
data = None
19+
20+
21+
class Program_weight_tensor_data_2:
22+
name = "data_2"
23+
shape = [512, 4]
24+
dtype = "float32"
25+
max_val = float("936.918")
26+
mean = float("499.308")
27+
std = float("203.062")
28+
data = None
29+
30+
31+
class Program_weight_tensor_data_3:
32+
name = "data_3"
33+
shape = [512, 4]
34+
dtype = "float32"
35+
max_val = float("981.0")
36+
mean = float("506.296")
37+
std = float("288.897")
38+
data = None
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
import paddle
2+
3+
4+
class GraphModule(paddle.nn.Layer):
5+
def __init__(self):
6+
super().__init__()
7+
8+
def forward(self, data_0, data_1, data_2, data_3):
9+
# pd_op.shape64: (2xi64) <- (512x4xf32)
10+
shape64_0 = paddle._C_ops.shape64(data_0)
11+
del data_0
12+
13+
# pd_op.full_int_array: (1xi64) <- ()
14+
full_int_array_0 = [0]
15+
16+
# pd_op.full_int_array: (1xi64) <- ()
17+
full_int_array_1 = [1]
18+
19+
# pd_op.slice: (1xi64) <- (2xi64, 1xi64, 1xi64)
20+
slice_0 = paddle._C_ops.slice(
21+
shape64_0, [0], full_int_array_0, full_int_array_1, [1], []
22+
)
23+
del shape64_0
24+
25+
# pd_op.shape64: (2xi64) <- (512x4xf32)
26+
shape64_1 = paddle._C_ops.shape64(data_1)
27+
del data_1
28+
29+
# pd_op.slice: (1xi64) <- (2xi64, 1xi64, 1xi64)
30+
slice_1 = paddle._C_ops.slice(
31+
shape64_1, [0], full_int_array_0, full_int_array_1, [1], []
32+
)
33+
del shape64_1
34+
35+
# pd_op.shape64: (2xi64) <- (512x4xf32)
36+
shape64_2 = paddle._C_ops.shape64(data_2)
37+
del data_2
38+
39+
# pd_op.slice: (1xi64) <- (2xi64, 1xi64, 1xi64)
40+
slice_2 = paddle._C_ops.slice(
41+
shape64_2, [0], full_int_array_0, full_int_array_1, [1], []
42+
)
43+
del shape64_2
44+
45+
# pd_op.shape64: (2xi64) <- (512x4xf32)
46+
shape64_3 = paddle._C_ops.shape64(data_3)
47+
del data_3
48+
49+
# pd_op.slice: (1xi64) <- (2xi64, 1xi64, 1xi64)
50+
slice_3 = paddle._C_ops.slice(
51+
shape64_3, [0], full_int_array_0, full_int_array_1, [1], []
52+
)
53+
del full_int_array_0, full_int_array_1, shape64_3
54+
55+
# pd_op.full: (1xi32) <- ()
56+
full_0 = paddle._C_ops.full(
57+
[1], float("0"), paddle.int32, paddle.core.CPUPlace()
58+
)
59+
60+
# builtin.combine: ([1xi64, 1xi64, 1xi64, 1xi64]) <- (1xi64, 1xi64, 1xi64, 1xi64)
61+
combine_0 = [slice_0, slice_1, slice_2, slice_3]
62+
del slice_0, slice_1, slice_2, slice_3
63+
64+
# pd_op.concat: (4xi64) <- ([1xi64, 1xi64, 1xi64, 1xi64], 1xi32)
65+
concat_0 = paddle._C_ops.concat(combine_0, full_0)
66+
del combine_0, full_0
67+
68+
return concat_0
File renamed without changes.

0 commit comments

Comments
 (0)