mirror of
https://github.com/hpcaitech/ColossalAI.git
synced 2025-09-09 04:50:17 +00:00
[fx/profiler] debug the fx.profiler / add an example test script for fx.profiler (#1730)
* [fx/profiler] add test. * [fx] fix file names. * [fx] add docstring and comment. * [fx] polish profiler.py. * [fx] fix import errors. * [fx] fix profiler. * [fx] fix names.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import torch
|
||||
|
||||
__all__ = ['ALIAS_ATEN', 'INPLACE_NEW', 'INPLACE_MATH_ATEN', 'CLONE_ATEN']
|
||||
__all__ = ['ALIAS_ATEN', 'INPLACE_NEW', 'INPLACE_MATH_ATEN', 'CLONE_ATEN', 'RELU_LIKE_OPS', 'RELU_LIKE_MOD']
|
||||
|
||||
aten = torch.ops.aten
|
||||
|
||||
@@ -30,3 +30,15 @@ INPLACE_MATH_ATEN = [
|
||||
CLONE_ATEN = [
|
||||
aten.clone.default,
|
||||
]
|
||||
|
||||
# See illustrations in
|
||||
# https://github.com/hpcaitech/ColossalAI/blob/main/colossalai/fx/profiler/constants.py
|
||||
OUTPUT_SAVED_OPS = [
|
||||
torch.nn.functional.relu,
|
||||
torch.nn.functional.softmax,
|
||||
]
|
||||
|
||||
OUTPUT_SAVED_MOD = [
|
||||
torch.nn.ReLU,
|
||||
torch.nn.Softmax,
|
||||
]
|
||||
|
Reference in New Issue
Block a user