Exemplo n.º 1
0
def main():
    q = DistribOutputPipe('jacinle.test')
    with control(pipes=[q]):
        while True:
            data = {
                'msg': 'hello',
                'current': time.time(),
                'data': np.zeros(shape=(128, 224, 224, 3), dtype='float32')
            }
            print('RFlow sending', data['current'])
            q.put(data)
Exemplo n.º 2
0
def recv_thread():
    q = DistribInputPipe('jacinle.test')
    with control(pipes=[q]):
        while True:
            q.get()
            next(counter)
Exemplo n.º 3
0
def main():
    q = DistribInputPipe('jacinle.test')
    with control(pipes=[q]):
        for i in range(10):
            stprint(q.get())
            time.sleep(1)