backprop modification
add some tools