Mojo equivalent of Python class parameters

In Python, you can create a class, say "model" and ask for its parameters using model.parameters. Is there an equivalent for a struct in Mojo? I would like to pass it to something like: torch.optim.Adam(model.parameters(), ...) .
2 Replies
Darkmatter
Darkmatter16h ago
There is not. Static reflection might allow that in the future.
Gennadiy
GennadiyOP15h ago
OK, thanks.
Want results from more Discord servers?
Add your server