def transform(self, embedding: Tensor) -> Tensor:
        """Project the data by using matrix product with the random matrix.

        Args:
            embedding (Tensor): Embedding of shape (n_samples, n_features)
                The input data to project into a smaller dimensional space

        Returns:
            projected_embedding (Tensor): Matrix of shape
                (n_samples, n_components) Projected array.
        """
        if self.random_matrix is None:
            raise NotFittedError(
                "`fit()` has not been called on RandomProjection yet.")

        projected_embedding = embedding @self.random_matrix.T
        return projected_embedding
Project the data by using matrix product with the random matrix.

        Args:
            embedding (Tensor): Embedding of shape (n_samples, n_features)
                The input data to project into a smaller dimensional space

        Returns:
            projected_embedding (Tensor): Matrix of shape
                (n_samples, n_components) Projected array.
        
contrib/QualityInspector/qinspector/uad/utils/random_projection.py