Home
last modified time | relevance | path

Searched refs:mean_ (Results 1 – 25 of 45) sorted by relevance

12

/third_party/boost/boost/histogram/accumulators/
Dmean.hpp37 : sum_{o.sum_}, mean_{o.mean_}, sum_of_deltas_squared_{o.sum_of_deltas_squared_} {} in mean()
41 : sum_(n), mean_(mean), sum_of_deltas_squared_(variance * (n - 1)) {} in mean()
46 const auto delta = x - mean_; in operator ()()
47 mean_ += delta / sum_; in operator ()()
48 sum_of_deltas_squared_ += delta * (x - mean_); in operator ()()
54 const auto delta = x - mean_; in operator ()()
55 mean_ += w.value * delta / sum_; in operator ()()
56 sum_of_deltas_squared_ += w.value * delta * (x - mean_); in operator ()()
62 const auto tmp = mean_ * sum_ + rhs.mean_ * rhs.sum_; in operator +=()
64 mean_ = tmp / sum_; in operator +=()
[all …]
/third_party/abseil-cpp/absl/random/
Dpoisson_distribution.h63 double mean() const { return mean_; } in mean()
66 return a.mean_ == b.mean_;
76 double mean_; variable
134 : mean_(mean), split_(0) { in param_type()
141 if (mean_ < 10) { in param_type()
144 emu_ = std::exp(-mean_); in param_type()
145 } else if (mean_ <= 50) { in param_type()
147 split_ = 1 + static_cast<int>(mean_ / 10.0); in param_type()
148 emu_ = std::exp(-mean_ / static_cast<double>(split_)); in param_type()
154 lmu_ = std::log(mean_); in param_type()
[all …]
Dpoisson_distribution_test.cc165 explicit PoissonModel(double mean) : mean_(mean) {} in PoissonModel()
167 double mean() const { return mean_; } in mean()
168 double variance() const { return mean_; } in variance()
170 double skew() const { return 1.0 / mean_; } in skew()
171 double kurtosis() const { return 3.0 + 1.0 / mean_; } in kurtosis()
191 ABSL_INTERNAL_LOG(INFO, absl::StrCat("CDF (mean = ", mean_, ")")); in LogCDF()
199 const double mean_; member in __anon10bc306f0111::PoissonModel
215 ABSL_ASSERT(mean_ < 201.0); in InitCDF()
Dgaussian_distribution.h96 : mean_(mean), stddev_(stddev) {} in mean_() function
100 result_type mean() const { return mean_; } in mean()
106 return a.mean_ == b.mean_ && a.stddev_ == b.stddev_;
114 result_type mean_;
/third_party/skia/third_party/externals/abseil-cpp/absl/random/
Dpoisson_distribution.h63 double mean() const { return mean_; } in mean()
66 return a.mean_ == b.mean_;
76 double mean_; variable
134 : mean_(mean), split_(0) { in param_type()
141 if (mean_ < 10) { in param_type()
144 emu_ = std::exp(-mean_); in param_type()
145 } else if (mean_ <= 50) { in param_type()
147 split_ = 1 + static_cast<int>(mean_ / 10.0); in param_type()
148 emu_ = std::exp(-mean_ / static_cast<double>(split_)); in param_type()
154 lmu_ = std::log(mean_); in param_type()
[all …]
Dpoisson_distribution_test.cc165 explicit PoissonModel(double mean) : mean_(mean) {} in PoissonModel()
167 double mean() const { return mean_; } in mean()
168 double variance() const { return mean_; } in variance()
170 double skew() const { return 1.0 / mean_; } in skew()
171 double kurtosis() const { return 3.0 + 1.0 / mean_; } in kurtosis()
191 ABSL_INTERNAL_LOG(INFO, absl::StrCat("CDF (mean = ", mean_, ")")); in LogCDF()
199 const double mean_; member in __anon91352ae40111::PoissonModel
215 ABSL_ASSERT(mean_ < 201.0); in InitCDF()
Dgaussian_distribution.h96 : mean_(mean), stddev_(stddev) {} in mean_() function
100 result_type mean() const { return mean_; } in mean()
106 return a.mean_ == b.mean_ && a.stddev_ == b.stddev_;
114 result_type mean_;
/third_party/boost/boost/accumulators/statistics/
Drolling_mean.hpp65 : mean_(numeric::fdiv(args[sample | Sample()],numeric::one<std::size_t>::value)) in immediate_rolling_mean_impl()
75mean_ -= numeric::fdiv(rolling_window_plus1(args).front()-args[sample],rolling_count(args)); in operator ()()
77mean_ += numeric::fdiv(args[sample]-rolling_window_plus1(args).front(),rolling_count(args)); in operator ()()
81 result_type prev_mean = mean_; in operator ()()
83 mean_ -= numeric::fdiv(prev_mean-args[sample],rolling_count(args)); in operator ()()
85 mean_ += numeric::fdiv(args[sample]-prev_mean,rolling_count(args)); in operator ()()
92 return mean_; in result()
99 ar & mean_; in serialize() local
104 result_type mean_; member
/third_party/mindspore/mindspore/lite/src/delegate/npu/op/
Dbatchnorm_npu.cc67 mean_ = new (std::nothrow) hiai::op::Const(name_ + "_mean"); in SetNPUInputs()
68 if (mean_ == nullptr) { in SetNPUInputs()
73 mean_->set_attr_value(mean_tensor); in SetNPUInputs()
74 batchnorm_->set_input_mean(*mean_); in SetNPUInputs()
102 if (mean_ != nullptr) { in ~BatchnormNPUOp()
103 delete mean_; in ~BatchnormNPUOp()
104 mean_ = nullptr; in ~BatchnormNPUOp()
/third_party/mindspore/mindspore/ccsrc/minddata/dataset/kernels/image/
Dnormalize_op.cc30 NormalizeOp::NormalizeOp(const std::vector<float> &mean, const std::vector<float> &std) : mean_(mea… in NormalizeOp()
33 mean_[i] = mean_[i] / std_[i]; in NormalizeOp()
40 return Normalize(input, output, mean_, std_); in Compute()
45 for (const auto &m : mean_) { in Print()
Dnormalize_pad_op.cc27 Status s = Tensor::CreateFromVector<float>({mean_r, mean_g, mean_b}, &mean_); in NormalizePadOp()
43 return NormalizePad(input, output, mean_, std_, dtype_); in Compute()
47 …out << "NormalizeOp, mean: " << *(mean_.get()) << std::endl << "std: " << *(std_.get()) << std::en… in Print()
/third_party/mindspore/mindspore/ccsrc/minddata/dataset/kernels/ir/vision/
Dnormalize_pad_ir.cc33 : mean_(mean), std_(std), dtype_(dtype) {} in NormalizePadOperation()
40 RETURN_IF_NOT_OK(ValidateVectorMeanStd("NormalizePad", mean_, std_)); in ValidateParams()
53 …return std::make_shared<NormalizePadOp>(mean_[dimension_zero], mean_[dimension_one], mean_[dimensi… in Build()
59 args["mean"] = mean_; in to_json()
Dnormalize_ir.cc27 : mean_(mean), std_(std) {} in NormalizeOperation()
34 RETURN_IF_NOT_OK(ValidateVectorMeanStd("Normalize", mean_, std_)); in ValidateParams()
38 std::shared_ptr<TensorOp> NormalizeOperation::Build() { return std::make_shared<NormalizeOp>(mean_,… in Build()
42 args["mean"] = mean_; in to_json()
Dascend_vision_ir.cc266 : mean_(mean), std_(std) {} in DvppNormalizeOperation()
269 if (mean_.size() != 3) { in ValidateParams()
270 …g err_msg = "DvppNormalization:: mean expecting size 3, got size: " + std::to_string(mean_.size()); in ValidateParams()
279 …if (*min_element(mean_.begin(), mean_.end()) < 0 || *max_element(mean_.begin(), mean_.end()) > 256… in ValidateParams()
299 std::shared_ptr<DvppNormalizeOp> tensor_op = std::make_shared<DvppNormalizeOp>(mean_, std_); in Build()
307 std::transform(mean_.begin(), mean_.end(), std::back_inserter(enlarge_mean_), in to_json()
/third_party/mindspore/mindspore/lite/src/runtime/kernel/arm/fp32/
Dbatchnorm_fp32.cc53 if (mean_ != nullptr) { in FreeMeanAndVariance()
54 free(mean_); in FreeMeanAndVariance()
55 mean_ = nullptr; in FreeMeanAndVariance()
82 mean_ = malloc(in_tensors_.at(SECOND_INPUT)->Size()); in InitConstTensor()
84 if (mean_ == nullptr || variance_ == nullptr) { in InitConstTensor()
95 memcpy(mean_, in_tensor_mean_data, in_tensors_.at(SECOND_INPUT)->Size()); in InitConstTensor()
114 BatchNormFp32(in_tensor_data, mean_, variance_, param, task_id, out_tensor_data); in DoExecute()
Dfused_batchnorm_fp32.cc54 mean_ = malloc(mean->Size()); in InitConstTensor()
56 if (scale_ == nullptr || offset_ == nullptr || mean_ == nullptr || variance_ == nullptr) { in InitConstTensor()
69 memcpy(mean_, mean->data(), mean->Size()); in InitConstTensor()
81 float *current_mean = static_cast<float *>(mean_); in Run()
132 memcpy(mean_, save_mean, in_tensors_.at(FOURTH_INPUT)->Size()); in Eval()
144 FusedBatchNormFp32(in_data, scale_, offset_, mean_, variance_, param, task_id, out_data); in DoExecute()
/third_party/mindspore/mindspore/lite/src/runtime/kernel/opencl/kernel/
Dbatchnorm.cc116 if (allocator->UnmapBuffer(mean_) != RET_OK) { in UnmapBuffer()
133 if (allocator->MapBuffer(mean_, CL_MAP_WRITE, nullptr, true) == nullptr) { in MapBuffer()
159 mean_ = allocator->Malloc(weight_size, lite::opencl::MemType::BUF); in Initweight()
160 if (mean_ == nullptr) { in Initweight()
176 memset(mean_, 0x00, weight_size); in Initweight()
186 memcpy(mean_, in_tensors_.at(3)->data(), weight_size); in Initweight()
191 auto mean_fp32 = reinterpret_cast<float *>(mean_); in Initweight()
210 auto mean_fp16 = reinterpret_cast<float16_t *>(mean_); in Initweight()
227 memcpy(mean_, in_tensors_.at(3)->data(), weight_size); in Initweight()
283 if (ocl_runtime_->SetKernelArg(kernel_, arg_cn++, mean_, true) != CL_SUCCESS) { in Run()
Dlayer_norm.cc214 mean_ = allocator->Malloc(mean_size, lite::opencl::MemType::BUF); in Prepare()
215 if (mean_ == nullptr) { in Prepare()
257 if (ocl_runtime_->SetKernelArg(kernel_mean_var_, arg1_cn++, mean_, true) != CL_SUCCESS) { in Run()
276 if (ocl_runtime_->SetKernelArg(kernel_, arg_cn++, mean_, true) != CL_SUCCESS) { in Run()
/third_party/mindspore/mindspore/lite/src/runtime/kernel/arm/fp16/
Dbatchnorm_fp16.cc39 mean_ = malloc(mean_fp32->ElementsNum() * sizeof(float16_t)); in InitConstTensor()
41 if (mean_ == nullptr || variance_ == nullptr) { in InitConstTensor()
47 …loat32ToFloat16(reinterpret_cast<float *>(mean_fp32->data()), reinterpret_cast<float16_t *>(mean_), in InitConstTensor()
88 BatchNormFp16(input_, mean_, variance_, param, task_id, output_); in DoExecute()
/third_party/mindspore/mindspore/lite/src/runtime/kernel/opencl/cl/
Dlayer_norm.cl21 __kernel void ComputeMeanVarAxis3NHWC4(__read_only image2d_t src_data, __global FLT *mean_, __globa…
69 mean_[position] = mean;
74 … __global FLT *mean_, __global FLT *variance_, __global FLT *gamma_,
101 …result.x = ((result_in.x - mean_[postion_mv]) / sqrt(variance_[postion_mv] + epsilon_)) * gamma_[p…
103 …result.y = ((result_in.y - mean_[postion_mv]) / sqrt(variance_[postion_mv] + epsilon_)) * gamma_[p…
105 …result.z = ((result_in.z - mean_[postion_mv]) / sqrt(variance_[postion_mv] + epsilon_)) * gamma_[p…
107 …result.w = ((result_in.w - mean_[postion_mv]) / sqrt(variance_[postion_mv] + epsilon_)) * gamma_[p…
/third_party/mindspore/mindspore/ccsrc/minddata/dataset/kernels/image/dvpp/
Ddvpp_normalize_op.h35 : mean_(std::move(mean)), std_(std::move(std)) {} in DvppNormalizeOp()
46 std::vector<float> mean_;
/third_party/mindspore/mindspore/ccsrc/backend/optimizer/gpu/
Dbatch_norm_relu_fusion.h30 mean_ = std::make_shared<Var>();
42 VarPtr mean_; variable
Dpost_batch_norm_add_relu_fusion.h31 mean_ = std::make_shared<Var>();
44 VarPtr mean_; variable
Dbatch_norm_add_relu_fusion.h31 mean_ = std::make_shared<Var>();
44 VarPtr mean_; variable
Dbatch_norm_add_relu_grad_fusion.h33 mean_ = std::make_shared<Var>();
49 VarPtr mean_; variable

12