MCPcopy Create free account
hub / github.com/dmlc/parameter_server / push

Method push

src/util/threadsafe_queue.h:19–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17 threadsafe_queue() {}
18
19 void push(T new_value) {
20 std::lock_guard<std::mutex> lk(mut);
21 data_queue.push(std::move(new_value));
22 data_cond.notify_all();
23 }
24
25 void wait_and_pop(T& value) {
26 std::unique_lock<std::mutex> lk(mut);

Callers 5

computeGradientMethod · 0.45
computeGradientMethod · 0.45
queueMethod · 0.45
preprocessDataMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected