testing gradient efficiency