11#! /bin/bash
22
3- # GRAPH_NET_ROOT=$(python3 -c "import graph_net; import os; print(os.path.dirname(os.path.dirname(graph_net.__file__)))")
4-
5- # model_path_list=$GRAPH_NET_ROOT/graph_net/test/dev_model_list/cumsum_num_kernels_sample_list.txt
6- # WORKSPACE_ROOT=/tmp/fusible_subgraphs
7- # CUMSUM_NUM_KERNELS_WORKSPACE=$WORKSPACE_ROOT/workspace_cumsum_num_kernels
8- # FUSIBLE_SUBGRAPH_RANGES_WORKSPACE=$WORKSPACE_ROOT/workspace_fusible_subgraph_ranges
9- # FUSIBLE_SUBGRAPH_SAMPLES_WORKSPACE=$WORKSPACE_ROOT/workspace_fusible_subgraph_samples
10- # resume=false
11-
12- # python3 -m graph_net.model_path_handler \
13- # --model-path-list "$model_path_list" \
14- # --handler-config $(base64 -w 0 <<EOF
15- # {
16- # "handler_path": "$GRAPH_NET_ROOT/graph_net/torch/sample_passes/cumsum_num_kernels_generator.py",
17- # "handler_class_name": "CumSumNumKernelsGenerator",
18- # "handler_config": {
19- # "output_json_file_name": "cumsum_num_kernels.json",
20- # "model_path_prefix": "$GRAPH_NET_ROOT",
21- # "output_dir": "$CUMSUM_NUM_KERNELS_WORKSPACE",
22- # "resume": $resume
23- # }
24- # }
25- # EOF
26- # )
27-
28- # python3 -m graph_net.model_path_handler \
29- # --model-path-list "$model_path_list" \
30- # --handler-config $(base64 -w 0 <<EOF
31- # {
32- # "handler_path": "$GRAPH_NET_ROOT/graph_net/sample_pass/fusible_subgraph_ranges_generator.py",
33- # "handler_class_name": "FusibleSubgraphRangesGenerator",
34- # "handler_config": {
35- # "model_path_prefix": "$CUMSUM_NUM_KERNELS_WORKSPACE",
36- # "input_json_file_name": "cumsum_num_kernels.json",
37- # "output_json_file_name": "fusible_subgraph_ranges.json",
38- # "output_dir": "$FUSIBLE_SUBGRAPH_RANGES_WORKSPACE",
39- # "resume": $resume
40- # }
41- # }
42- # EOF
43- # )
44-
45- # python3 -m graph_net.model_path_handler \
46- # --model-path-list "$model_path_list" \
47- # --handler-config $(base64 -w 0 <<EOF
48- # {
49- # "handler_path": "$GRAPH_NET_ROOT/graph_net/torch/sample_passes/subgraph_generator.py",
50- # "handler_class_name": "SubgraphGenerator",
51- # "handler_config": {
52- # "model_path_prefix": "$GRAPH_NET_ROOT",
53- # "output_dir": "$FUSIBLE_SUBGRAPH_SAMPLES_WORKSPACE",
54- # "subgraph_ranges_json_root": "$FUSIBLE_SUBGRAPH_RANGES_WORKSPACE",
55- # "resume": $resume
56- # }
57- # }
58- # EOF
59- # )
60-
613GRAPH_NET_ROOT=$( python3 -c " import graph_net; import os; print(os.path.dirname(os.path.dirname(graph_net.__file__)))" )
624
635model_path_list=$GRAPH_NET_ROOT /graph_net/test/dev_model_list/cumsum_num_kernels_sample_list.txt
@@ -69,7 +11,7 @@ resume=false
6911
7012python3 -m graph_net.apply_sample_pass \
7113 --model-path-list " $model_path_list " \
72- --sample-pass-file-path " $GRAPH_NET_ROOT /graph_net/torch/sample_passes /cumsum_num_kernels_generator.py" \
14+ --sample-pass-file-path " $GRAPH_NET_ROOT /graph_net/torch/sample_pass /cumsum_num_kernels_generator.py" \
7315 --sample-pass-class-name " CumSumNumKernelsGenerator" \
7416 --sample-pass-config " $( cat << EOF
7517{
0 commit comments