提交 c4031f35 编写于 作者: S stephon

Merge branch 'release/2.2' of https://github.com/Intsigstephon/PaddleClas into release/2.2

...@@ -120,7 +120,7 @@ python3 tools/train.py \ ...@@ -120,7 +120,7 @@ python3 tools/train.py \
`-c` is used to specify the path to the configuration file, and `-o` is used to specify the parameters that need to be modified or added, where `-o Arch.Backbone.pretrained=True` indicates that the Backbone part uses the pre-trained model, in addition, `Arch.Backbone.pretrained` can also specify backbone.`pretrained` can also specify the address of a specific model weight file, which needs to be replaced with the path to your own pre-trained model weight file when using it. `-o Global.device=gpu` indicates that the GPU is used for training. If you want to use a CPU for training, you need to set `Global.device` to `cpu`. `-c` is used to specify the path to the configuration file, and `-o` is used to specify the parameters that need to be modified or added, where `-o Arch.Backbone.pretrained=True` indicates that the Backbone part uses the pre-trained model, in addition, `Arch.Backbone.pretrained` can also specify backbone.`pretrained` can also specify the address of a specific model weight file, which needs to be replaced with the path to your own pre-trained model weight file when using it. `-o Global.device=gpu` indicates that the GPU is used for training. If you want to use a CPU for training, you need to set `Global.device` to `cpu`.
For more detailed training configuration, you can also modify the corresponding configuration file of the model directly. Refer to the [configuration document](config_en.md) for specific configuration parameters. For more detailed training configuration, you can also modify the corresponding configuration file of the model directly. Refer to the [configuration document](config_description_en.md) for specific configuration parameters.
Run the above commands to check the output log, an example is as follows: Run the above commands to check the output log, an example is as follows:
......
docs/images/wx_group.png

66.4 KB | W: | H:

docs/images/wx_group.png

57.4 KB | W: | H:

docs/images/wx_group.png
docs/images/wx_group.png
docs/images/wx_group.png
docs/images/wx_group.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -117,7 +117,7 @@ python3 tools/train.py \ ...@@ -117,7 +117,7 @@ python3 tools/train.py \
其中,`-c`用于指定配置文件的路径,`-o`用于指定需要修改或者添加的参数,其中`-o Arch.Backbone.pretrained=True`表示Backbone部分使用预训练模型,此外,`Arch.Backbone.pretrained`也可以指定具体的模型权重文件的地址,使用时需要换成自己的预训练模型权重文件的路径。`-o Global.device=gpu`表示使用GPU进行训练。如果希望使用CPU进行训练,则需要将`Global.device`设置为`cpu` 其中,`-c`用于指定配置文件的路径,`-o`用于指定需要修改或者添加的参数,其中`-o Arch.Backbone.pretrained=True`表示Backbone部分使用预训练模型,此外,`Arch.Backbone.pretrained`也可以指定具体的模型权重文件的地址,使用时需要换成自己的预训练模型权重文件的路径。`-o Global.device=gpu`表示使用GPU进行训练。如果希望使用CPU进行训练,则需要将`Global.device`设置为`cpu`
更详细的训练配置,也可以直接修改模型对应的配置文件。具体配置参数参考[配置文档](config.md) 更详细的训练配置,也可以直接修改模型对应的配置文件。具体配置参数参考[配置文档](config_description.md)
运行上述命令,可以看到输出日志,示例如下: 运行上述命令,可以看到输出日志,示例如下:
...@@ -245,4 +245,4 @@ python3 tools/export_model.py \ ...@@ -245,4 +245,4 @@ python3 tools/export_model.py \
- 平均检索精度(mAP) - 平均检索精度(mAP)
- AP: AP指的是不同召回率上的正确率的平均值 - AP: AP指的是不同召回率上的正确率的平均值
- mAP: 测试集中所有图片对应的AP的的平均值 - mAP: 测试集中所有图片对应的AP的的平均值
\ No newline at end of file
...@@ -131,7 +131,7 @@ class GoogLeNetDY(nn.Layer): ...@@ -131,7 +131,7 @@ class GoogLeNetDY(nn.Layer):
self._ince5b = Inception( self._ince5b = Inception(
832, 832, 384, 192, 384, 48, 128, 128, name="ince5b") 832, 832, 384, 192, 384, 48, 128, 128, name="ince5b")
self._pool_5 = AvgPool2D(kernel_size=7, stride=7) self._pool_5 = AdaptiveAvgPool2D(1)
self._drop = Dropout(p=0.4, mode="downscale_in_infer") self._drop = Dropout(p=0.4, mode="downscale_in_infer")
self._fc_out = Linear( self._fc_out = Linear(
......
...@@ -34,9 +34,8 @@ Optimizer: ...@@ -34,9 +34,8 @@ Optimizer:
momentum: 0.9 momentum: 0.9
lr: lr:
name: Piecewise name: Piecewise
learning_rate: 0.01
decay_epochs: [30, 60, 90] decay_epochs: [30, 60, 90]
values: [0.1, 0.01, 0.001, 0.0001] values: [0.01, 0.001, 0.0001, 0.00001]
regularizer: regularizer:
name: 'L2' name: 'L2'
coeff: 0.0001 coeff: 0.0001
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册