• Home
  • Raw
  • Download

Lines Matching refs:exp

19 TORCH_META_FUNC2(pow, Tensor_Tensor) (const Tensor& base, const Tensor& exp) {  in TORCH_META_FUNC2()
20 build_borrowing_binary_op(maybe_get_output(), base, exp); in TORCH_META_FUNC2()
23 TORCH_META_FUNC2(pow, Tensor_Scalar) (const Tensor& base, const Scalar& exp) { in TORCH_META_FUNC2()
26 exp.isIntegral(true) && exp.toLong() < 0), in TORCH_META_FUNC2()
29 auto common_dtype = at::result_type(base, exp); in TORCH_META_FUNC2()
33 TORCH_META_FUNC2(pow, Scalar) (const Scalar& base, const Tensor& exp) { in TORCH_META_FUNC2()
36 …ype = maybe_get_output().defined() ? maybe_get_output().scalar_type() : at::result_type(base, exp); in TORCH_META_FUNC2()
37 …set_output_raw_strided(0, exp.sizes(), {}, exp.options().dtype(dtype), exp.has_names() ? exp.names… in TORCH_META_FUNC2()
47 TORCH_IMPL_FUNC(pow_Tensor_Tensor_out) (const Tensor& base, const Tensor& exp, const Tensor& out) { in TORCH_IMPL_FUNC()
51 TORCH_IMPL_FUNC(pow_Tensor_Scalar_out) (const Tensor& base, const Scalar& exp, const Tensor& out) { in TORCH_IMPL_FUNC()
52 if (exp.equal(0.0) || exp.equal(false)) { in TORCH_IMPL_FUNC()
54 } else if (exp.equal(1.0) || exp.equal(true) ) { in TORCH_IMPL_FUNC()
57 pow_tensor_scalar_stub(device_type(), *this, exp); in TORCH_IMPL_FUNC()
61 TORCH_IMPL_FUNC(pow_Scalar_out) (const Scalar& base, const Tensor& exp, const Tensor& out) { in TORCH_IMPL_FUNC()
66 …at::pow_out(const_cast<Tensor&>(out), wrapped_scalar_tensor(base, exp.device()), exp); // redispat… in TORCH_IMPL_FUNC()
70 Tensor& float_power_out(const Tensor& base, const Tensor& exp, Tensor& result) { in float_power_out() argument
71 auto dtype = (at::isComplexType(base.scalar_type()) || at::isComplexType(exp.scalar_type())) ? in float_power_out()
77 return at::pow_out(result, base.to(dtype), exp.to(dtype)); in float_power_out()
80 Tensor& float_power_out(const Tensor& base, const Scalar& exp, Tensor& result) { in float_power_out() argument
81 …auto dtype = (at::isComplexType(base.scalar_type()) || exp.isComplex()) ? at::kComplexDouble : at:… in float_power_out()
88 …auto casted_exp = (dtype == at::kComplexDouble) ? Scalar(exp.toComplexDouble()) : Scalar(exp.toDou… in float_power_out()
92 Tensor& float_power_out(const Scalar& base, const Tensor& exp, Tensor& result) { in float_power_out() argument
93 …auto dtype = (at::isComplexType(exp.scalar_type()) || base.isComplex()) ? at::kComplexDouble : at:… in float_power_out()
99 return at::pow_out(result, casted_base, exp.to(dtype)); in float_power_out()
102 Tensor float_power(const Tensor& base, const Scalar& exp) { in float_power() argument
103 …auto dtype = (at::isComplexType(base.scalar_type()) || exp.isComplex()) ? at::kComplexDouble : at:… in float_power()
104 …auto casted_exp = (dtype == at::kComplexDouble) ? Scalar(exp.toComplexDouble()) : Scalar(exp.toDou… in float_power()
108 Tensor float_power(const Scalar& base, const Tensor& exp) { in float_power() argument
109 …auto dtype = (at::isComplexType(exp.scalar_type()) || base.isComplex()) ? at::kComplexDouble : at:… in float_power()
111 return at::pow(casted_base, exp.to(dtype)); in float_power()
114 Tensor float_power(const Tensor& base, const Tensor& exp) { in float_power() argument
115 …auto dtype = (at::isComplexType(base.scalar_type()) || at::isComplexType(exp.scalar_type())) ? at:… in float_power()
116 return at::pow(base.to(dtype), exp.to(dtype)); in float_power()
119 Tensor& float_power_(Tensor& base, const Tensor& exp) { in float_power_() argument
120 …auto dtype = (at::isComplexType(base.scalar_type()) || at::isComplexType(exp.scalar_type())) ? at:… in float_power_()
125 return base.pow_(exp.to(dtype)); in float_power_()
128 Tensor& float_power_(Tensor& base, const Scalar& exp) { in float_power_() argument
129 …auto dtype = (at::isComplexType(base.scalar_type()) || exp.isComplex()) ? at::kComplexDouble : at:… in float_power_()
134 …auto casted_exp = (dtype == at::kComplexDouble) ? Scalar(exp.toComplexDouble()) : Scalar(exp.toDou… in float_power_()