pytorch
58fb3f01 - Fix conjugate bit discrepancy in composite compliance

Commit
2 years ago
Fix conjugate bit discrepancy in composite compliance When testing composite compliance, the conj bit and neg bit are not propagated to the wrapper tensor. This leads to problems when a composite operator has two paths depending on whether one of these bits are set, since the non-conjugated path will always be taken. For example, `at::real` effectively does ```cpp view_as_real(tensor.is_conj() ? tensor.conj() : tensor) ``` which will never call `conj()` because the `CompositeCompliantTensor` never has has the conj bit set. The result is `view_as_real` fails when `r.elem` does have the conj bit set. Pull Request resolved: https://github.com/pytorch/pytorch/pull/75830 Approved by: https://github.com/zou3519
Author
Committer
Parents
Loading