MCPcopy Create free account
hub / github.com/BindsNET/bindsnet / set_batch_size

Method set_batch_size

bindsnet/network/nodes.py:297–305  ·  view source on GitHub ↗

Sets mini-batch size. Called when layer is added to a network. :param batch_size: Mini-batch size.

(self, batch_size)

Source from the content-addressed store, hash-verified

295 super().reset_state_variables()
296
297 def set_batch_size(self, batch_size) -> None:
298 # language=rst
299 """
300 Sets mini-batch size. Called when layer is added to a network.
301
302 :param batch_size: Mini-batch size.
303 """
304 super().set_batch_size(batch_size=batch_size)
305 self.v = torch.zeros(batch_size, *self.shape, device=self.v.device)
306
307
308class IFNodes(Nodes):

Callers

nothing calls this directly

Calls 1

set_batch_sizeMethod · 0.45

Tested by

no test coverage detected