This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| demo for RTP and RTCP Buffer parse with GStreamer | |
| 1. This example program is designed to work with the deepstream / gstreamer python API | |
| to calculate the latency of an rtsp transfer. | |
| 2. The gstreamer element example is modified from NVIDIA-AI-IOT/deepstream_python_apps/ | |
| deepstream_test1_rtsp_in_rtsp_out.py. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # caculate loss (forrward) | |
| start_forward = time.time() | |
| outputs = model(samples) | |
| loss = criterion(outputs, targets) | |
| end = time.time() | |
| # caculate loss (forrward) & log time | |
| torch.cuda.synchronize() |