debouncing is something which has to be done by Hardware. It takes place directly at the input of your camera and before the image is actually aquired. Please check your cameras documentation and search for the available debounce options. Typically most modern cameras do have a possibility to ignore pulses which are shorter than the set debounce value.
If it is not possible for you to remove the bouncing behavior completely by the camera hardware you should try to remove the bouncing itself. Only if this is not possible you will have to look for a software workaround which suits your applictation. E.g. if you know that your images are not aquired below a specific frame rate you could check the timestamp of each image and ignore images which where aquired with a framerate which is out of spec. However, this will not work with every application.