You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's hard to see, but in the original spec there's a semi-colon to distinguish the features for POS tags from words, tags, and labels. The feature spec must match the rest of the arguments:
Here you see there are three feature groups, and the order is important. Otherwise the model will get feature values that don't correspond to the embedding matrix size, and you get segfaults.
So the solution is:
Make sure you have semi-colons for each group of features
[before]
Parameter {
name: 'brain_parser_features'
value: 'input.word input(1).word input(2).word input(3).word stack.word stack(1).word stack(2).word stack(3).word stack.child(1).word stack.child(1).sibling(-1).word stack.child(-1).word stack.child(-1).sibling(1).word stack(1).child(1).word stack(1).child(1).sibling(-1).word stack(1).child(-1).word stack(1).child(-1).sibling(1).word stack.child(2).word stack.child(-2).word stack(1).child(2).word stack(1).child(-2).word;input.tag input(1).tag input(2).tag input(3).tag stack.tag stack(1).tag stack(2).tag stack(3).tag stack.child(1).tag stack.child(1).sibling(-1).tag stack.child(-1).tag stack.child(-1).sibling(1).tag stack(1).child(1).tag stack(1).child(1).sibling(-1).tag stack(1).child(-1).tag stack(1).child(-1).sibling(1).tag stack.child(2).tag stack.child(-2).tag stack(1).child(2).tag stack(1).child(-2).tag;stack.child(1).label stack.child(1).sibling(-1).label stack.child(-1).label stack.child(-1).sibling(1).label stack(1).child(1).label stack(1).child(1).sibling(-1).label stack(1).child(-1).label stack(1).child(-1).sibling(1).label stack.child(2).label stack.child(-2).label stack(1).child(2).label stack(1).child(-2).label'
}
[after]
Parameter {
name: 'brain_parser_features'
value: 'input.tag input(1).tag input(2).tag input(3).tag stack.tag stack(1).tag stack(2).tag stack(3).tag input.word input(1).word input(2).word input(3).word stack.word stack(1).word stack(2).word stack(3).word '
}
....
...
./train_sejong.sh: line 129: 2808 segmentation fault ${BINDIR}/parser_trainer --arg_prefix=brain_parser --batch_size=${BATCH_SIZE} --compute_lexicon --decay_steps=4400 --graph_builder=greedy --hidden_layer_sizes=${HIDDEN_LAYER_SIZES} --learning_rate=0.08 --momentum=0.85 --beam_size=1 --output_path=${TMP_DIR} --task_context=${TMP_DIR}/context --projectivize_training_set --training_corpus=tagged-training-corpus --tuning_corpus=tagged-tuning-corpus --params=${LP_PARAMS} --num_epochs=3 --report_every=100 --checkpoint_every=1000 --logtostderr
is there any rules for constructing features?
The text was updated successfully, but these errors were encountered: