def infer_action(self, raw_obs, ids, policy='e_greedy', eps=0, block=True):
        """ infer action

        Parameters
        ----------
        policy: str
            can be 'e_greedy' or 'greedy'
        eps: float
            used when policy is 'e_greedy'
        block: bool
            if it is True, the function call will block, and return actions
            if it is False, the function call won't block, the caller
                            must call fetch_action() to get actions

        Returns
        -------
        actions: numpy array (int32)
            see above
        """

        package = NDArrayPackage(raw_obs[0], raw_obs[1], ids)
        self.conn.send(["act", policy, eps, package.info])
        package.send_to(self.conn, use_thread=True)

        if block:
            info = self.conn.recv()
            return NDArrayPackage(info).recv_from(self.conn)[0]
        else:
            return None
 infer action

        Parameters
        ----------
        policy: str
            can be 'e_greedy' or 'greedy'
        eps: float
            used when policy is 'e_greedy'
        block: bool
            if it is True, the function call will block, and return actions
            if it is False, the function call won't block, the caller
                            must call fetch_action() to get actions

        Returns
        -------
        actions: numpy array (int32)
            see above
        
python/magent/model.py