提交 52e1392b 编写于 作者: G gaotingquan 提交者: Tingquan Gao

revert

the code may cause problem that loss change in training.
上级 0e0eca3b
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
import copy import copy
import importlib import importlib
import paddle
import paddle.nn as nn import paddle.nn as nn
from paddle.jit import to_static from paddle.jit import to_static
from paddle.static import InputSpec from paddle.static import InputSpec
...@@ -42,14 +41,6 @@ def build_model(config): ...@@ -42,14 +41,6 @@ def build_model(config):
prune_model(config, arch) prune_model(config, arch)
quantize_model(config, arch) quantize_model(config, arch)
logger.info("The FLOPs and Params of Arch:")
try:
flops = paddle.flops(arch, [1, *config["Global"]["image_shape"]])
except Exception as e:
logger.warning(
f"An error occurred when calculating FLOPs and Params of Arch. Please check the Global.image_shape in config. The details of error is: {e}"
)
return arch return arch
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册