A visual sensor system for controlling imaging timings, the visual sensor system comprising: an imaging device for capturing a plurality of images of the target object, the target object being conveyed on a conveying path; a sensor for sending a detection signal when the target object reaches an imaging range of the imaging device; and a detection signal input unit for receiving a detection signal from the sensor; and an image processing device comprising: a command output unit for outputting an imaging command to the imaging device; an operation input unit for receiving an operation command given by a user, the operation input unit including a selection operation input unit (104, 103) for receiving the operation command; an image output unit for outputting an image to a display device; a memory for storing image files of the plurality of captured images when the detection signal is received; and a delay amount setting unit for setting an amount of delay produced between a time when the detection signal input unit receives the detection signal as input and a time when the command output unit outputs the imaging command, wherein the amount of delay is set for a subsequent observing processing, characterized in that the delay amount setting unit is configured to: read image files from the memory and display the image files on the display device one by one, wherein a desired image of the displayed image files is selected by the user giving the operation command; display a mark indicating a coordinate position of the target object in the desired image; and calculate the amount of delay from a product of an amount of correction and an inverse of a moving speed of the target object, and the amount of correction is calculated by an inner product of a first vector (a) having been input by the user and a second vector (b), the direction and length of the first vector (a) being indicative of a moving direction and moving distance of the target object from the mark to a position of the imaging range which is desired by the user, and the second vector (b) being indicative of actual moving direction and moving distance of the target object conveyed on the conveying path by a conveying mechanism in the imaging range, wherein the inverse of the moving speed of the target object is a delay time (1/S) per pair of images of adjacent image files stored in the memory. an imaging device for capturing a plurality of images of the target object, the target object being conveyed on a conveying path; a sensor for sending a detection signal when the target object reaches an imaging range of the imaging device; and a detection signal input unit for receiving a detection signal from the sensor; and an image processing device comprising: a command output unit for outputting an imaging command to the imaging device; an operation input unit for receiving an operation command given by a user, the operation input unit including a selection operation input unit (104, 103) for receiving the operation command; an image output unit for outputting an image to a display device; a memory for storing image files of the plurality of captured images when the detection signal is received; and a command output unit for outputting an imaging command to the imaging device; an operation input unit for receiving an operation command given by a user, the operation input unit including a selection operation input unit (104, 103) for receiving the operation command; an image output unit for outputting an image to a display device; a memory for storing image files of the plurality of captured images when the detection signal is received; and a delay amount setting unit for setting an amount of delay produced between a time when the detection signal input unit receives the detection signal as input and a time when the command output unit outputs the imaging command, wherein the amount of delay is set for a subsequent observing processing, characterized in that the delay amount setting unit is configured to: read image files from the memory and display the image files on the display device one by one, wherein a desired image of the displayed image files is selected by the user giving the operation command; display a mark indicating a coordinate position of the target object in the desired image; and calculate the amount of delay from a product of an amount of correction and an inverse of a moving speed of the target object, and the amount of correction is calculated by an inner product of a first vector (a) having been input by the user and a second vector (b), read image files from the memory and display the image files on the display device one by one, wherein a desired image of the displayed image files is selected by the user giving the operation command; display a mark indicating a coordinate position of the target object in the desired image; and calculate the amount of delay from a product of an amount of correction and an inverse of a moving speed of the target object, and the amount of correction is calculated by an inner product of a first vector (a) having been input by the user and a second vector (b), the direction and length of the first vector (a) being indicative of a moving direction and moving distance of the target object from the mark to a position of the imaging range which is desired by the user, and the second vector (b) being indicative of actual moving direction and moving distance of the target object conveyed on the conveying path by a conveying mechanism in the imaging range, wherein the inverse of the moving speed of the target object is a delay time (1/S) per pair of images of adjacent image files stored in the memory.