fynance.models.neural_network.BaseNeuralNet.buffers¶
-
BaseNeuralNet.
buffers
(recurse=True)¶ Returns an iterator over module buffers.
- Args:
- recurse (bool): if True, then yields buffers of this module
- and all submodules. Otherwise, yields only buffers that are direct members of this module.
- Yields:
- torch.Tensor: module buffer
Example:
>>> for buf in model.buffers(): >>> print(type(buf.data), buf.size()) <class 'torch.FloatTensor'> (20L,) <class 'torch.FloatTensor'> (20L, 1L, 5L, 5L)