Design and realization of a palmar vein imaging instrument

With the rapid development of the society, people's requirements on the medical level are gradually rising. Palmar vein injection is a commonly used treatment method, but it is difficult for infants, elderly people, obese patients and other groups to have venous access. For example, the fat layer under the skin of obese patients is thick, and the vein depth is deep but not obvious, which greatly increases the difficulty of venipuncture for medical staff. Old people's palm appears spot and wrinkle, increased the difficulty of vein recognition; The smaller blood vessels in infants are difficult to identify, coupled with the increase in the number of infants under the universal two-child policy, the probability of failure in venipuncture by medical staff increases. In addition, under the current situation of weak doctor-patient relationship and declining professional skills of medical staff, patients become more sensitive to the situation of multiple injections, or even cannot be inserted, resulting in numerous doctor-patient disputes. To solve the problem of low accuracy of puncture technique has become an important research topic for scientists. Therefore, a palmar vein imaging instrument is proposed to assist doctors in palmar vein puncture.


Introduction
Palmar vein imaging instrument is mainly used as an auxiliary instrument for medical personnel to perform palmar vein puncture in the face of patients with difficulty in accessing veins. It can reduce the burden of patients and pressure of medical personnel, improve the success rate of puncture, and thus improve the doctor-patient relationship. There are many devices for venous imaging on the market today, but they are too large to be portable and easy to move. Narrow scope of application; The processed venous image has the disadvantage of interference noise points.
The equipment has been improved from the aspects of overall instrument volume, image processing accuracy and image display mode. A camera sensitive to infrared is used to collect the palm vein, and a microcomputer processor is used to process the infrared image of the palm vein in real time. WiFi is transmitted to the remote display device (tablet, et al.) to view the patient's vein image. It can effectively reduce the size of the instrument, increase portability, and provide free selection of imaging equipment for medical staff. Different display devices can be selected in different environments. In community hospitals, where the flow of people is relatively small, mobile devices such as mobile phones and tablets can be used for display, thus saving medical costs.

Overall system design
The overall design includes hardware design and software design. The acquisition of high-quality palm infrared images from hardware is more convenient for subsequent processing. The software carries out a series of digital image processing on the collected images to obtain the palm vein images of the patients.
As shown in Fig. 1,the treatment of palmar vein by this instrument can be divided into three steps: the collection of palmar vein image, the processing of infrared image, and the display of vein image. Medical staff can display the image of the patient's palmar vein through the monitor for auxiliary puncture. Firstly, through the transmission of the lower infrared light source and the reflection of the upper infrared light source, the infrared imager obtains the image of the required imaging part, and then converts it into the infrared image, which is transmitted to the image processing system through the interface. Then the image is obtained through algorithm processing, which is transmitted to the remote display device through WiFi.

System hardware design
The whole system hardware includes image acquisition hardware, image processing platform, image display hardware and power module.

System hardware composition
As shown in Fig. 2, the main components of the instrument include infrared light source, image processing system, stand and so on.  Holder: Provides the fixing of infrared imager, microcomputer processing system and other parts, as well as multiple rotating shafts, which can fold the pole for easy carrying.  Detection point: Place the desired palm vein imaging site  Infrared imager: Equipped with a high-sensitivity infrared lens, 3 million pixels, 7-22 zoom times.  Microcomputer processing system: The algorithm in the computer processes the image of the infrared sensor to obtain the image of the target.  Lower infrared light source: The lower light source adopts high-power solid-state LED light source, which has strong penetration and can clearly display deep vascular images.  Upper infrared light source: The upper light source adopts multi-point LED light source, no shadow, no reflected light interference, suitable for observing shallow vessels. Both the upper and lower light sources have strong and weak stepless adjustable, mutual use.  Spin axis: The device can be folded down, reducing the size of the device and making it easy to carry.  Optional: The display provides the best imaging results via a wireless connection to the remote display.

Design of infrared light source
Due to the strong absorption ability of hemoglobin to infrared light and the strong absorption ability of oxygenated hemoglobin and deoxygenated hemoglobin to infrared light compared with other tissues, infrared LED lamp is adopted for vein development [1].
According to the diffraction properties of waves, the longer the wavelength, the stronger the penetration [2].
In this design, the near infrared light source is selected, and the lower infrared light source is the LED light source with strong penetration, that is, a longer wavelength, to facilitate the display of deeper blood vessels. The upper infrared light source selects the LED light source with shorter wavelength to facilitate the display of shallow blood vessels. Moreover, the upper and lower light sources are controlled by PWM wave, which can be adjusted with strong and weak level. According to the study by Huiying Lan et al. [3], 810nm is the most ideal venous imaging light source. According to the types of near infrared light source on the market, the wavelength of 780nm is selected as the upper infrared light source and 850nm as the lower infrared light source.
For the control of the light source, PWM is used to adjust the light intensity, so as to reduce the number of infrared LED installation, while not affecting the image acquired by the infrared camera. At the same time, through the adjustable light intensity, medical staff can choose the light intensity suitable for the environment, to achieve a comfortable medical environment, easy to pin.

Camera selection with sensor
A camera with excellent infrared sensitivity is selected to collect images, and a better near-infrared band acquisition effect is determined by its spectral response curve.
In order to capture a clear dual-band infrared image, a sensor with better infrared photosensitivity needs to be developed, and a bandpass filter needs to be added to reduce the interference of ambient natural light to the infrared image. The infrared camera adopted by us is composed of lens, filter and CMOS photosensitive device. The relationship between them is that the filter is located between the lens and CMOS photosensitive sensor, and is placed at the bottom of the control box to collect vein texture image. The filter is a normal 780 nm bandpass filter that can only pass through nir light with a wavelength of 780 nm. CMOS photosensitive device adopts ordinary CMOS, which is placed in the middle of the bottom of the control box to collect the vein texture image.

