code: def send_frames(payload, snd_cnt, session):
      if args.client_batching:
          snd_cnt += len(payload)
          payload = json.dumps(payload)
          response = requests.post(api, data=payload, headers=headers)
      else:
          snd_cnt += 1
          response = session.post(api, data=payload)
  
      return (response, snd_cnt)
  
file_path: serve/examples/image_classifier/near_real_time_video/request.py
imports: import argparse
  import base64
  import json
  import time
  from collections import deque
  from concurrent.futures import as_completed
  from threading import Thread
  import cv2
  import requests
  from requests_futures.sessions import FuturesSession
label_desc: Use image node_id 2 for calling a global function with example usage: send_frames(payload, snd_cnt, session) and returns: response,  snd_cnt