Synchronize the calling CPU thread with any outstanding CUDA work on the specified stream.
This function allows the host application code to ensure that all kernel launches
and memory copies have completed on the stream.
- Parameters:
stream_or_device (Stream | Device | str | None) – wp.Stream or a device. If the argument is a device, synchronize the device’s current stream.