def project(self, mean, covariance):
        """
        Project state distribution to measurement space.

        Args
            mean (ndarray): The state's mean vector (8 dimensional array).
            covariance (ndarray): The state's covariance matrix (8x8 dimensional).

        Returns:
            The projected mean and covariance matrix of the given state estimate.
        """
        std = np.array(
            [
                self._std_weight_position * mean[3], self._std_weight_position *
                mean[3], 1e-1, self._std_weight_position * mean[3]
            ],
            dtype=np.float32)

        if use_numba:
            return nb_project(mean, covariance, std, self._update_mat)

        innovation_cov = np.diag(np.square(std))

        mean = np.dot(self._update_mat, mean)
        covariance = np.linalg.multi_dot((self._update_mat, covariance,
                                          self._update_mat.T))
        return mean, covariance + innovation_cov

        Project state distribution to measurement space.

        Args
            mean (ndarray): The state's mean vector (8 dimensional array).
            covariance (ndarray): The state's covariance matrix (8x8 dimensional).

        Returns:
            The projected mean and covariance matrix of the given state estimate.
        
ppdet/modeling/mot/motion/kalman_filter.py