Skip to content

[tune] Make Trainable API clearer/cache state across workers #10305

@michaelitvin

Description

@michaelitvin

I need to pass params to the constructor of my Trainable subclass.
In the Trainable.__init__ docstring it says that I should prefer providing a build() method rather than my own __init__.
Why? Who would use build() and when?

-> Also, there is the fact that PyCharm wouldn't appreciate any instance variables I'd declare inside build() but not inside __init__().

Metadata

Metadata

Assignees

Labels

P1Issue that should be fixed within a few weeksdocsAn issue or change related to documentationenhancementRequest for new feature and/or capabilitytuneTune-related issues

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions