|
|
|
|
|
|
embeddings.append(var_len_processor(encoded_self, var_len_input)) |
|
|
|
qkv = torch.cat(embeddings, dim=1) |
|
|
|
attention_embedding = self.rsa(qkv, masks) |
|
|
|
if encoded_self is None: |
|
|
|
if encoded_self.shape[1] == 0: |
|
|
|
if encoded_self is None: |
|
|
|
if encoded_self.shape[1] == 0: |
|
|
|
raise Exception("No valid inputs to network.") |
|
|
|
|
|
|
|
# Constants don't work in Barracuda |
|
|
|