-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Add LogSoftmax and LogSigmoid support #4921
Conversation
Codecov Report
@@ Coverage Diff @@
## master #4921 +/- ##
========================================
Coverage 94.91% 94.91%
========================================
Files 776 778 +2
Lines 226096 226275 +179
========================================
+ Hits 214589 214760 +171
- Misses 11507 11515 +8
|
Wait, is it better to rewrite logsigmoid/logsoftmax nodes into a log node and a sigmoid/softmax node in pnnx's pass_ncnn? This helps removing duplicate code but achieving higher numerical stability is impossible with this solution. |
For code reuse, additional parameters can be added to the existing sigmoid/softmax |
Is it better to rewrite logxxx nodes into a log node + a xxx node? I will submit another PR soon. |
The patch adds LogSoftmax and LogSigmoid layers to ncnn and respective passes to pnnx.