Search notes:

torch.nn.Module: initialization (__init__)

__init__ intializes the module's internal state (which, as per comment in the source code, is shared by torch.nn.Module and ScriptModule).
In particular, it sets training to True and the following member so an empty OrderedDict:
_parameters
_buffers
_non_persistent_buffers_set
_backward_pre_hooks
_backward_hooks
_is_full_backward_hook
_forward_hooks
_forward_hooks_with_kwargs
_forward_pre_hooks
_forward_pre_hooks_with_kwargs
_state_dict_hooks
_state_dict_pre_hooks
_load_state_dict_pre_hooks
_load_state_dict_post_hooks
_modules

Index