Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否可以将 push_back 与 Thrust 库一起使用?那么向量的向量呢?我想在 GPU 中使用 CPU 中的内容:
vector< vector<int> > MyVector( 100 ); ... MyVector[i].push_back(j);
有没有办法使用它,例如:
thrust::device_vector<thrust::device_vector<int>> d_vec(4);
那么创建一个 device_vectors 数组呢?可能吗?
thrust::device_vector
push_back
std::vector
device_vector
device_vectors
thrust::zip_iterator