26 lines
476 B
Python
26 lines
476 B
Python
#!/usr/bin/env python
|
|
|
|
import sys
|
|
|
|
from multiprocessing.managers import BaseManager
|
|
|
|
import numpy as np
|
|
|
|
import interp.bootstrap
|
|
|
|
class QueueManager(BaseManager): pass
|
|
QueueManager.register('get_inqueue' )
|
|
|
|
m = QueueManager(address=('gannon', 50000), authkey='asdf')
|
|
m.connect()
|
|
|
|
if __name__ == '__main__':
|
|
start = int(sys.argv[1])
|
|
end = int(sys.argv[2])
|
|
|
|
inq = m.get_inqueue()
|
|
|
|
for i in xrange(start, end + 1):
|
|
X = np.random.random((1,3))[0]
|
|
inq.put((i,X))
|