graphlow.TensorMesh.requires_grad#
- TensorMesh.requires_grad(requires_grad: bool = True, point_data: bool = False, cell_data: bool = False) None#
Set
requires_gradflags for backend tensors.- Parameters:
- requires_gradbool
If True, gradients are tracked. If False, gradients are not tracked.
- point_databool, default=False
If True, also applies to floating-point arrays in
point_data. (in addition topoints).- cell_databool, default=False
If True, also applies to floating-point arrays in
cell_data. (in addition topoints).