MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / BM_Adam

Function BM_Adam

tensorflow/core/kernels/training_ops_test.cc:254–267  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

252}
253
254static void BM_Adam(int iters, int params, int is_multi_threaded) {
255 const int64 tot = static_cast<int64>(iters) * params;
256 testing::ItemsProcessed(tot);
257 testing::BytesProcessed(tot * sizeof(float));
258 Graph* init;
259 Graph* train;
260 Adam(params, &init, &train);
261 if (is_multi_threaded) {
262 // Use max thread number if test performance.
263 test::Benchmark("cpu", train, nullptr, init).Run(iters);
264 } else {
265 test::Benchmark("cpu", train, GetOptions(), init).Run(iters);
266 }
267}
268BENCHMARK(BM_Adam)->ArgPair(128 << 10, 0)->ArgPair(256 << 10, 0);
269BENCHMARK(BM_Adam)->ArgPair(256 << 5, 1)->ArgPair(256 << 16, 1);
270

Callers

nothing calls this directly

Calls 6

ItemsProcessedFunction · 0.85
BytesProcessedFunction · 0.85
AdamFunction · 0.70
GetOptionsFunction · 0.70
BenchmarkClass · 0.50
RunMethod · 0.45

Tested by

no test coverage detected