def tablelib_binary_features(span1, span2):
binary_features = settings["<STR_LIT>"]["<STR_LIT>"]["<STR_LIT>"]<EOL>if span1.sentence.is_tabular() and span2.sentence.is_tabular():<EOL><INDENT>if span1.sentence.table == span2.sentence.table:<EOL><INDENT>yield "<STR_LIT>", DEF_VALUE<EOL>if span1.sentence.cell is not None and span2.sentence.cell is not None:<EOL><INDENT>row_diff = min_row_diff(<EOL>span1.sentence,<EOL>span2.sentence,<EOL>absolute=binary_features["<STR_LIT>"]["<STR_LIT>"],<EOL>)<EOL>col_diff = min_col_diff(<EOL>span1.sentence,<EOL>span2.sentence,<EOL>absolute=binary_features["<STR_LIT>"]["<STR_LIT>"],<EOL>)<EOL>yield f"<STR_LIT>", DEF_VALUE<EOL>yield f"<STR_LIT>", DEF_VALUE<EOL>yield (<EOL>f"<STR_LIT>"<EOL>), DEF_VALUE<EOL>if span1.sentence.cell == span2.sentence.cell:<EOL><INDENT>yield "<STR_LIT>", DEF_VALUE<EOL>yield (<EOL>f"<STR_LIT>"<EOL>f"<STR_LIT>"<EOL>f"<STR_LIT:]>"<EOL>), DEF_VALUE<EOL>yield (<EOL>f"<STR_LIT>"<EOL>), DEF_VALUE<EOL>if span1.sentence == span2.sentence:<EOL><INDENT>yield "<STR_LIT>", DEF_VALUE<EOL><DEDENT><DEDENT><DEDENT><DEDENT>else:<EOL><INDENT>if span1.sentence.cell is not None and span2.sentence.cell is not None:<EOL><INDENT>yield "<STR_LIT>", DEF_VALUE<EOL>row_diff = min_row_diff(<EOL>span1.sentence,<EOL>span2.sentence,<EOL>absolute=binary_features["<STR_LIT>"]["<STR_LIT>"],<EOL>)<EOL>col_diff = min_col_diff(<EOL>span1.sentence,<EOL>span2.sentence,<EOL>absolute=binary_features["<STR_LIT>"]["<STR_LIT>"],<EOL>)<EOL>yield f"<STR_LIT>", DEF_VALUE<EOL>yield f"<STR_LIT>", DEF_VALUE<EOL>yield (<EOL>f"<STR_LIT>"<EOL>), DEF_VALUE<EOL><DEDENT><DEDENT><DEDENT>
Table-/structure-related features for a pair of spans