add test for predict and fix commonc.pyx