AndrewZhaoLuo commented on code in PR #11141:
URL: https://github.com/apache/tvm/pull/11141#discussion_r875262435
##########
python/tvm/relay/frontend/onnx.py:
##########
@@ -2349,30 +2349,18 @@ class LogSoftmax(OnnxOpConverter):
"""Operator converter for Softmax."""
@classmethod
- def run_calculation(cls, x, axes):
+ def run_calculation(cls, inputs, attr, params, opset):
"""Run the calculation for Log Softmax calculation."""
- m = _op.max(x, axes, keepdims=True)
- e = _op.exp(x - m)
- s = _op.sum(e, axes, keepdims=True)
- return x - m - _op.log(s)
Review Comment:
Ah cool
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]