Image processing platform
In terms of image processing and pattern recognition, due to the high complexity of the algorithm, large amount of computation, and high real-time requirements, it is necessary to choose the Intel X5 Z8350 four core, equipped with 64-bit Win10 microcomputer to achieve some complex image processing and pattern recognition applications.

Wireless image transmission
According to the characteristics of short transmission distance and portability, this product uses wireless network to transmit processed palm vein images. Medical staff can freely choose display devices such as computer, mobile phone, tablet, etc., which also increases the mobility of the device for multiple observation. Since the palm of the patient is not completely still during the puncture, the palm image is collected and processed in real time, which is equivalent to video transmission. The system uses WiFi for image transmission, and WiFi is a popular choice of communication technology for near field wireless video application transmission. WiFi band is ISM band, which can be connected to a variety of devices. WiFi has low price, high security, wide transmission range and has been widely used. WiFi wireless transmission speed is up to 54Mbit/s [8], which can better satisfy the transmission of processed palm vein images.

System software design
Computer image processing is a very important part of this system, through the analysis and processing of images to achieve the purpose of detection and location of blood vessels.  The processing process of the collected infrared image is shown in Fig. 3. After the infrared camera captures the palm vein image, preliminary segmentation is conducted to obtain the approximate area of the blood vessels. The image histogram is used to adjust the contrast of the image, then the image is sharpened by convolution, and the vein boundary is determined by the edge detection algorithm. Morphological operations are used to remove noise and make the vessels continuously visible. The veins are then colored for identification. Finally, the processed image is transferred to the display device by wireless transmission for palmar vein display.

System software processing process
The image of the middle process of palmar vein image processing is shown in Fig. 4.Which (a) is a infrared sensor camera collected human hand vein image, (b) is carried out on the collected images after segmentation of images, (c) is to limit the image contrast of the image after histogram equalization, (d) is the image after binarization, (e) is the image after median filtering, (f) is to remove small noise image, after input morphology (g) is processed images, (h) is the hand vein image after coloring and flip. In the software design of palmar vein image processing, the main algorithms include real-time palmar vein image processing algorithm, vascular feature extraction algorithm and vascular depth extraction algorithm.

Real-time palmar vein image processing algorithm
Compared with the static image processing system, the real-time image processing system not only requires higher processing speed, but also high repeatability of the system, which requires the process of executing the program to be more stable. Processing the data returned from the software provides a reliable condition for this function. The image acquisition system collects the lattice diagram of each frame. Then the image processing algorithm is carried out, and finally the processed image is displayed in the image window.

Vascular feature extraction algorithm
The image processing system preprocesses the infrared images to show the difference between the vein and the surrounding area and eliminate the noise in the non-vascular area. Niblack [5] algorithm is used to improve histogram binarization and direction-based adjustable filter. The local threshold method is used, and the calculation formula of the threshold is given as in (1).Where "m" is the average gray value of the region centered on the pixel, "v" is the standard deviation of the region, and "k" is the correction coefficient, "T" is the threshold.
T=m+k*v (1) The selection of image processing algorithm should not only highlight vein veins, but also avoid misjudging non-vascular parts as vein veins. After processing, the image should be able to observe that the uneven distribution of noise is filtered out and the veins are clear.
Frangi [6] algorithm is adopted, which is an edge detection enhanced filtering algorithm based on Hessian matrix. Since Hessian is composed of second partial derivatives, it is very sensitive to noise. It's like using the Laplace operator for edge detection, smoothing first. The corresponding function Hessian2D() is used to solve the Hessian matrix. The corresponding function eig2image() is used to obtain the two eigenvalues of Hessian matrix, and finally the response function is constructed to complete the filtering.
Findcontour was used to remove small area noise. Morphological processing of images, expansion and corrosion of images, and the definition of structural elements are the core of mathematical morphological processing. In OpenCV, the built-in getStructuring Elemet function can be used to advance the corrosion operation and then the expansion operation. About the corrosion and expansion of the image, using function cv2.erode (), cv2.dilate (), all need to two parameters, one is the need to deal with the binary image, the second is the structural elements, return good image processing. Output the image after inverting the Y-axis of the image.

Vascular depth analysis algorithm
Infrared image has the characteristics of low contrast and little local information.The depth features of the image were estimated by the Gist feature and SIFT feature [7] algorithm, which could reflect the global contour information of the image.Based on the depth estimation model, the original eigenvector cue type is compared with the infrared image eigenvector cue type to obtain the image depth information.

Conclusion
Palmar vein imaging instrument selected near infrared light source in the biological spectrum for irradiation, harmless to human body; The filter is used to filter the visible light, so as to ensure the quality of the vein image collected by the camera and make the characteristic points of the vein image more obvious. In the algorithm processing of vein images, the images captured by the camera in real time can be preprocessed, segmenced and post-processed to show clear and smooth vein images without confusing areas. For real-time moving target, it can be processed quickly with short delay. To assist medical staff in locating superficial vein vessels safely, efficiently and intuitively before venipuncturing, so as to find the most suitable vessels for puncture conveniently and quickly, so as to greatly improve the efficiency and success rate of puncture, reduce the labor intensity of medical staff, reduce the psychological pressure of nurses, and reduce the probability of doctor-patient disputes caused by the failure of venipuncture.
In addition, the equipment is in the process of hand vein image processing, access to the patient's hand vein image, because each person's palm vein has living, uniqueness, rooted in intradermal, unable to forge and other characteristics [8], can use palm vein identity based electronic patient cases, used to identify a person, contribute to intelligent medical.