Skip to content

Conversation

@ooooo-create
Copy link
Contributor

@ooooo-create ooooo-create commented Aug 13, 2024

PR Category

Execute Infrastructure

PR Types

Others

Description

  • 适配 python/paddle/signal.py 中的 API
  • 同步 binary_cross_entropy_with_logits 旧 IR 下的 typeerror
  • 适配 paddle.view
class TestToStaticCheck(unittest.TestCase):
    def test_error(self):
        @paddle.jit.to_static(full_graph=True)
        def func():
            x_np = np.random.random(size=[2, 3, 4]).astype('float32')
            x = paddle.to_tensor(x_np)
            y = paddle.transpose(x, perm=[1, 0, 2])
            x.add_(x)

        self.assertRaises(ValueError, func)
        if not paddle.framework.use_pir_api():
            self.assertRaises(ValueError, func)

加上了 if not paddle.framework.use_pir_api():,如果PIR下也不支持 stride 应该需要适配。

@paddle-bot
Copy link

paddle-bot bot commented Aug 13, 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 Aug 13, 2024
Copy link
Contributor

@wanghuancoder wanghuancoder left a comment

Choose a reason for hiding this comment

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

LGTM

@luotao1 luotao1 merged commit 0880ac0 into PaddlePaddle:develop Aug 14, 2024
@ooooo-create ooooo-create deleted the pir_ut_signal branch March 8, 2025 04:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contributor External developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants