MCPcopy Create free account
hub / github.com/MegEngine/MegFlow / exec

Method exec

flow-python/examples/basis_function/profile/sink.py:14–23  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

12 self.count = 0
13
14 def exec(self):
15 envelope = self.inp.recv()
16
17 if envelope is not None:
18 self.count += 1
19 if self.count == self.data_n:
20 start = envelope.msg['time']
21 end = time.perf_counter()
22 elapsed = end - start
23 print('Time elapsed is {} ms for {} messages, {} nodes '.format(elapsed*1000, self.data_n, self.node_n))
24

Callers

nothing calls this directly

Calls 1

recvMethod · 0.45

Tested by

no test coverage detected