MCPcopy Create free account
hub / github.com/Anoise/WTFlib / __init__

Method __init__

LDPS_Graph/models/Mvstgn.py:577–579  ·  view source on GitHub ↗
(self, d_hid, n_position=20)

Source from the content-addressed store, hash-verified

575class PositionalEncoding(nn.Module):
576
577 def __init__(self, d_hid, n_position=20):
578 super(PositionalEncoding, self).__init__()
579 self.register_buffer('pos_table', self._get_sinusoid_encoding_table(n_position, d_hid))
580
581 def _get_sinusoid_encoding_table(self, n_position, d_hid):
582 def get_position_angle_vec(position):

Callers

nothing calls this directly

Calls 2

__init__Method · 0.45

Tested by

no test coverage detected