Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@tc-mateus
Copy link
Contributor

Description

Implemented a new method for inverse PCA, similar to sklearn.decomposition.PCA.inverse_transform()

@tc-mateus tc-mateus changed the title feat: inverse pca implement Feat: Implement Inverse PCA function Aug 7, 2023
@YuhanLiin
Copy link
Collaborator

Can you update to latest master?

/// Transform data back to its original space
pub fn inverse_transform(
&self,
prediction: ArrayBase<ndarray::OwnedRepr<f64>, ndarray::Dim<[usize; 2]>>,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can use Array2<f64>

pub fn inverse_transform(
&self,
prediction: ArrayBase<ndarray::OwnedRepr<f64>, ndarray::Dim<[usize; 2]>>,
) -> ArrayBase<ndarray::OwnedRepr<f64>, ndarray::Dim<[usize; 2]>> {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also Array2<f64>

@bytesnake bytesnake merged commit b807674 into rust-ml:master Jul 3, 2024
@bytesnake
Copy link
Member

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants