Skip to content
class

ImagBackward

ImagBackward

Python wrappers

Public Python APIs implemented by this engine symbol.

Extract the imaginary part of a complex tensor as a real tensor.

The result dtype is the corresponding real dtype (C64 → F32, C128 → F64); the shape and device are unchanged.

Math

yk=ℑ(zk) y_k = \Im(z_k)

See Also

real_op, complex_op, conj_op Backward for imag — see RealBackward for why these were missing and what it cost. The same statement about the other lane.

Parameters

aTensorImplPtr
Complex-dtype input tensor (C64; CPU also supports C128).

Raises

DtypeMismatch
If a is not a complex dtype.