de46464aa3595c0fcb622ceaf2248eb9266e46e8,python/ray/experimental/queue.py,Queue,get,#Queue#Any#Any#,77
Before Change
// Polling
// Use a not_empty condition variable or return a promise?
success, item = ray.get(self.actor.get.remote())
while not success:
// Consider adding time.sleep here
success, item = ray.get(self.actor.get.remote())
elif timeout < 0:
raise ValueError(""timeout" must be a non-negative number")
else:
endtime = time.time() + timeout
After Change
if not block:
try:
return ray.get(self.actor.get_nowait.remote())
except asyncio.QueueEmpty:
raise Empty
else:
if timeout is not None and timeout < 0:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances
Project Name: ray-project/ray
Commit Name: de46464aa3595c0fcb622ceaf2248eb9266e46e8
Time: 2020-08-19
Author: architkulkarni@users.noreply.github.com
File Name: python/ray/experimental/queue.py
Class Name: Queue
Method Name: get
Project Name: keras-team/keras
Commit Name: 98d49754edd5b5757fb7c37c8a3cdc9a65d6f238
Time: 2015-07-20
Author: michael.d.oliver@gmail.com
File Name: examples/lstm_text_generation.py
Class Name:
Method Name: sample
Project Name: NTMC-Community/MatchZoo
Commit Name: e9e80a1f4502d336414049a87a9a7f3252d072c4
Time: 2018-06-27
Author: kingbolanda@live.com
File Name: matchzoo/preprocessors.py
Class Name: NgramLetterUnit
Method Name: transform