How to get the NDArray in the C++ files


I want to get the value of variables with the NDArray data structure in the C++ files, such as the recv_buf in PullImpl() function in kvstore_dist.h (shown in the following figure). 39 . Anyone gives me some suggestions? Thank your.


To copy a NDArray you can use the SyncCopyToCPU() function see the docs here:


Thank you, Thomas. Got it.