How to Loop over a Tensor in TensorFlow with for
A Python for loop works on a TensorFlow tensor the way it works on a list of lists: it hands you one row at a time. Each row is still a tensor, and so is each value in it. This guide loops over a small table of scores in TensorFlow 2.22.0, row by row and value by value.
