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

Add candle-nn::Sequential::new() constructor #2801

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

slckl
Copy link
Contributor

@slckl slckl commented Mar 10, 2025

Pretty much all the layers in candle-nn implement a ::new() constructor, which follows rust conventions.

I was a bit surprised to see that nn::Sequential is an exception to this, having the sequential::seq() function as the only method of construction.

This PR adds a ::new() to nn::Sequential, hopefully making it somewhat more familiar to those new to candle.

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.

1 participant