Commit 44589fb 1 parent 6d4e8e1 commit 44589fb Copy full SHA for 44589fb
File tree 1 file changed +4
-8
lines changed
1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -249,13 +249,7 @@ cdef class Break:
249
249
elif st.stack_depth() < 1 :
250
250
return False
251
251
else :
252
- prev = st.B_(0 )- 1
253
- if Lexeme.c_check_flag(prev.lex, IS_PUNCT):
254
- return True
255
- elif Lexeme.c_check_flag(prev.lex, IS_SPACE):
256
- return True
257
- else :
258
- return False
252
+ return True
259
253
260
254
@staticmethod
261
255
cdef int transition(StateC* st, attr_t label) nogil:
@@ -292,7 +286,7 @@ cdef class Break:
292
286
return 0
293
287
294
288
cdef int _get_root(int word, const GoldParseC* gold) nogil:
295
- while gold.heads[word] != word and not gold.has_dep[word] and word >= 0 :
289
+ while gold.heads[word] != word and gold.has_dep[word] and word >= 0 :
296
290
word = gold.heads[word]
297
291
if not gold.has_dep[word]:
298
292
return - 1
@@ -522,9 +516,11 @@ cdef class ArcEager(TransitionSystem):
522
516
" before training and after parsing. Either pass make_projective=True "
523
517
" to the GoldParse class, or use PseudoProjectivity.preprocess_training_data" )
524
518
else :
519
+ print (gold.orig_annot)
525
520
print (gold.words)
526
521
print (gold.heads)
527
522
print (gold.labels)
523
+ print (gold.sent_starts)
528
524
raise ValueError (
529
525
" Could not find a gold-standard action to supervise the dependency "
530
526
" parser.\n "
You can’t perform that action at this time.
0 commit comments