/external/tensorflow/tensorflow/python/distribute/ |
D | parameter_server_strategy_v2.py | 622 def init_shard_fn(shard_index): argument 625 logging.WARN, _INEFFICIENT_INIT_WARNING % name, shard_index == 0 and 627 return initial_value[offsets[shard_index]:offsets[shard_index + 1]] 628 partition_shape = (offsets[shard_index + 1] - 629 offsets[shard_index],) + shape[1:] 630 partition_offset = (offsets[shard_index],) + (0,) * len(shape[1:]) 652 shard_index == 0 and 654 return value[offsets[shard_index]:offsets[shard_index + 1]]
|
/external/tensorflow/tensorflow/core/kernels/data/experimental/ |
D | io_ops.cc | 111 int64 shard_index = -1; in WriteData() local 113 &iter_ctx, instantiated_captured_func.get(), element, &shard_index)); in WriteData() 116 if (writers.count(shard_index) == 0) { in WriteData() 118 snapshot_util::ShardDirectory(run_dir, shard_index); in WriteData() 120 ctx->env(), shard_index, snapshot_shard_directory, in WriteData() 126 writers.insert({shard_index, std::move(writer_thread)}); in WriteData() 128 writers[shard_index]->Write(element); in WriteData() 144 int64* shard_index) { in GetShardIndex() argument 146 *shard_index = (*shard_index + 1) % port::NumSchedulableCPUs(); in GetShardIndex() 157 *shard_index = output_tensors[0].flat<int64>()(0); in GetShardIndex()
|
D | io_ops.h | 50 const std::vector<Tensor>& element, int64* shard_index);
|
D | snapshot_dataset_op.cc | 258 int64* shard_index) TF_EXCLUSIVE_LOCKS_REQUIRED(mu_); 683 int64* shard_index) { in GetShardIndex() argument 696 *shard_index = output_tensors[0].flat<int64>()(0); in GetShardIndex() 748 int64 shard_index = 0; in GetNextInternal() local 749 TF_RETURN_IF_ERROR(GetShardIndex(ctx, *out_tensors, &shard_index)); in GetNextInternal() 752 if (writers_.count(shard_index) == 0) { in GetNextInternal() 754 snapshot_util::ShardDirectory(run_dir_, shard_index); in GetNextInternal() 756 ctx->env(), shard_index, snapshot_shard_directory, in GetNextInternal() 765 writers_.insert({shard_index, std::move(writer)}); in GetNextInternal() 767 current_writer = writers_[shard_index].get(); in GetNextInternal()
|
/external/tensorflow/tensorflow/python/tpu/ |
D | tpu_sharding.py | 192 def get_sharded_shape(self, shape, shard_index=None): argument 219 if shard_index is not None: 220 if shard_index < 0 or shard_index >= self.number_of_shards: 222 (shard_index, self._number_of_shards))
|
D | tpu_sharding_test.py | 100 _ = p.get_sharded_shape([4, 9], shard_index=4) 102 _ = p.get_sharded_shape([4, 9], shard_index=-1) 108 _ = p.get_sharded_shape([4, 10], shard_index=-1)
|
/external/tensorflow/tensorflow/core/kernels/data/ |
D | split_utils.cc | 61 int64 num_shards, int64 shard_index, in ShardingSplitProvider() argument 64 shard_index_(shard_index), in ShardingSplitProvider()
|
D | split_utils.h | 46 ShardingSplitProvider(int64 num_shards, int64 shard_index,
|
/external/rust/crates/crossbeam-utils/src/sync/ |
D | sharded_lock.rs | 228 let shard_index = current_index & (self.shards.len() - 1); in try_read() localVariable 230 match self.shards[shard_index].lock.try_read() { in try_read() 288 let shard_index = current_index & (self.shards.len() - 1); in read() localVariable 290 match self.shards[shard_index].lock.read() { in read()
|
/external/autotest/server/cros/ap_configurators/ |
D | pyauto_utils.py | 170 def Shard(ilist, shard_index, num_shards): argument 179 chunk_start = shard_index * chunk_size 180 if shard_index == num_shards - 1: # Exhaust the remainder in the last shard.
|
/external/tensorflow/tensorflow/core/kernels/ |
D | topk_op_gpu.h | 323 int shard_index = max_element.index; 324 top_k_indices[rank] = entries[shard_index].index; 325 int next_shard_index = shard_index + num_shards; 335 int shard_index = max_element.index; 336 top_k_indices[last_k] = entries[shard_index].index;
|
/external/angle/src/tests/restricted_traces/ |
D | restricted_trace_gold_tests.py | 412 def _shard_tests(tests, shard_count, shard_index): argument 413 return [tests[index] for index in range(shard_index, len(tests), shard_count)] 456 args.shard_index = int(env.pop('GTEST_SHARD_INDEX')) 488 sharded_tests = _shard_tests(tests['traces'], args.shard_count, args.shard_index)
|
/external/googletest/googletest/test/ |
D | googletest-filter-unittest.py | 220 def RunWithSharding(total_shards, shard_index, command): argument 223 extra_env = {SHARD_INDEX_ENV_VAR: str(shard_index),
|
D | gtest_unittest.cc | 1961 for (int shard_index = 0; shard_index < num_shards; shard_index++) { in TEST() local 1962 if (ShouldRunTestOnShard(num_shards, shard_index, test_id)) { in TEST() 1964 prev_selected_shard_index = shard_index; in TEST() 1967 << shard_index << " are both selected to run test " << test_id; in TEST() 1975 for (int shard_index = 0; shard_index < num_shards; shard_index++) { in TEST() local 1979 ShouldRunTestOnShard(num_shards, shard_index, test_id); in TEST()
|
/external/llvm/utils/unittest/googletest/src/ |
D | gtest.cc | 2702 const Int32 shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 2705 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 4281 const Int32 shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 4283 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 4285 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 4288 << kTestShardIndex << " = " << shard_index in ShouldShard() 4293 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 4301 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 4305 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() 4336 bool ShouldRunTestOnShard(int total_shards, int shard_index, int test_id) { in ShouldRunTestOnShard() argument [all …]
|
/external/llvm-project/llvm/utils/unittest/googletest/src/ |
D | gtest.cc | 3071 const Int32 shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 3074 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 4723 const Int32 shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 4725 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 4727 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 4730 << kTestShardIndex << " = " << shard_index in ShouldShard() 4735 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 4743 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 4747 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() 4778 bool ShouldRunTestOnShard(int total_shards, int shard_index, int test_id) { in ShouldRunTestOnShard() argument [all …]
|
/external/libvpx/libvpx/third_party/googletest/src/src/ |
D | gtest.cc | 3140 const Int32 shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 3143 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 5265 const Int32 shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 5267 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 5269 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 5272 << kTestShardIndex << " = " << shard_index in ShouldShard() 5277 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 5285 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 5289 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() 5320 bool ShouldRunTestOnShard(int total_shards, int shard_index, int test_id) { in ShouldRunTestOnShard() argument [all …]
|
/external/libaom/libaom/test/ |
D | test.cmake | 419 foreach(shard_index RANGE ${max_shard_index}) 420 set(test_name "test_${shard_index}") 423 -DGTEST_SHARD_INDEX=${shard_index}
|
/external/rust/crates/quiche/deps/boringssl/src/third_party/googletest/src/ |
D | gtest.cc | 3147 const Int32 shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 3150 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 5364 const Int32 shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 5366 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 5368 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 5371 << kTestShardIndex << " = " << shard_index in ShouldShard() 5376 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 5384 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 5388 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() 5419 bool ShouldRunTestOnShard(int total_shards, int shard_index, int test_id) { in ShouldRunTestOnShard() argument [all …]
|
/external/mesa3d/src/gtest/src/ |
D | gtest.cc | 3156 const Int32 shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 3159 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 5426 const Int32 shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 5428 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 5430 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 5433 << kTestShardIndex << " = " << shard_index in ShouldShard() 5438 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 5446 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 5450 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() 5481 bool ShouldRunTestOnShard(int total_shards, int shard_index, int test_id) { in ShouldRunTestOnShard() argument [all …]
|
/external/googletest/googletest/src/ |
D | gtest.cc | 3403 const int32_t shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 3405 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 5958 const int32_t shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 5960 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 5962 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 5965 << kTestShardIndex << " = " << shard_index in ShouldShard() 5970 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 5978 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 5982 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() 6013 bool ShouldRunTestOnShard(int total_shards, int shard_index, int test_id) { in ShouldRunTestOnShard() argument [all …]
|
/external/libaom/libaom/third_party/googletest/src/googletest/src/ |
D | gtest.cc | 3228 const int32_t shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 3230 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 5467 const int32_t shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 5469 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 5471 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 5473 << kTestShardIndex << " = " << shard_index in ShouldShard() 5479 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 5487 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 5491 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() 5522 bool ShouldRunTestOnShard(int total_shards, int shard_index, int test_id) { in ShouldRunTestOnShard() argument [all …]
|
/external/fmtlib/test/ |
D | gmock-gtest-all.cc | 685 GTEST_API_ bool ShouldRunTestOnShard(int total_shards, int shard_index, 4099 const Int32 shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 4101 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 5722 const Int32 shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 5724 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 5726 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 5728 << kTestShardIndex << " = " << shard_index in ShouldShard() 5734 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 5742 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 5746 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() [all …]
|
/external/rust/crates/grpcio-sys/grpc/third_party/cares/cares/test/gmock-1.8.0/ |
D | gmock-gtest-all.cc | 683 int total_shards, int shard_index, int test_id); 4519 const Int32 shard_index = Int32FromEnvOrDie(kTestShardIndex, -1); in OnTestIterationStart() local 4522 static_cast<int>(shard_index) + 1, in OnTestIterationStart() 6171 const Int32 shard_index = Int32FromEnvOrDie(shard_index_env, -1); in ShouldShard() local 6173 if (total_shards == -1 && shard_index == -1) { in ShouldShard() 6175 } else if (total_shards == -1 && shard_index != -1) { in ShouldShard() 6178 << kTestShardIndex << " = " << shard_index in ShouldShard() 6183 } else if (total_shards != -1 && shard_index == -1) { in ShouldShard() 6191 } else if (shard_index < 0 || shard_index >= total_shards) { in ShouldShard() 6195 << ", but you have " << kTestShardIndex << "=" << shard_index in ShouldShard() [all …]
|
/external/rust/crates/quiche/deps/boringssl/src/third_party/googletest/test/ |
D | gtest_unittest.cc | 1952 for (int shard_index = 0; shard_index < num_shards; shard_index++) { in TEST() local 1953 if (ShouldRunTestOnShard(num_shards, shard_index, test_id)) { in TEST() 1955 prev_selected_shard_index = shard_index; in TEST() 1958 << shard_index << " are both selected to run test " << test_id; in TEST() 1966 for (int shard_index = 0; shard_index < num_shards; shard_index++) { in TEST() local 1970 ShouldRunTestOnShard(num_shards, shard_index, test_id); in TEST()
|