Nvinfer batch-size from video file input

Do you actually input 8 sources while you set batch size to 8 for nvinfer and nvstreammux? Have you set the sink to fakesink? Have you disabled nvosd and nvmultistreamtiler?
Even with the data you give to us, the batch size 1 pipeline can only handle one video, it takes 34 seconds. 8 videos take 34s x 8 = 272s = 4m32s, after you set batch size to 8, the pipeline can handle 8 videos simultaneously, it takes 1m17s which is much less than 4m32s.
The batch saved your time.

If you are using deepstream-app sample application, it can output the pipeline FPS.
If you are using your own DeepStream application, you may refer to
DeepStream SDK FAQ - Intelligent Video Analytics / DeepStream SDK - NVIDIA Developer Forums

To measure the pipeline performance, you need to follow the Performance — DeepStream documentation 6.4 documentation (nvidia.com) to disable nvosd and nvmultistreamtiler, and the fakesink with “sync=0” will help you to disable the sink clock synchronization which may affect the pipeline.