Skip to content
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

[Paddle TensorRT No.2] Add pd_op.elu converter #69278

Merged
merged 11 commits into from
Dec 13, 2024

Conversation

enkilee
Copy link
Contributor

@enkilee enkilee commented Nov 11, 2024

PR Category

User Experience

PR Types

New features

Description

Copy link

paddle-bot bot commented Nov 11, 2024

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

@paddle-bot paddle-bot bot added the contributor External developers label Nov 11, 2024
@ooooo-create
Copy link
Contributor

标题把 No.2 放 [] 里边叭,不然不会自动统计,issue 里已经修改过了

@enkilee enkilee changed the title [Paddle TensorRT] No.2 Add pd_op.elu converter [Paddle TensorRT No.2] Add pd_op.elu converter Nov 11, 2024
@enkilee enkilee changed the title [Paddle TensorRT No.2] Add pd_op.elu converter 【Paddle TensorRT No.2】 Add pd_op.elu converter Nov 11, 2024
@enkilee
Copy link
Contributor Author

enkilee commented Nov 11, 2024

收到

@@ -20,6 +20,21 @@
import paddle


class TestEluTRTPattern(TensorRTBaseTest):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

再加一个"int64"的单测,把np.float32改为"float32"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

收到

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

    if in_dynamic_or_pir_mode():
        return _C_ops.elu(x, alpha)

    else:
        check_variable_and_dtype(
            x, 'x', ['float16', 'uint16', 'float32', 'float64'], 'elu'
        )
        helper = LayerHelper("elu", **locals())
        out = helper.create_variable_for_type_inference(x.dtype)
        helper.append_op(
            type='elu',
            inputs={'X': x},
            outputs={'Out': out},
            attrs={'alpha': alpha},
        )
        return out

不支持int64

@luotao1 luotao1 added the HappyOpenSource 快乐开源活动issue与PR label Nov 13, 2024
@luotao1
Copy link
Contributor

luotao1 commented Nov 27, 2024

冲突了

@enkilee enkilee changed the title 【Paddle TensorRT No.2】 Add pd_op.elu converter [Paddle TensorRT No.2] Add pd_op.elu converter Dec 3, 2024
@enkilee
Copy link
Contributor Author

enkilee commented Dec 9, 2024

@lizexu123 please review the pr if u are free. thx.

self.check_trt_result()


class TestEluTRTPatternCase2(TensorRTBaseTest):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

再加一个self.enable_fp16=True的检查,如果过了就可以approve了

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个可以先合入,后续再添加也行

YuanRisheng
YuanRisheng previously approved these changes Dec 11, 2024
@luotao1
Copy link
Contributor

luotao1 commented Dec 11, 2024

冲突啦

Copy link

paddle-ci-bot bot commented Dec 12, 2024

Sorry to inform you that 1be8daa's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually.

@enkilee
Copy link
Contributor Author

enkilee commented Dec 13, 2024

@YuanRisheng conflict resloved. please review if u are free. thx.

@YuanRisheng YuanRisheng merged commit 5b06508 into PaddlePaddle:develop Dec 13, 2024
28 checks passed
@enkilee enkilee deleted the TensorRT-converter-2-elu branch January 8, 2025 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor External developers HappyOpenSource 快乐开源活动issue与PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants