What is tensor_like?
It could be worth saying here that it should still follow get_data_specs(), just that for this cost get_data_specs() is always guaranteed to take that form.