pytorch/torch/quantization/ns
Vasiliy Kuznetsov 2a2bc1fc8a ns for fx: add fqn to results, when present (#61377)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/61377

Both the quantization tracer and the NS tracer record
`_node_name_to_scope`, which contains the mapping from
node name to FQN.

This PR adds the FQN information to the NS results, so that it is
more convenient for users to attribute a NS result to the corresponding
module in their model.

Test Plan:
```
python test/test_quantization.py TestFXNumericSuiteCoreAPIs.test_extract_weights_fqn
python test/test_quantization.py TestFXNumericSuiteCoreAPIs.test_match_activations_fqn
python test/test_quantization.py TestFXNumericSuiteCoreAPIs.test_shadow_activations_fqn
```

Imported from OSS

Reviewed By: jerryzh168

Differential Revision: D29600349

fbshipit-source-id: df489e03daff97dd380f59c83ffdc2b0012a0a53
2021-07-17 20:53:41 -07:00
..
__init__.py
graph_matcher.py ns for fx: return results in execution order (#61360) 2021-07-17 20:53:39 -07:00
graph_passes.py ns for fx: add fqn to results, when present (#61377) 2021-07-17 20:53:41 -07:00
mappings.py ns for fx: preserve observers and fake_quants through passes (#61323) 2021-07-17 20:53:33 -07:00
ns_types.py ns for fx: support binary ops when adding unshadowed loggers for inputs (#57025) 2021-04-27 16:28:58 -07:00
pattern_utils.py ns for fx: preserve observers and fake_quants through passes (#61323) 2021-07-17 20:53:33 -07:00
utils.py ns for fx: add fqn to results, when present (#61377) 2021-07-17 20:53:41 -07:00
weight_utils.py ns for fx: add fqn to results, when present (#61377) 2021-07-17 20:53:41 -07:00