Learn Before
Concept

TensorFlow Tensor Immutability

In TensorFlow, standard Tensors are immutable data structures and do not support direct element assignment. To maintain mutable state that allows for index-based updates, elements must be stored within a Variable. However, it is important to note that gradients do not flow backwards through assignments made to a Variable.

0

1

Updated 2026-05-01

Contributors are:

Who are from:

Tags

D2L

Dive into Deep Learning @ D2L