Home
last modified time | relevance | path

Searched refs:WeightedPicker (Results 1 – 4 of 4) sorted by relevance

/external/tensorflow/tensorflow/core/lib/random/
Dweighted_picker_test.cc32 static void CheckUniform(SimplePhilox* rnd, WeightedPicker* picker, int trials);
33 static void CheckSkewed(SimplePhilox* rnd, WeightedPicker* picker, int trials);
36 TEST(WeightedPicker, Simple) { in TEST() argument
42 WeightedPicker picker(0); in TEST()
48 WeightedPicker picker(1); in TEST()
56 WeightedPicker picker(0); in TEST()
65 WeightedPicker picker(1); in TEST()
74 WeightedPicker picker(1); in TEST()
92 TEST(WeightedPicker, BigWeights) { in TEST() argument
96 WeightedPicker picker(2); in TEST()
[all …]
Dweighted_picker.cc26 WeightedPicker::WeightedPicker(int N) { in WeightedPicker() function in tensorflow::random::WeightedPicker
45 WeightedPicker::~WeightedPicker() { in ~WeightedPicker()
100 int WeightedPicker::Pick(SimplePhilox* rnd) const { in Pick()
109 int WeightedPicker::PickAt(int32 weight_index) const { in PickAt()
133 void WeightedPicker::set_weight(int index, int32 weight) { in set_weight()
145 void WeightedPicker::SetAllWeights(int32 weight) { in SetAllWeights()
155 void WeightedPicker::SetWeightsFromArray(int N, const int32* weights) { in SetWeightsFromArray()
167 void WeightedPicker::RebuildTreeWeights() { in RebuildTreeWeights()
177 void WeightedPicker::Append(int32 weight) { in Append()
182 void WeightedPicker::Resize(int new_size) { in Resize()
[all …]
Dweighted_picker.h41 class WeightedPicker {
45 explicit WeightedPicker(int N);
48 ~WeightedPicker();
117 TF_DISALLOW_COPY_AND_ASSIGN(WeightedPicker);
120 inline int32 WeightedPicker::get_weight(int index) const { in get_weight()
126 inline int32 WeightedPicker::total_weight() const { return level_[0][0]; } in total_weight()
128 inline int WeightedPicker::num_elements() const { return N_; } in num_elements()
/external/tensorflow/tensorflow/core/kernels/
Drange_sampler.h177 random::WeightedPicker picker_;