You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since TensorDict.memmap_() creates a copy on physical mem of the content of a tensordict, it would be nice to have some more options:
MemmapTensors are temporary files. It could be nice to disable this when calling memmap_() (like temporary=False). In that way, one would know that the content of the memmap will be kept in memory after the process exits.
Similarly, it could be neat to be able to control if a memmap_ tensor can be written or not (by passing mode="r+" for instance). Of course, memmap_() would always write the content but then modify the permissions accordingly to make sure that the content is somewhat locked for in-place modifs.
The text was updated successfully, but these errors were encountered:
Motivation
Since
TensorDict.memmap_()
creates a copy on physical mem of the content of a tensordict, it would be nice to have some more options:MemmapTensors
are temporary files. It could be nice to disable this when callingmemmap_()
(liketemporary=False
). In that way, one would know that the content of the memmap will be kept in memory after the process exits.memmap_
tensor can be written or not (by passingmode="r+"
for instance). Of course,memmap_()
would always write the content but then modify the permissions accordingly to make sure that the content is somewhatlocked
for in-place modifs.The text was updated successfully, but these errors were encountered: