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

Refactor/optim #272

Merged
merged 13 commits into from
Apr 5, 2023
Merged

Refactor/optim #272

merged 13 commits into from
Apr 5, 2023

Conversation

nathanielsimard
Copy link
Member

@nathanielsimard nathanielsimard commented Apr 5, 2023

Refactor how optimizer works.

Now similar to modules, they have their own Record associative type to determine how their state will be saved. There is two optimizer traits, one for simpler implementations and the other more general.

Copy link
Collaborator

@antimora antimora left a comment

Choose a reason for hiding this comment

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

There is one question about serde's empty bound. Not sure if this should be empty on purpose or no bound should be set.

}

#[derive(Serialize, Deserialize)]
#[serde(bound = "")]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should the bound be empty?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, it should, because no matter the generics, Serialize and Deserialize should always be implemented.

}

#[derive(Serialize, Deserialize)]
#[serde(bound = "")]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Same question about the bound

@nathanielsimard nathanielsimard merged commit ca8ee07 into main Apr 5, 2023
@nathanielsimard nathanielsimard deleted the refactor/optim branch April 5, 2023 16:38
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