Would it be possible to create a tensor that is both pinned and shared?
When I call share_memory_() on a pinned tensor, it is no longer pinned, and vice versa.
So what is the best way to share a read-only tensor created in main process with its child processes?
Background: I am training multiple models on multiple GPUs of the same machine. They all share the same training data, which lives in the main process and is shared to all child processes. And pinning memory makes the transfer from RAM to GPU faster.
Thanks