def __create_action(self, main_root):
		action_dir = os.path.join(main_root, 'action')
		safe_mkdir(action_dir)

		actions = set()
		for unit, param in self.__task.data['workflow'].items():
			actions.add(param['type'])
		self.__action_mgr.create_actions(actions, action_dir)
def _cost_gp_withGradients(self,x):
        """
        Predicts the time cost and its gradient of evaluating the function at x.
        """
        m, _, dmdx, _= self.cost_model.predict_withGradients(x)
        return np.exp(m), np.exp(m)*dmdx