def get_agent_value_estimate(agent, state, action):
    """
    Obtains the agent's value estimate for a particular state and action.

    Args:
        state (torch.Tensor): state of size [batch_size, n_state_dims]
        action (torch.Tensor): action of size [batch_size, n_action_dims]

    Returns a dictionary of action-value estimates:
        direct: the estimate using the Q-network, size [batch_size]
        estimate: the full estimate (using the model), size [batch_size]
    """
    agent.reset(); agent.eval()
    state = state.to(agent.device); action = action.to(agent.device)
    direct_estimate = agent.q_value_estimator(agent, state, action, direct=True).detach().view(-1).cpu().numpy()
    estimate = agent.q_value_estimator(agent, state, action).detach().view(-1).cpu().numpy()
    return {'direct': direct_estimate, 'estimate': estimate}