code: def __init__(self, resolution=(320, 240), framerate=32, **kwargs):
      # initialize the camera
      self.camera = PiCamera()
  
      # set camera parameters
      self.camera.resolution = resolution
      self.camera.framerate = framerate
  
      # set optional camera parameters (refer to PiCamera docs)
      for arg, value in kwargs.items():
          setattr(self.camera, arg, value)
  
      # initialize the stream
      self.rawCapture = PiRGBArray(self.camera, size=resolution)
      self.stream = self.camera.capture_continuous(
          self.rawCapture, format="bgr", use_video_port=True
      )
  
      # initialize the frame and the variable used to indicate
      # if the thread should be stopped
      self.frame = None
      self.stopped = False
  
file_path: imutils/imutils/video/pivideostream.py
imports: from picamera.array import PiRGBArray
  from picamera import PiCamera
  from threading import Thread
  import cv2
label_desc: Use image node_id 1 to create a new PiVideoStream object  with example: obj = PiVideoStream(resolution, framerate)