Use texture memory. Change the kernel of gini for version 3.