MCPcopy Index your code
hub / github.com/PaddlePaddle/PaddleRec / WrapperThread

Class WrapperThread

tools/inference/python/slot_dnn_infer_dataloader.py:228–240  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

226
227
228class WrapperThread(Thread):
229 def __init__(self, func, cost_time, thread_id, args):
230 super(WrapperThread, self).__init__()
231 self.func = func
232 self.cost_time = cost_time
233 self.thread_id = thread_id
234 self.args = args
235
236 def run(self):
237 self.result = self.func(self.cost_time, self.thread_id, self.args)
238
239 def get_result(self):
240 return self.result
241
242
243def parse_args():

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected