Update bert_layers.py
Browse files- bert_layers.py +7 -7
bert_layers.py
CHANGED
@@ -939,19 +939,19 @@ class BertForSequenceClassification(BertPreTrainedModel):
|
|
939 |
all_attention_probs = outputs[3]
|
940 |
|
941 |
try:
|
942 |
-
print(f'outputs[2] AFTER reassignment SHAPE: {outputs[3][0].shape} ')
|
943 |
except:
|
944 |
-
print(print(f'outputs[2] AFTER reassignment LENGTH: {len(outputs[3][0])} '))
|
945 |
|
946 |
|
947 |
|
948 |
try:
|
949 |
-
print(f'all_attention_weights last: {all_attention_probs.shape}')
|
950 |
except:
|
951 |
try:
|
952 |
-
print(f'last first except: {all_attention_probs[0].shape}')
|
953 |
except:
|
954 |
-
print(f'last second except: {len(all_attention_probs[0])}')
|
955 |
|
956 |
|
957 |
pooled_output = self.dropout(pooled_output)
|
@@ -991,9 +991,9 @@ class BertForSequenceClassification(BertPreTrainedModel):
|
|
991 |
|
992 |
# print(outputs.attentions)
|
993 |
try:
|
994 |
-
print(f'not stacked final attention SHAPE: {outputs[3][0].shape}')
|
995 |
except:
|
996 |
-
print(f'not stacked final attention LEN: {len(outputs[3])}')
|
997 |
|
998 |
# try:
|
999 |
# print(f'STACKED final attention SHAPE: {(outputs.attentions).shape}')
|
|
|
939 |
all_attention_probs = outputs[3]
|
940 |
|
941 |
try:
|
942 |
+
print(f'outputs[2] AFTER reassignment probsss SHAPE: {outputs[3][0].shape} ')
|
943 |
except:
|
944 |
+
print(print(f'outputs[2] AFTER reassignment probsss LENGTH: {len(outputs[3][0])} '))
|
945 |
|
946 |
|
947 |
|
948 |
try:
|
949 |
+
print(f'all_attention_weights probsss last: {all_attention_probs.shape}')
|
950 |
except:
|
951 |
try:
|
952 |
+
print(f'last first except probsss: {all_attention_probs[0].shape}')
|
953 |
except:
|
954 |
+
print(f'last second except probsss: {len(all_attention_probs[0])}')
|
955 |
|
956 |
|
957 |
pooled_output = self.dropout(pooled_output)
|
|
|
991 |
|
992 |
# print(outputs.attentions)
|
993 |
try:
|
994 |
+
print(f'not stacked final attention probsss SHAPE: {outputs[3][0].shape}')
|
995 |
except:
|
996 |
+
print(f'not stacked final attention probsss LEN: {len(outputs[3])}')
|
997 |
|
998 |
# try:
|
999 |
# print(f'STACKED final attention SHAPE: {(outputs.attentions).shape}')
|