restruct test_crf.py