Skip to content

Commit

Permalink
Merge branch 'release/2.5' into xyt/gamma_double_r25
Browse files Browse the repository at this point in the history
  • Loading branch information
xytintel authored Aug 29, 2024
2 parents e9ad734 + 2bd8ce9 commit 2b7d7ff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ATen/native/xpu/sycl/UnaryKernels.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -234,8 +234,8 @@ struct Expm1Functor {
template <typename T>
struct Expm1Functor<c10::complex<T>> {
c10::complex<T> operator()(c10::complex<T> x) const {
auto a = std::sin(.5 * x.imag());
auto re = std::expm1(x.real()) * std::cos(x.imag()) - 2 * a * a;
auto a = std::sin(T(.5) * x.imag());
auto re = std::expm1(x.real()) * std::cos(x.imag()) - T(2) * a * a;
auto im = std::exp(x.real()) * std::sin(x.imag());
return c10::complex<T>(re, im);
}
Expand Down

0 comments on commit 2b7d7ff

Please sign in to comment.