Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change coefs definition for SINDy when using torch #21

Merged
merged 1 commit into from
Dec 21, 2024

Conversation

andersonw1
Copy link
Collaborator

A small change for the preallocation of SINDy coefficients coefs when using torch. As defined, torch.Tensor([n_train, self.ncoefs]) returns a tensor with two entries which are n_train and self.ncoefs. This small change makes it so that we define a tensor of size n_train by self.ncoefs

Copy link
Collaborator

@dreamer2368 dreamer2368 left a comment

Choose a reason for hiding this comment

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

Thanks for this PR. This bug has been in my mind.

@dreamer2368 dreamer2368 merged commit edcd47c into main Dec 21, 2024
1 check passed
@dreamer2368 dreamer2368 deleted the tensor_change branch December 21, 2024 16:57
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.

2 participants