mindspore.ops.xlogy

View Source On Gitee
mindspore.ops.xlogy(input, other)[source]

Compute input multiplied by the logarithm of other element-wise.

outi=inputilnotheri

Note

  • Support broadcast, support implicit type conversion and type promotion.

Warning

On Ascend, the data type of input and other must be float16 or float32.

Parameters
Returns

Tensor

Supported Platforms:

Ascend GPU CPU

Examples

>>> import mindspore
>>> output = mindspore.ops.xlogy(mindspore.tensor([-5., 0., 4.]), mindspore.tensor([2., 2., 2.]))
>>> print(output)
[-3.465736   0.         2.7725887]