code: def video_length(filename):
      cap = cv2.VideoCapture(filename)
      return int(cap.get(cv2.CAP_PROP_FRAME_COUNT))
  
imports: import nvidia.dali.fn
  from nvidia.dali import pipeline_def
  import numpy
  import cv2
  import nvidia.dali.types
  import glob
  from itertools import cycle
  from test_utils import get_dali_extra_path, is_mulit_gpu
  from nvidia.dali.backend import TensorListGPU
  from nose2.tools import params
  from nose import SkipTest
  from nose.plugins.attrib import attr
label_desc: Use image node_id 2 for calling a global function with example usage: video_length(filename) and returns: int