Adding logging to PCA