code: def test_seek_reading(self, keyframes, full_path, duration):
      torchvision.set_video_backend("cuda")
      decoder = VideoReader(full_path)
      time = duration / 2
      decoder.seek(time, keyframes_only=keyframes)
      with av.open(full_path) as container:
          container.seek(
              int(time * 1000000),
              any_frame=not keyframes,
              backward=False,
          )
          for av_frame in container.decode(container.streams.video[0]):
              av_frames = torch.tensor(
                  av_frame.to_rgb(src_colorspace="ITU709").to_ndarray()
              )
              vision_frames = next(decoder)["data"]
              mean_delta = torch.mean(
                  torch.abs(
                      av_frames.float() - vision_frames.cpu().float()
                  )
              )
              assert mean_delta < 0.75
  
file_path: vision/test/test_video_gpu_decoder.py
imports: import math
  import os
  import pytest
  import torch
  import torchvision
  from torchvision.io import _HAS_GPU_VIDEO_DECODER, VideoReader
label_desc: Use image node_id 2 for calling the TestVideoGPUDecoder obj's underlying member method code with example usage: obj.test_seek_reading(keyframes, full_path, duration) without return types