TensorDictBase.is_memmap#
- TensorDictBase.is_memmap() bool#
Checks if tensordict is memory-mapped.
If a TensorDict instance is memory-mapped, it is locked (entries cannot be renamed, removed or added). If a
TensorDictis created with tensors that are all memory-mapped, this does __not__ mean thatis_memmapwill returnTrue(as a new tensor may or may not be memory-mapped). Only if one calls tensordict.memmap_() will the tensordict be considered as memory-mapped.This is always
Truefor tensordicts on a CUDA device.
Every tensordict class and every tensorclass has this method. For the other methods, see Methods by task.