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.linalg.corrcoef的计算结果不对称 #50048
Comments
您好,我们已经收到了您的问题,会安排技术人员尽快解答您的问题,请耐心等待。请您再次检查是否提供了清晰的问题描述、复现代码、环境&版本、报错信息等。同时,您也可以通过查看官网API文档、常见问题、历史Issue、AI社区来寻求解答。祝您生活愉快~ Hi! We've received your issue and please be patient to get responded. We will arrange technicians to answer your questions as soon as possible. Please make sure that you have posted enough message to demo your request. You may also check out the API,FAQ,Github Issue and AI community to get the answer.Have a nice day! |
你好,我复现了你的问题,这个bug会找相关API负责人( #40690 )修复,谢谢反馈。 |
你好,根据你的截图来看,gpu场景不正常鸭,它只保证了对角线为1,对称不同。 |
@liqitong-a 可以帮忙看下这个问题么? |
numpy 其实也有该问题,输出的矩阵并非严格对称,numpy.corrcoef: import numpy as np
print(np.__version__) # 1.23.2
xt = np.random.rand(30, 40)
r = np.corrcoef(xt, dtype="float32")
print(np.allclose(r, r.T, rtol=1e-8)) # False
print(np.count_nonzero(r != r.T)) # 300
for i in range(r.shape[0]):
for j in range(r.shape[1]):
if r[i][j] != r[j][i]:
print(r[i][j], r[j][i]) |
由于是在其他算子的基础上进行运算,所以和其他算子的精度也有关系,使用float64精度会高一些,使用float32cov算子也会有偏差。
|
@Liyulingyue 看下这个问题是否解决了? |
got it 但是我有个小问题,这种情况需要特意对齐吗?毕竟按照计算逻辑,对角线默认为1,对称元素应当相同? |
64可以对齐 |
bug描述 Describe the Bug
相关系数矩阵不对称。
其他补充信息 Additional Supplementary Information
No response
The text was updated successfully, but these errors were encountered: