richliao / textClassifier

Text classifier for Hierarchical Attention Networks for Document Classification
Apache License 2.0
1.07k stars 379 forks source link

ValueError #43

Open jyostnab opened 4 years ago

jyostnab commented 4 years ago

ValueError: Dimension 1 in both shapes must be equal, but are 100 and 10000. Shapes are [?,100] and [?,10000]. for 'bidirectional_20/while/Select' (op: 'Select') with input shapes: [?,10000], [?,100], [?,100].

sauteed-mackerel commented 4 years ago

Which notebook are you running? If HATT, there is a known issue regarding mask handling by the custom Attention layer. Try disabling the mask for the custom layer.

https://github.com/richliao/textClassifier/blob/master/textClassifierHATT.py#L153 Change to return None.