fix bug
test gradient