-
Notifications
You must be signed in to change notification settings - Fork 7.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
submit micronet #5169
submit micronet #5169
Conversation
zhangxinyu15 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
Thanks for your contribution! |
你好,ocr10日课中,提供了这样一个识别数据集,可以基于这个数据集,看下mv3 small 0.5x或者mv1enhance0.5x和micronet的精度差异(仅backbone部分不同,其他部分参数保持一致) https://paddleocr.bj.bcebos.com/dataset/rec_data_lesson_demo.tar |
@@ -0,0 +1,432 @@ | |||
from __future__ import absolute_import |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
需要添加license,可以参考其他的文件头
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
|
||
class h_swish(nn.Layer): | ||
def __init__(self): | ||
super(h_swish, self).__init__() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
super(h_swish, self).__init__()
->super().__init__()
- paddle有现成的hardsigmoid与hardswish api,可以直接调用,这个可以删掉
- 类名首字母大写,不建议用小写+下划线方式
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
|
||
|
||
class MicroNet(nn.Layer): | ||
def __init__(self, mode='M0', **kwargs): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
可以在这里添加下reference
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
ppocr/optimizer/dyshiftmax.py
Outdated
@@ -0,0 +1,104 @@ | |||
import paddle |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
license
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个文件中仅有一个class了,合并到了rec_micronet.py中。
ppocr/optimizer/dyshiftmax.py
Outdated
import paddle.nn.functional as F | ||
|
||
|
||
class h_sigmoid(nn.Layer): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个用标准api替代吧
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
ppocr/optimizer/dyshiftmax.py
Outdated
return self.relu(x + 3) * self.h_max | ||
|
||
|
||
class DYShiftMax(nn.Layer): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个文件放在backbone目录下面吧,跟optimizer没啥关系
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个文件中仅有一个class了,合并到了rec_micronet.py中。
好的,我这几天训练一下 |
目前我不知道如何提交具体的log,所有上传到了百度云盘,链接: https://pan.baidu.com/s/1zKI--IZen-HiT3zwirqpsQ 密码: ir8n。里面有我做的实验log和可视化图。 |
跟onecycle那个pr相同,把log和指标贴在这个pr下面就ok哈,代码方面我没问题了~ |
pr5169_micronet.zip |
修改了commit的用户名和邮箱,之前cla一直没成功。 |
论文链接
参考代码
我的工作
单机4卡(V100,32G),num_workers=8,batch_size=256