Reshape dJdu before returning from compute_adjoints