MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / get

Method get

imperative/python/megengine/data/tools/_queue.py:158–168  ·  view source on GitHub ↗
(self, block=True, timeout=None)

Source from the content-addressed store, hash-verified

156 raise queue.Full
157
158 def get(self, block=True, timeout=None):
159 if self.client is None:
160 self.client = plasma.connect(self.socket_name)
161 object_id = self.queue.get(block, timeout)
162 if not self.client.contains(object_id):
163 exc_type = "ObjectIDGetError"
164 data = (self.get_error(exc_type),)
165 else:
166 data = self.client.get(object_id)
167 self.client.delete([object_id])
168 return data
169
170 def qsize(self):
171 return self.queue.qsize()

Callers 10

check_is_gradMethod · 0.45
check_remote_tracerMethod · 0.45
user_getMethod · 0.45
bcast_valMethod · 0.45
__init__Method · 0.45
_bcast_tracer_stateFunction · 0.45
dataloader.pyFile · 0.45
_try_get_dataMethod · 0.45
_worker_loopFunction · 0.45
__init__Method · 0.45

Calls 2

get_errorMethod · 0.95
connectMethod · 0.45

Tested by

no test coverage detected