mirror of
https://github.com/explosion/spaCy.git
synced 2025-10-24 12:41:23 +03:00
The helper method state.B(1) gets the index of the first token of the buffer, or -1 if no such token exists. Normally this is safe because we pass this to functions like state.safe_get(), which returns an empty token. Here we used it directly as an array index, which is not okay! This error may have been the cause of out-of-bounds access errors during training. Similar errors may still be around, so much be hunted down. Hunting this one down took a long time...I printed out values across training runs and diffed, looking for points of divergence between runs, when no randomness should be allowed. |
||
|---|---|---|
| .. | ||
| __init__.pxd | ||
| __init__.py | ||
| _beam_utils.pxd | ||
| _beam_utils.pyx | ||
| _parser_model.pxd | ||
| _parser_model.pyx | ||
| _state.pxd | ||
| _state.pyx | ||
| arc_eager.pxd | ||
| arc_eager.pyx | ||
| ner.pxd | ||
| ner.pyx | ||
| nn_parser.pxd | ||
| nn_parser.pyx | ||
| nonproj.pxd | ||
| nonproj.pyx | ||
| stateclass.pxd | ||
| stateclass.pyx | ||
| transition_system.pxd | ||
| transition_system.pyx | ||