We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4d5c370 commit 3edaeebCopy full SHA for 3edaeeb
pvnet/models/multimodal/site_encoders/encoders.py
@@ -74,24 +74,24 @@ def __init__(
74
)
75
76
def _calculate_attention(self, x):
77
- i=0
+ i = 0
78
for key in x.keys():
79
- if(i==17):
80
- ans=key
+ if i == 17:
+ ans = key
81
print(key, type(key))
82
- i+=1
+ i += 1
83
gsp_ids = x[ans].squeeze().int()
84
attention = self._attention_network(gsp_ids)
85
return attention
86
87
def _encode_value(self, x):
88
# Shape: [batch size, sequence length, PV site]
89
90
91
- if(i==6):
92
+ if i == 6:
93
94
95
pv_site_seqs = x[ans].float()
96
batch_size = pv_site_seqs.shape[0]
97
0 commit comments