changes before cleaning recognition code
clean recognition code part 1
clean recognition code part 2