-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
report_dynamo_export.sarif
121 lines (121 loc) · 8.72 KB
/
report_dynamo_export.sarif
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
{
"runs":[
{
"tool":{
"driver":{
"name":"torch.onnx.dynamo_export",
"contents":[
"localizedData",
"nonLocalizedData"
],
"language":"en-US",
"rules":[
{
"id":"FXE0010",
"fullDescription":{
"text":"FX graph transformation during ONNX export before converting from FX IR to ONNX IR.",
"markdown":"This diagnostic tracks the FX passes executed during the ONNX export process prior\nto converting from FX IR (Intermediate Representation) to ONNX IR.\n\nUnder the scope of ONNX export, an FX pass refers to a specific transformation applied to the FX GraphModule.\nThe primary aim of these passes is to streamline the graph into a format that aligns more with the ONNX IR.\nMoreover, these passes work to substitute unsupported FX IR features with those recognized and endorsed by\nONNX IR. Common transformations include, but aren't limited to, decomposition, functionalization and\ntype promotion.\n\nFor those who are interested in a comprehensive log detailing the modifications made during these passes,\nthere are a couple of options:\n\n- Set DiagnosticOptions.verbosity_level to logging.DEBUG.\n- Activate the environment variable TORCH_LOGS='onnx_diagnostics'.\n\nHowever, it's noteworthy that by default, such detailed logging is turned off. The primary reason being\nits considerable impact on performance.\n\nFor an in-depth understanding of each specific pass, please refer to the directory: torch/onnx/_internal/fx/passes.\n"
},
"name":"fx-pass",
"shortDescription":{
"text":"FX graph transformation during ONNX export before converting from FX IR to ONNX IR."
}
}
],
"version":"2.1.1"
}
},
"language":"en-US",
"newlineSequences":[
"\r\n",
"\n"
],
"results":[
{
"message":{
"markdown":"Running Decompose pass. \n\n## Additional Message:\n\n## Function Signature\n### Function Signature Transform.run\n- self: <class 'torch.onnx._internal.fx.passes.decomp.Decompose'>\n- args: Tuple[length=1](\nTensor(f32[1, 256, 1, 1]),\n)\nFor detailed logging of graph modifications by this pass, either set `DiagnosticOptions.verbosity_level` to `logging.DEBUG` or use the environment variable `TORCH_LOGS='onnx_diagnostics'`.\n## Return values\ntorch.fx.GraphModule(<lambda>)",
"text":"Running Decompose pass. "
},
"codeFlows":[
{
"threadFlows":[
{
"locations":[]
}
]
}
],
"graphs":[],
"kind":"informational",
"level":"none",
"locations":[
{
"message":{
"text":"Transform.run"
},
"physicalLocation":{
"artifactLocation":{
"uri":"/opt/homebrew/lib/python3.11/site-packages/torch/onnx/_internal/fx/_pass.py"
},
"region":{
"snippet":{
"text":"@diagnostics.diagnose_call("
},
"startLine":232
}
}
}
],
"properties":{
"tags":[]
},
"ruleId":"FXE0010",
"stacks":[]
},
{
"message":{
"markdown":"Running Functionalize pass. \n\n## Additional Message:\n\n## Function Signature\n### Function Signature Transform.run\n- self: <class 'torch.onnx._internal.fx.passes.functionalization.Functionalize'>\n- args: Tuple[length=1](\nTensor(f32[1, 256, 1, 1]),\n)\nFor detailed logging of graph modifications by this pass, either set `DiagnosticOptions.verbosity_level` to `logging.DEBUG` or use the environment variable `TORCH_LOGS='onnx_diagnostics'`.\n## Exception log\n```\nTraceback (most recent call last):\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/onnx/_internal/diagnostics/infra/decorator.py\", line 135, in wrapper\n return_values = fn(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/onnx/_internal/fx/_pass.py\", line 267, in run\n module = self._run(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/onnx/_internal/fx/passes/functionalization.py\", line 123, in _run\n graph_module = proxy_tensor.make_fx(\n ^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/fx/experimental/proxy_tensor.py\", line 809, in wrapped\n t = dispatch_trace(wrap_key(func, args, fx_tracer, pre_dispatch), tracer=fx_tracer, concrete_args=tuple(phs))\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/_compile.py\", line 24, in inner\n return torch._dynamo.disable(fn, recursive)(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/_dynamo/eval_frame.py\", line 328, in _fn\n return fn(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/_dynamo/external_utils.py\", line 17, in inner\n return fn(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/fx/experimental/proxy_tensor.py\", line 468, in dispatch_trace\n graph = tracer.trace(root, concrete_args)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/_dynamo/eval_frame.py\", line 328, in _fn\n return fn(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/_dynamo/external_utils.py\", line 17, in inner\n return fn(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/fx/_symbolic_trace.py\", line 817, in trace\n (self.create_arg(fn(*args)),),\n ^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/fx/experimental/proxy_tensor.py\", line 485, in wrapped\n out = f(*tensors)\n ^^^^^^^^^^^\n\n File \"<string>\", line 1, in <lambda>\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/onnx/_internal/fx/passes/functionalization.py\", line 86, in wrapped\n out = function(*inputs_functional)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/onnx/_internal/fx/passes/_utils.py\", line 30, in wrapped\n return torch.fx.Interpreter(graph_module).run(*args)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/fx/interpreter.py\", line 138, in run\n self.env[node] = self.run_node(node)\n ^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/fx/interpreter.py\", line 195, in run_node\n return getattr(self, n.op)(n.target, args, kwargs)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/fx/interpreter.py\", line 267, in call_function\n return target(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^^^^^\n\n File \"/opt/homebrew/lib/python3.11/site-packages/torch/_ops.py\", line 448, in __call__\n return self._op(*args, **kwargs or {})\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\nRuntimeError: false INTERNAL ASSERT FAILED at \"/Users/runner/work/pytorch/pytorch/pytorch/build/aten/src/ATen/RegisterFunctionalization_2.cpp\":7745, please report a bug to PyTorch. mutating a non-functional tensor with a functional tensor is not allowed. Please ensure that all of your inputs are wrapped inside of a functionalize() call.\n\nWhile executing %_native_batch_norm_legit : [num_users=3] = call_function[target=torch.ops.aten._native_batch_norm_legit.default](args = (%convolution, %_param_constant1, %_param_constant2, %_tensor_constant1, %_tensor_constant2, True, 0.1, 1e-05), kwargs = {})\nOriginal traceback:\n File \"/Users/kenny/Desktop/github/terrain-synth/model/gan/generator.py\", line 64, in forward\n return self.net(x)\n\n\n```",
"text":"Running Functionalize pass. "
},
"codeFlows":[
{
"threadFlows":[
{
"locations":[]
}
]
}
],
"graphs":[],
"kind":"fail",
"level":"error",
"locations":[
{
"message":{
"text":"Transform.run"
},
"physicalLocation":{
"artifactLocation":{
"uri":"/opt/homebrew/lib/python3.11/site-packages/torch/onnx/_internal/fx/_pass.py"
},
"region":{
"snippet":{
"text":"@diagnostics.diagnose_call("
},
"startLine":232
}
}
}
],
"properties":{
"tags":[]
},
"ruleId":"FXE0010",
"stacks":[]
}
]
}
],
"version":"2.1.0",
"schemaUri":"https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/schemas/sarif-schema-2.1.0.json"
}