import numpy as np import nest_asyncio nest_asyncio.apply() import asyncio from functools import partial from teeport import Teeport from opt.processors.gps_predictor import process params = dict(theta=np.array([[0.4]]), var='auto', sigma_n=np.array([[1e-4]]), C=1e9) teeport = Teeport('ws://lambda-sp3:8090/') teeport.run_processor(partial(process, params=params), 'GPS Predictor: no opt') print('processor is running...') loop = asyncio.get_event_loop() loop.run_until_complete(teeport.processors[0].task)
import numpy as np import nest_asyncio nest_asyncio.apply() import asyncio from functools import partial from teeport import Teeport from opt.processors.gpy_predictor import process teeport = Teeport('ws://lambda-sp3:8090/') teeport.run_processor(partial(process, configs={}), 'GPy Predictor') print('processor is running...') loop = asyncio.get_event_loop() loop.run_until_complete(teeport.processors[0].task)
import nest_asyncio nest_asyncio.apply() import asyncio from teeport import Teeport from opt.processors.gpy_predictor import process teeport = Teeport('ws://lambda-sp3:8090/') teeport.run_processor(process, 'GPy-Pred', name='GPy Predictor', configs={ 'theta': None, 'var': None, 'sigma_n': None, 'ret_grad': False }) print('processor is running...') loop = asyncio.get_event_loop() loop.run_until_complete(teeport.processors[0].task)
import numpy as np import nest_asyncio nest_asyncio.apply() import asyncio from functools import partial from teeport import Teeport from opt.processors.gpy_predictor import process teeport = Teeport('ws://lambda-sp3:8090/') teeport.run_processor(partial(process, configs={'ret_grad': True}), 'GPy Predictor with Grad') print('processor is running...') loop = asyncio.get_event_loop() loop.run_until_complete(teeport.processors[0].task)