CN110123254B - Electronic colposcope image adjusting method and system and terminal equipment - Google Patents

Electronic colposcope image adjusting method and system and terminal equipment Download PDF

Info

Publication number
CN110123254B
CN110123254B CN201810133584.8A CN201810133584A CN110123254B CN 110123254 B CN110123254 B CN 110123254B CN 201810133584 A CN201810133584 A CN 201810133584A CN 110123254 B CN110123254 B CN 110123254B
Authority
CN
China
Prior art keywords
image
acetic acid
acid reaction
value
green light
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810133584.8A
Other languages
Chinese (zh)
Other versions
CN110123254A (en
Inventor
章鸿
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Edan Instruments Inc
Original Assignee
Edan Instruments Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Edan Instruments Inc filed Critical Edan Instruments Inc
Priority to CN201810133584.8A priority Critical patent/CN110123254B/en
Publication of CN110123254A publication Critical patent/CN110123254A/en
Application granted granted Critical
Publication of CN110123254B publication Critical patent/CN110123254B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B1/00Instruments for performing medical examinations of the interior of cavities or tubes of the body by visual or photographical inspection, e.g. endoscopes; Illuminating arrangements therefor
    • A61B1/00002Operational features of endoscopes
    • A61B1/00004Operational features of endoscopes characterised by electronic signal processing
    • A61B1/00009Operational features of endoscopes characterised by electronic signal processing of image signals during a use of endoscope
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B1/00Instruments for performing medical examinations of the interior of cavities or tubes of the body by visual or photographical inspection, e.g. endoscopes; Illuminating arrangements therefor
    • A61B1/04Instruments for performing medical examinations of the interior of cavities or tubes of the body by visual or photographical inspection, e.g. endoscopes; Illuminating arrangements therefor combined with photographic or television appliances
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B1/00Instruments for performing medical examinations of the interior of cavities or tubes of the body by visual or photographical inspection, e.g. endoscopes; Illuminating arrangements therefor
    • A61B1/303Instruments for performing medical examinations of the interior of cavities or tubes of the body by visual or photographical inspection, e.g. endoscopes; Illuminating arrangements therefor for the vagina, i.e. vaginoscopes

Landscapes

  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Surgery (AREA)
  • Engineering & Computer Science (AREA)
  • Biophysics (AREA)
  • Medical Informatics (AREA)
  • Nuclear Medicine, Radiotherapy & Molecular Imaging (AREA)
  • Optics & Photonics (AREA)
  • Pathology (AREA)
  • Radiology & Medical Imaging (AREA)
  • Veterinary Medicine (AREA)
  • Biomedical Technology (AREA)
  • Heart & Thoracic Surgery (AREA)
  • Physics & Mathematics (AREA)
  • Molecular Biology (AREA)
  • Animal Behavior & Ethology (AREA)
  • General Health & Medical Sciences (AREA)
  • Public Health (AREA)
  • Signal Processing (AREA)
  • Gynecology & Obstetrics (AREA)
  • Reproductive Health (AREA)
  • Image Processing (AREA)
  • Image Analysis (AREA)

Abstract

The invention is suitable for the technical field of electronic colposcopes, and provides an electronic colposcope image adjusting method, a system and terminal equipment, wherein when the acetic acid reaction is started, the acetic acid reaction image is collected from a set time point, and the equipment parameters of the electronic colposcope are adjusted according to the RGB value of the acetic acid reaction image so as to collect and store the acetic acid reaction image meeting the first image quality requirement; acquiring a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the green light image of the acetic acid reaction image so as to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement; and when the iodine reacts, acquiring an iodine reaction image, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the iodine reaction image so as to acquire and store the iodine reaction image meeting the third image quality requirement, so that the images acquired by each stage of the electronic colposcope can achieve the optimal display effect.

Description

Electronic colposcope image adjusting method and system and terminal equipment
Technical Field
The invention belongs to the technical field of electronic colposcopy, and particularly relates to an electronic colposcope image adjusting method, an electronic colposcope image adjusting system and terminal equipment.
Background
The electronic colposcope is widely applied to diagnosis of diseases of the lower genital tract and diagnosis of early cervical cancer. The electronic colposcope magnifies the images of the cervix, vagina and vulva by a certain factor, and under the irradiation of a light source, the changes of the epithelium and blood vessels which can not be seen by naked eyes are observed. By observing these changes, electronic colposcopy can detect cervical erosion, cervical polyps, cervical intraepithelial neoplasia, cervical cancer, vaginitis, vulvar, vaginal or cervical sarcoidosis, viral infections and subclinical papillomavirus infections. The electronic colposcope is valuable not only in the aspects of diagnosing early cervical canceration, distinguishing tumors and inflammations and the like, but also has special application value in the aspect of treatment, particularly in the aspect of treatment of cervical intraepithelial neoplasia. The electronic colposcope mainly comprises an imaging system, a light source, an acquisition system, a display system, a computer and the like, when the colposcopy is carried out, a vaginoscope is needed to expose the vagina and the cervix, the lens of the colposcope is aligned to the cervix or the vagina at a certain distance away from the vaginal orifice, the focal length is adjusted, optical imaging is converted into an electronic signal through the imaging system, the electronic signal is acquired to computer equipment through the acquisition system, and then the image is displayed through the display system. The electronic colposcope needs to realize examination work through a light source and an imaging system, and the diagnostic result of a doctor is influenced by the factors of image definition and color deviation. In the electronic colposcopy process, 3% -5% acetic acid solution and Lugol's solution are needed for examination, and a doctor needs to diagnose by observing the change condition of the image after the 3% -5% acetic acid solution and Lugol's solution are smeared. Therefore, the image display effect at different stages is not consistent during the electronic colposcopy.
However, in the prior art, under the condition that the equipment parameters of the electronic colposcope are the same, images at different stages are obtained, the optimal image display effect is difficult to achieve, and the accuracy of the diagnosis result is seriously influenced.
Disclosure of Invention
In view of this, embodiments of the present invention provide an electronic colposcope image adjusting method, an electronic colposcope image adjusting system, and a terminal device, so as to solve the problems that in the prior art, under the condition that device parameters of an electronic colposcope are the same, images at different stages are obtained, an optimal image display effect is difficult to achieve, and accuracy of a diagnosis result is seriously affected.
A first aspect of an embodiment of the present invention provides an electronic colposcope image adjusting method, which includes:
when the acetic acid reaction is started, collecting an acetic acid reaction image from a set time point, and adjusting equipment parameters of the electronic colposcope according to the RGB value of the acetic acid reaction image so as to collect and store the acetic acid reaction image meeting the first image quality requirement;
acquiring a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjusting equipment parameters of the electronic colposcope according to the RGB value of the green light image of the acetic acid reaction image so as to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement;
and during iodine reaction, acquiring an iodine reaction image, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the iodine reaction image so as to acquire and store the iodine reaction image meeting the third image quality requirement.
A second aspect of an embodiment of the present invention provides an electronic colposcopic image adjustment system, including:
the acetic acid reaction image adjusting module is used for collecting an acetic acid reaction image from a set time point when the acetic acid reaction is started, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the acetic acid reaction image so as to collect and store the acetic acid reaction image meeting the first image quality requirement;
the first green light image adjusting module is used for acquiring a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the green light image of the acetic acid reaction image so as to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement;
and the iodine reaction image adjusting module is used for acquiring an iodine reaction image during iodine reaction, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the iodine reaction image so as to acquire and store the iodine reaction image meeting the third image quality requirement.
A third aspect of the embodiments of the present invention provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the steps of the method when executing the computer program.
A fourth aspect of embodiments of the present invention provides a computer-readable storage medium storing a computer program which, when executed by a processor, implements the steps of the above-described method.
According to the embodiment of the invention, the equipment parameters of the electronic colposcope are adjusted according to the RGB values of the images at each stage in different stages of the images collected by the electronic colposcope so as to collect and store the images meeting the image quality requirement, so that the images collected at each stage of the electronic colposcope can achieve the optimal display effect, and the accuracy of the diagnosis result is effectively improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
Fig. 1 is a schematic flow chart of an electronic colposcope image adjusting method according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of image region division of a cervical part according to an embodiment of the present invention;
FIG. 3 is a schematic flow chart of an electronic colposcope image adjustment method according to a second embodiment of the present invention;
FIG. 4 is a schematic flow chart of a color deviation detection algorithm according to a third embodiment of the present invention;
fig. 5 is a schematic flowchart of an image sharpness detecting method according to a fourth embodiment of the present invention;
FIG. 6 is a schematic structural diagram of an electronic colposcope image adjusting system according to a fifth embodiment of the present invention;
FIG. 7 is a schematic structural diagram of an electronic colposcope image adjusting system according to a sixth embodiment of the invention;
fig. 8 is a schematic structural diagram of a terminal device according to a seventh embodiment of the present invention.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the invention. It will be apparent, however, to one skilled in the art that the present invention may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, circuits, and methods are omitted so as not to obscure the description of the present invention with unnecessary detail.
In order to explain the technical means of the present invention, the following description will be given by way of specific examples.
Example one
The embodiment provides an electronic colposcope image adjusting method, which can be specifically executed by a workstation connected with an electronic colposcope, a user performs man-machine interaction with the workstation through any feasible man-machine interaction method, and the workstation controls the working state of the electronic colposcope to acquire images of each stage of colposcope detection and store the images in storage equipment of the workstation. The workstation analyzes and judges the image collected by the electronic colposcope, and when the image does not accord with the corresponding image quality requirement, the workstation adjusts the equipment parameters of the electronic colposcope so as to obtain the image which accords with the image quality requirement.
In a specific application, the electronic colposcope comprises a camera module (a camera, a light source, a CCD or CMOS image sensor, etc.), an acquisition card, etc., and the workstation comprises a computer, a display device, a human-computer interaction device, etc., wherein the computer, the display device, and the human-computer interaction device of the workstation can be equivalently replaced by devices having data processing, displaying, and human-computer interaction functions, such as a notebook computer, a tablet computer, a personal digital assistant, a mobile phone, etc.
In specific application, before obtaining a cervical image through an electronic colposcope, reasonable equipment parameters of the electronic colposcope need to be set in advance, so that the acquired image preliminarily meets the image quality requirement, and the follow-up parameter adjustment step is facilitated. The equipment parameters influencing the imaging definition and the color of the camera module comprise aperture priority and shutter priority parameters, an R value and a B value, and the equipment parameters influencing the imaging definition and the color of the acquisition card comprise brightness, contrast, hue and saturation.
In one embodiment, the step of presetting device parameters of the electronic colposcope comprises the following steps:
setting and initializing device parameters of the electronic colposcope; the device parameters comprise camera module parameters and acquisition card parameters, the camera module parameters comprise aperture priority and shutter priority parameters, R values and B values, and the acquisition card parameters comprise brightness, contrast, hue and saturation.
As shown in fig. 1, the method for adjusting an image of an electronic colposcope provided by this embodiment includes:
and S101, when the acetic acid reaction is started, collecting an acetic acid reaction image from a set time point, and adjusting equipment parameters of the electronic colposcope according to RGB values of the acetic acid reaction image so as to collect and store the acetic acid reaction image meeting the first image quality requirement.
In a specific application, after the acetic acid reaction starts, the reaction time of about 50 seconds generally needs to be waited, and the acetic acid reaction image is started to be collected after the acetic acid reaction is completed. The set time point may be set as required, for example, 30 seconds, 40 seconds, 50 seconds, 60 seconds, or the like after the start of the acetic acid reaction.
In this embodiment, after the acetic acid reaction image is collected, the RGB values of the acetic acid reaction image are obtained, and then it is determined whether the acetic acid reaction image meets the first image quality requirement according to the RGB values of the acetic acid reaction image, if not, the device parameters of the electronic colposcope are adjusted, the acetic acid reaction image is collected again, and the collection, determination and adjustment are repeated until the collected acetic acid reaction image meets the first image quality requirement, and the collected acetic acid reaction image is stored in the first register.
In one embodiment, the step S101 of adjusting the device parameters of the electronic colposcope according to the RGB values of the acetic acid reaction image to acquire and store an acetic acid reaction image meeting the first image quality requirement specifically includes:
step S1011, calculating the color deviation of the acetic acid reaction image through a color deviation detection algorithm according to the RGB value of the acetic acid reaction image;
step S1012, adjusting parameters of a camera module of the electronic colposcope according to the color deviation of the acetic acid reaction image until the color deviation of the acetic acid reaction image reaches a first color deviation; the camera module parameters comprise aperture priority and shutter priority parameters, and R values and B values;
step S1013, detecting the definition of the acetic acid reaction image by an image definition detection method according to the RGB value of the acetic acid reaction image;
step S1014, adjusting acquisition card parameters of the electronic colposcope according to the definition of the acetic acid reaction image until the definition of the acetic acid reaction image reaches a first definition; wherein the acquisition card parameters comprise brightness, contrast, hue and saturation;
step S1015, when the color deviation of the acetic acid reaction image reaches the first color deviation value and the resolution reaches the first resolution, collecting and storing the acetic acid reaction image.
In this embodiment, the first image quality requirement means that the color deviation of the image reaches the first color deviation value and the resolution reaches the first resolution. The values of the first color deviation and the first definition may be set according to specific image quality requirements for the acetic acid reaction image, and the values of the first color deviation and the first definition may be changed according to the different image quality requirements.
In one embodiment, step S101 is followed by:
scanning the acetic acid reaction image meeting the first image quality requirement through a cross mark arranged at the center of a lens of the electronic colposcope, detecting the position of the center of a cervical orifice in the acetic acid reaction image meeting the first image quality requirement, and recording the coordinates of the cervical orifice;
and according to the coordinate of the central position of the cervical orifice, intercepting the image area information of the cervical part in the acetic acid reaction image which meets the first image quality requirement, converting the image area information into an acetic acid reaction image array and storing the acetic acid reaction image array in a first cache.
As shown in fig. 2, an image region division schematic diagram of a cervical part is exemplarily shown, wherein an intersection point of a cross-shaped mark is a central position of a cervical opening, a circular region 1 is a region where the cervical opening is located, and an annular region 2 and an annular region 3 are peripheral regions of the cervical opening.
And S102, acquiring a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjusting equipment parameters of the electronic colposcope according to the RGB value of the green light image of the acetic acid reaction image so as to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement.
In this embodiment, after the green light image of the acetic acid reaction image is collected, the RGB value of the green light image is acquired, and then it is determined whether the green light image meets the second image quality requirement according to the RGB value thereof, if not, the device parameter of the electronic colposcope is adjusted, the green light image of the acetic acid reaction image is collected again, and the collection, the determination and the adjustment are repeated in this way until the collected green light image meets the second image quality requirement, and then the collected green light image is stored in the second register.
In the present embodiment, the principle of acquiring the green light image is as follows: filtering the image by setting an electronic green light filtering value of a lens of the electronic colposcope so as to obtain a green light image of the image; wherein the electronic green filter value includes an R value and a B value among RGB values related to white balance of the image.
In one embodiment, the step S102 of adjusting the device parameters of the electronic colposcope according to the RGB values of the green image of the acetic acid reaction image to acquire and store the green image of the acetic acid reaction image meeting the second image quality requirement specifically includes:
step S1021, judging whether a green light parameter value of the green light image of the acetic acid reaction image is in a first threshold value range according to the RGB value of the green light image of the acetic acid reaction image;
step S1022, when the green light parameter value of the green light image of the acetic acid reaction image is not within the first threshold value range, calculating the color deviation of the green light image of the acetic acid reaction image through a color deviation detection algorithm;
step S1023, adjusting the camera module parameter of the electronic colposcope according to the color deviation of the green light image of the acetic acid reaction image until the green light parameter value of the green light image of the acetic acid reaction image is within a first threshold value range; the camera module parameters comprise an R value and a B value;
and step S1024, when the green light parameter value of the green light image of the acetic acid reaction image is within a first threshold value range, acquiring and storing the green light image of the acetic acid reaction image.
In this embodiment, the second image quality requirement means that the green light parameter value is within the first threshold range. The first threshold range may be set according to specific image quality requirements for the green image, and may be altered depending on the image quality requirements. The first threshold range includes an upper limit and a lower limit, and within the first threshold range, the first threshold range is greater than the lower limit and less than the upper limit.
In one embodiment, step S102 is followed by:
scanning the green light image of the acetic acid reaction image according with the second image quality requirement through a cross mark arranged at the center of a lens of the electronic colposcope, detecting the center position of the cervical orifice in the green light image of the acetic acid reaction image according with the second image quality requirement and recording the coordinates of the cervical orifice;
and according to the coordinate of the central position of the cervical orifice, intercepting the image area information of the cervical part in the green light image of the acetic acid reaction image which meets the second image quality requirement, converting the image area information into a green light image array of the acetic acid reaction image and storing the green light image array in a second cache.
And S103, acquiring an iodine reaction image during iodine reaction, and adjusting equipment parameters of the electronic colposcope according to the RGB value of the iodine reaction image so as to acquire and store the iodine reaction image meeting the third image quality requirement.
In this embodiment, after the iodine reaction image is collected, the RGB values of the iodine reaction image are obtained, and then it is determined whether the iodine reaction image meets the third image quality requirement according to the RGB values, if not, the device parameters of the electronic colposcope are adjusted, the iodine reaction image is collected again, and the collection, determination and adjustment are repeated in this way until the collected iodine reaction image meets the third image quality requirement, and then the collected iodine reaction image is stored in the third register.
In one embodiment, in step S103, adjusting the device parameters of the electronic colposcope according to the RGB values of the iodine reaction image to obtain and store an iodine reaction image meeting a third image quality requirement, specifically including:
step S1031, calculating the color deviation of the iodine reaction image through a color deviation detection algorithm according to the RGB value of the iodine reaction image;
step S1032, adjusting the camera module parameters of the electronic colposcope according to the color deviation of the iodine reaction image until the color deviation of the iodine reaction image reaches a second color deviation; the camera module parameters comprise aperture priority and shutter priority parameters, and R values and B values;
step S1033, detecting the definition of the iodine reaction image by an image definition detection method according to the RGB value of the iodine reaction image;
step S1034, adjusting acquisition card parameters of the electronic colposcope according to the definition of the iodine reaction image until the definition of the iodine reaction image reaches a second definition; wherein the acquisition card parameters comprise brightness, contrast, hue and saturation;
and step S1035, collecting and storing the iodine reaction image when the color deviation of the iodine reaction image reaches the second color deviation value and the definition reaches the second definition.
In this embodiment, the third image quality requirement means that the color deviation of the image reaches the second color deviation value and the definition reaches the second definition. The values of the second color deviation and the second sharpness may be set according to specific image quality requirements for the iodine responsive image, and the values of the second color deviation and the second sharpness may be altered according to differences in the image quality requirements.
In one embodiment, step S103 is followed by:
scanning the iodine reaction image meeting the third image quality requirement through a cross mark arranged at the center of a lens of the electronic colposcope, detecting the central position of a cervical orifice in the iodine reaction image meeting the third image quality requirement and recording the coordinate of the cervical orifice;
and intercepting the image area information of the cervical part in the iodine reaction image which meets the third image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into an iodine reaction image array and storing the iodine reaction image array in a third cache.
In a specific application, the image acquired during the iodine reaction is not necessarily an iodine reaction image, and may be an image in which the iodine reaction has not started or is not completed.
In one embodiment, the step of determining whether the acquired image is an iodine-reacted image comprises:
after the iodine reaction is started, acquiring an image in real time, converting the current frame image into pixel data and storing the pixel data in a fourth cache;
acquiring a difference value between pixel data of each pixel point of the current frame image and preset pixel data, and judging whether the absolute value of the difference value is greater than a first threshold value;
counting the number of pixel points of which the absolute value of the difference value in the current frame image is greater than a first threshold value;
and if the ratio of the number of the pixel points to the total number of the pixel points in the current frame image exceeds a second threshold value, determining that the current frame image is an iodine reaction image.
In a specific application, the first threshold and the second threshold may be set according to actual requirements, the first threshold is specifically related to the characteristics of the pixel data of the iodine reaction image, and the second threshold is specifically a percentage value, for example, 5%, 10%, 15%, or 20%.
In this embodiment, the principle of the electronic colposcope for collecting images is as follows: the detected imaging optical signal is converted into an electric signal in real time through a CCD or CMOS image photoelectric sensor, and then the electric signal is processed into a digital image signal through an image acquisition card.
In this embodiment, the display effect requirements of the images acquired by the electronic colposcope at different stages are different, and therefore, the images at different stages need to meet different image quality requirements.
In one embodiment, when the display effect of the image acquired at any stage meets the image quality requirement, prompt information is sent out, so that the user can acquire the image manually and store the image or the system can acquire the image automatically and store the image. When the information is collected manually, the prompt information is information which can be perceived by a human body, and specifically, the prompt information can be visual information and sound information, for example, prompt box information, light prompt information, voice prompt information and the like popped up on the display device. When the information is automatically collected, the prompt information can be a control instruction sent to the collection card by the controller in the system.
In the embodiment, the equipment parameters of the electronic colposcope are adjusted according to the RGB values of the images at each stage at different stages of the images collected by the electronic colposcope so as to collect and store the images meeting the image quality requirement, so that the images collected at each stage of the electronic colposcope can achieve the optimal display effect, and the accuracy of the diagnosis result is effectively improved.
Example two
As shown in fig. 3, this embodiment is implemented based on the first embodiment, and in this embodiment, the step S101 in the first embodiment includes:
and step S104, acquiring an original image, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the original image to acquire and store the original image meeting the fourth image quality requirement.
In a specific application, the cervical image cleaned by physiological saline is the required original image, and the acquired image may be an image which is not processed by physiological saline, so that before the original image is acquired, whether the acquired image is the original image or not needs to be judged.
In one embodiment, the step of determining whether the acquired image is an original image specifically includes:
acquiring a cervical image in real time, converting the previous cervical image into pixel data and storing the pixel data in a fourth cache;
converting the current cervical image into pixel data and storing the pixel data in a fifth cache;
acquiring a difference value between the pixel data of the previous cervical image and the pixel data of the current image, and judging whether the absolute value of the difference value is greater than a third threshold value;
and if the absolute value of the difference value is larger than a third threshold value, determining that the current frame image is an original image.
In a specific application, the third threshold may be set according to a difference requirement between the original image and the non-original image, and the size of the third threshold may be changed according to different difference requirements.
In this embodiment, after the original image is acquired, the RGB values of the original image are acquired, and then it is determined whether the original image meets the fourth image quality requirement according to the RGB values, if not, the device parameters of the electronic colposcope are adjusted, the original image is acquired again, and the acquisition, determination and adjustment are repeated in this way until the acquired original image meets the fourth image quality requirement, and then the acquired original image is stored in the fourth register.
In one embodiment, the adjusting the device parameters of the electronic colposcope according to the RGB values of the original image in step S104 to obtain and store an original image meeting a fourth image quality requirement specifically includes:
step S1041, calculating color deviation of the original image through a color deviation detection algorithm according to the RGB value of the original image;
step S1042, adjusting the camera module parameter of the electronic colposcope according to the color deviation of the original image until the color deviation of the original image reaches a third color deviation; the camera module parameters comprise aperture priority and shutter priority parameters, and R values and B values;
step S1043, detecting the definition of the original image by an image definition detection method according to the RGB value of the original image;
step S1044, adjusting acquisition card parameters of the electronic colposcope according to the definition of the original image until the definition of the original image reaches a third definition; wherein the acquisition card parameters comprise brightness, contrast, hue and saturation;
and S1045, when the color deviation of the original image reaches a third color deviation value and the definition reaches a third definition, collecting and storing the original image.
In this embodiment, the fourth image quality requirement means that the color deviation of the image reaches the third color deviation value and the definition reaches the third definition. The values of the third color deviation and the third definition may be set according to specific image quality requirements for the iodine responsive image, and the values of the third color deviation and the third definition may be changed according to the difference in the image quality requirements.
In one embodiment, step S104 is followed by:
scanning the original image meeting the fourth image quality requirement through a cross mark arranged at the center of a lens of the electronic colposcope, detecting the center position of the cervical orifice in the original image meeting the fourth image quality requirement and recording the coordinate of the cervical orifice;
and intercepting the image area information of the cervical part in the original image which meets the fourth image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into an original image array and storing the original image array in a fourth cache.
And step S105, acquiring a green light image of the original image meeting the fourth image quality requirement, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the green light image of the original image to acquire and store the green light image of the original image meeting the fifth image quality requirement.
In this embodiment, after the green light image of the original image meeting the fourth image quality requirement is acquired, the RGB values thereof are acquired, and then it is determined whether the green light image meets the fifth image quality requirement according to the RGB values thereof, if not, the device parameters of the electronic colposcope are adjusted, the green light image is acquired again, and the acquisition, determination and adjustment are repeated in this way until the acquired green light image meets the fifth image quality requirement, and then the acquired green light image is stored in the fifth register.
In one embodiment, in step S105, the adjusting the device parameters of the electronic colposcope according to the RGB values of the green image of the original image to obtain and store the green image of the original image meeting the fifth image quality requirement specifically includes:
step S1051, judging whether the green light parameter value of the green light image of the original image is in a second threshold value range according to the RGB value of the green light image of the original image;
step S1052, when the green light parameter value of the green light image of the original image is not within the second threshold range, calculating the color deviation of the green light image of the original image by a color deviation detection algorithm;
step S1053, adjusting the camera module parameter of the electronic colposcope according to the color deviation of the green light image of the original image until the green light parameter value of the green light image of the original image is within a second threshold value range; the camera module parameters comprise an R value and a B value;
and S1054, when the green light parameter value of the green light image of the original image is in a second threshold value range, acquiring and storing the green light image of the original image.
In this embodiment, the fifth image quality requirement means that the green light parameter value is within the second threshold range. The second threshold range may be set according to specific image quality requirements for the green image, and may be altered depending on the image quality requirements. The second threshold range includes an upper value and a lower value, and within the second threshold range, the second threshold range is greater than the lower value and less than the upper value.
In one embodiment, step S105 is followed by:
scanning the green light image of the original image according with the fourth image quality requirement through a cross mark arranged at the center of a lens of the electronic colposcope, detecting the center position of the cervical orifice in the green light image of the original image according with the fourth image quality requirement and recording the coordinates of the cervical orifice;
and intercepting the image area information of the cervical part in the green light image of the original image which meets the fourth image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into an original image array and storing the original image array in a sixth cache.
EXAMPLE III
As shown in fig. 4, this embodiment is implemented based on the first or second embodiment, and in this embodiment, the color deviation detection algorithm described in the first or second embodiment includes:
in step S201, RGB values of an image are acquired.
In this embodiment, when the color deviation detection algorithm is applied to different images in the above embodiments, the RGB values of the corresponding images are obtained.
Step S202, converting the RGB values of the image from the RGB color space to tristimulus values of the XYZ color space.
In this embodiment, the XYZ color space specifically refers to the XYZ color space conforming to the CIE (Commission international de L' Eclairage)1931 standard, and the tristimulus values refer to coordinate values of X (red), Y (green), and Z (blue) in the three primary colors in the XYZ color space.
In one embodiment, step S202 specifically includes:
step S2021, performing normalization processing on the RGB values of the image according to the following formula:
Figure BDA0001575630840000131
wherein d isrGray value representing red, dgGray value representing green, dbDenotes a gray value of blue, R'sRGB、G'sRGBAnd B'sRGBRespectively representing the gray value normalization results of red, green and blue;
step S2022, performing nonlinear transformation on the RGB values of the image after the normalization processing according to the following formula:
Figure BDA0001575630840000141
r'sRGB,G'sRGB,B'sRGB≤0.04045;
Figure BDA0001575630840000142
R'sRGB,G'sRGB,B'sRGB>0.04045;
R, G and B respectively represent the nonlinear transformation results after the gray value normalization of red, green and blue;
step S2023, converting the RGB values of the image after the nonlinear transformation from the RGB color space to tristimulus values of the XYZ color space according to the following formula:
Figure BDA0001575630840000143
x, Y and Z respectively represent tristimulus values of an XYZ color space, and if X, Y or Z is less than 0, the value is 0; if X, Y or Z is greater than 1, the value is 1.
In step S203, the tristimulus values are converted from XYZ color space into luminance values and two chrominance values of La × b color model.
In this embodiment, La × b color model specifically refers to a Lab color model conforming to CIE 1931 standard, where L represents a luminance value, a and b represent chrominance values of two color channels, a includes colors from dark green (low luminance value) to gray (medium luminance value) to bright pink red (high luminance value), and b includes colors from bright blue (low luminance value) to gray (medium luminance value) to yellow (high luminance value).
In one embodiment, step S203 specifically includes:
calculating the brightness value of the La b color model according to the following formula:
Figure BDA0001575630840000151
two colorimetric values of La × b color model were calculated according to the following formula:
Figure BDA0001575630840000152
wherein the content of the first and second substances,
Figure BDA0001575630840000153
Figure BDA0001575630840000154
Figure BDA0001575630840000155
wherein X, Y andz is the tristimulus value, X, of the XYZ color spacen、YnAnd ZnIs a predetermined standard tristimulus value of XYZ color space, L is a brightness value, a*And b*Are chrominance values.
And step S204, calculating the chromaticity difference between the chromaticity value and the set chromaticity to obtain the color deviation of the image.
In one embodiment, step S204 specifically includes:
according to the formula Δ a*=a* 1-a* sAnd Δ b*=b* 1-b* sCalculating the color deviation of the image;
wherein, a* sAnd b* sRepresenting a chrominance value of said image, a* 1And b* 1Indicates the set setting degree, Δ a*And Δ b*Indicating a color deviation.
Example four
As shown in fig. 5, this embodiment is implemented based on the first, second, or third embodiment, and in this embodiment, the method for detecting image sharpness in the first or second embodiment includes:
step S301, identifying the cervical orifice image in the image.
In this embodiment, step S301 specifically includes:
step S3011, obtaining RGB values of the image;
step S3012, converting the RGB values of the image from the RGB color space to the CMYK values of the three primary colors of the CMYK color space;
step S3013, performing threshold segmentation on the three primary colors CMYK value through an Otsu algorithm, and outputting a threshold corresponding to C channel data;
step S3014, obtaining a binary image of the image according to a threshold corresponding to the C channel data;
step S3015, carry on the swelling process to the said binary image, in order to inhibit the cervical mouth area in the picture because of sheltering from etc. factor and breaking into the situation of two or more areas;
step S3016, according to the maximum value and the minimum value of the area of the cervical orifice region which are preset, identifying the cervical orifice region in the binarized image after the expansion processing;
step S3017, excluding the peripheral area in the binarized image after the expansion processing according to the average distance from each pixel point in the cervical orifice area to the center of the binarized image after the expansion processing, so as to exclude the area which is easy to be confused in the peripheral area;
and step S3018, determining the boundary of the cervical orifice region by an active contour method to obtain a cervical orifice image.
Step S302, acquiring RGB values of the cervical orifice image.
In a specific application, the cervical opening image is specifically an image of the region 1 shown in fig. 2.
Step S303, acquiring the brightness and contrast of the cervical orifice image according to the RGB value of the cervical orifice image.
EXAMPLE five
The present embodiment provides an electronic colposcopic image adjustment system for performing the method steps of the first embodiment, which can be a software program system running in a computer of a workstation.
As shown in fig. 6, the electronic colposcope image adjusting system provided by the present embodiment includes:
the acetic acid reaction image adjusting module 101 is configured to start to acquire an acetic acid reaction image from a set time point when starting acetic acid reaction timing, and adjust an equipment parameter of the electronic colposcope according to an RGB value of the acetic acid reaction image to acquire and store an acetic acid reaction image meeting a first image quality requirement;
the first green light image adjusting module 102 is configured to acquire a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjust the device parameters of the electronic colposcope according to an RGB value of the green light image of the acetic acid reaction image to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement;
the iodine reaction image adjusting module 103 is configured to acquire an iodine reaction image during an iodine reaction, and adjust the device parameters of the electronic colposcope according to the RGB values of the iodine reaction image to acquire and store an iodine reaction image meeting a third image quality requirement.
In one embodiment, the system further comprises:
the device parameter setting module is used for setting and initializing the device parameters of the electronic colposcope; the device parameters comprise camera module parameters and acquisition card parameters, the camera module parameters comprise aperture priority and shutter priority parameters, R values and B values, and the acquisition card parameters comprise brightness, contrast, hue and saturation.
In one embodiment, the system further comprises:
the first scanning module is used for scanning the acetic acid reaction image meeting the first image quality requirement through a cross mark arranged at the center of a lens of the electronic colposcope, detecting the center position of the cervical orifice in the acetic acid reaction image meeting the first image quality requirement and recording the coordinates of the acetic acid reaction image;
and the first intercepting module is used for intercepting the image area information of the cervical part in the acetic acid reaction image which meets the first image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into an acetic acid reaction image array and storing the acetic acid reaction image array in a first cache.
In one embodiment, the system further comprises:
the second scanning module is used for scanning the green light image of the acetic acid reaction image meeting the second image quality requirement through a cross mark arranged at the center of the lens of the electronic colposcope, detecting the center position of the cervical orifice in the green light image of the acetic acid reaction image meeting the second image quality requirement and recording the coordinates of the cervical orifice;
and the second intercepting module is used for intercepting the image area information of the cervical part in the green light image of the acetic acid reaction image according with the second image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into a green light image array of the acetic acid reaction image and storing the green light image array in a second cache.
In one embodiment, the system further comprises:
the third scanning module is used for scanning the iodine reaction image meeting the third image quality requirement through a cross mark arranged at the center of the lens of the electronic colposcope, detecting the central position of the cervical orifice in the iodine reaction image meeting the third image quality requirement and recording the coordinate of the cervical orifice;
and the third intercepting module is used for intercepting the image area information of the cervical part in the iodine reaction image which meets the third image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into an iodine reaction image array and storing the iodine reaction image array in a third cache.
In the embodiment, the equipment parameters of the electronic colposcope are adjusted according to the RGB values of the images at each stage at different stages of the images collected by the electronic colposcope so as to collect and store the images meeting the image quality requirement, so that the images collected at each stage of the electronic colposcope can achieve the optimal display effect, and the accuracy of the diagnosis result is effectively improved.
EXAMPLE six
As shown in fig. 7, in the present embodiment, the electronic colposcopic image adjusting system in the fifth embodiment further comprises a structure for performing the method steps in the second embodiment, and further comprises:
the original image adjusting module 104 is configured to acquire an original image, adjust device parameters of the electronic colposcope according to an RGB value of the original image, and acquire and store the original image meeting a fourth image quality requirement;
and the second green light image adjusting module 105 is used for acquiring a green light image of the original image meeting the fourth image quality requirement, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the green light image of the original image so as to acquire and store the green light image of the original image meeting the fifth image quality requirement.
In one embodiment, the system further comprises:
and the judging module is used for judging whether the acquired image is an original image.
In one embodiment, the system further comprises:
the fourth scanning module is used for scanning the original image meeting the fourth image quality requirement through a cross mark arranged at the center of the lens of the electronic colposcope, detecting the central position of the cervical orifice in the original image meeting the fourth image quality requirement and recording the coordinate of the central position;
and the fourth intercepting module is used for intercepting the image area information of the cervical part in the original image which meets the fourth image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into an original image array and storing the original image array in a fourth cache.
In one embodiment, the system further comprises:
the fifth scanning module is used for scanning the green light image of the original image meeting the fourth image quality requirement through a cross mark arranged at the center of the lens of the electronic colposcope, detecting the center position of the cervical orifice in the green light image of the original image meeting the fourth image quality requirement and recording the coordinates of the cervical orifice;
and the fifth intercepting module is used for intercepting the image area information of the cervical part in the green light image of the original image according with the fourth image quality requirement according to the coordinate of the central position of the cervical orifice, converting the image area information into an original image array and storing the original image array in a sixth cache.
It should be understood that, the sequence numbers of the steps in the foregoing embodiments do not imply an execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
EXAMPLE seven
As shown in fig. 8, the present embodiment provides a terminal device 100, which includes: a processor 10, a memory 11 and a computer program 12, such as an electronic colposcopic image adjustment program, stored in the memory 11 and executable on the processor 10. The processor 10, when executing the computer program 12, implements the steps in the above-described embodiments of the electronic colposcopic image adjustment method, such as steps S101 to S103 shown in fig. 1. Alternatively, the processor 10, when executing the computer program 12, implements the functions of the modules in the system embodiments, such as the functions of the modules 101 to 103 shown in fig. 6.
Illustratively, the computer program 12 may be partitioned into one or more modules that are stored in the memory 11 and executed by the processor 10 to implement the present invention. The one or more modules may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution process of the computer program 12 in the terminal device 100. For example, the computer program 12 may be divided into an acetic acid response image adjustment module, a first green light image adjustment module, and an iodine response image adjustment module, and the specific functions of each module are as follows:
the acetic acid reaction image adjusting module is used for collecting an acetic acid reaction image from a set time point when the acetic acid reaction is started, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the acetic acid reaction image so as to collect and store the acetic acid reaction image meeting the first image quality requirement;
the first green light image adjusting module is used for acquiring a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the green light image of the acetic acid reaction image so as to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement;
and the iodine reaction image adjusting module is used for acquiring an iodine reaction image during iodine reaction, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the iodine reaction image so as to acquire and store the iodine reaction image meeting the third image quality requirement.
The terminal device 100 may be a desktop computer, a notebook, a palm computer, a cloud server, or other computing devices. The terminal device may include, but is not limited to, a processor 10, a memory 11. Those skilled in the art will appreciate that fig. 8 is merely an example of the terminal device 100 and does not constitute a limitation of the terminal device 100 and may include more or less components than those shown, or combine certain components, or different components, for example, the terminal device may also include input output devices, network access devices, buses, etc.
The Processor 10 may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 11 may be an internal storage unit of the terminal device 100, such as a hard disk or a memory of the terminal device 100. The memory 11 may also be an external storage device of the terminal device 100, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the terminal device 100. Further, the memory 11 may also include both an internal storage unit and an external storage device of the terminal device 100. The memory 11 is used for storing the computer program and other programs and data required by the terminal device. The memory 11 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the system is divided into different functional units or modules to perform all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the embodiments provided in the present invention, it should be understood that the disclosed system/terminal device and method can be implemented in other ways. For example, the above-described system/terminal device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implemented, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, systems or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated module, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, all or part of the flow of the method according to the embodiments of the present invention may also be implemented by a computer program, which may be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method embodiments may be implemented. . Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or system capable of carrying said computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, etc. It should be noted that the computer readable medium may contain content that is appropriately increased or decreased according to the image quality requirements of legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media that does not include electrical carrier signals and telecommunications signals according to legislation and patent practice.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present invention, and are intended to be included within the scope of the present invention.

Claims (9)

1. An electronic colposcope image adjustment method is characterized by comprising the following steps:
when the acetic acid reaction is started, collecting an acetic acid reaction image from a set time point, and adjusting equipment parameters of the electronic colposcope according to the RGB value of the acetic acid reaction image so as to collect and store the acetic acid reaction image meeting the first image quality requirement;
acquiring a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjusting equipment parameters of the electronic colposcope according to the RGB value of the green light image of the acetic acid reaction image so as to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement;
acquiring an iodine reaction image during iodine reaction, and adjusting equipment parameters of the electronic colposcope according to the RGB value of the iodine reaction image so as to acquire and store the iodine reaction image meeting the third image quality requirement;
adjusting the equipment parameters of the electronic colposcope according to the RGB values of the acetic acid reaction image so as to acquire and store the acetic acid reaction image meeting the first image quality requirement, and the method comprises the following steps:
calculating the color deviation of the acetic acid reaction image through a color deviation detection algorithm according to the RGB value of the acetic acid reaction image;
adjusting the parameters of a camera module of the electronic colposcope according to the color deviation of the acetic acid reaction image until the color deviation of the acetic acid reaction image reaches a first color deviation; the camera module parameters comprise aperture priority and shutter priority parameters, and R values and B values;
detecting the definition of the acetic acid reaction image by an image definition detection method according to the RGB value of the acetic acid reaction image;
adjusting acquisition card parameters of the electronic colposcope according to the definition of the acetic acid reaction image until the definition of the acetic acid reaction image reaches a first definition; wherein the acquisition card parameters comprise brightness, contrast, hue and saturation;
and when the color deviation of the acetic acid reaction image reaches a first color deviation value and the definition reaches a first definition, acquiring and storing the acetic acid reaction image.
2. The method for adjusting an electronic colposcope image as recited in claim 1, wherein adjusting the device parameters of the electronic colposcope according to the RGB values of the green image of the acetic acid reaction image to acquire and store the green image of the acetic acid reaction image meeting the second image quality requirement comprises:
judging whether a green light parameter value of the green light image of the acetic acid reaction image is within a first threshold value range according to the RGB value of the green light image of the acetic acid reaction image;
when the green light parameter value of the green light image of the acetic acid reaction image is not in the first threshold value range, calculating the color deviation of the green light image of the acetic acid reaction image through a color deviation detection algorithm;
adjusting the parameters of a camera module of the electronic colposcope according to the color deviation of the green light image of the acetic acid reaction image until the green light parameter value of the green light image of the acetic acid reaction image is within a first threshold range; the camera module parameters comprise an R value and a B value;
and when the green light parameter value of the green light image of the acetic acid reaction image is within a first threshold value range, acquiring and storing the green light image of the acetic acid reaction image.
3. The method for adjusting an electronic colposcope image as recited in claim 1, wherein adjusting the device parameters of the electronic colposcope according to the RGB values of the iodine response image to obtain and store an iodine response image meeting a third image quality requirement comprises:
calculating the color deviation of the iodine reaction image through a color deviation detection algorithm according to the RGB value of the iodine reaction image;
adjusting the parameters of a camera module of the electronic colposcope according to the color deviation of the iodine reaction image until the color deviation of the iodine reaction image reaches a second color deviation; the camera module parameters comprise aperture priority and shutter priority parameters, and R values and B values;
detecting the definition of the iodine reaction image by an image definition detection method according to the RGB value of the iodine reaction image;
adjusting acquisition card parameters of the electronic colposcope according to the definition of the iodine reaction image until the definition of the iodine reaction image reaches a second definition; wherein the acquisition card parameters comprise brightness, contrast, hue and saturation;
and when the color deviation of the iodine reaction image reaches a second color deviation value and the definition reaches a second definition, acquiring and storing the iodine reaction image.
4. The electronic colposcopic image adjustment method of any one of claims 1 to 3 wherein the color deviation detection algorithm comprises:
acquiring RGB values of an image;
converting the RGB values of the image from an RGB color space to tristimulus values of an XYZ color space;
converting the tristimulus values from an XYZ color space into a luminance value and two chrominance values of a La b color model;
calculating the chroma difference between the chroma value and the set chroma to obtain the color deviation of the image;
the image definition detection method comprises the following steps:
identifying a cervical os image in the image;
acquiring RGB values of the cervical orifice image;
and acquiring the brightness and contrast of the cervical orifice image according to the RGB value of the cervical orifice image.
5. The electronic colposcopic image adjustment method of claim 4 wherein converting the RGB values of the image from the RGB color space to tristimulus values in the XYZ color space comprises:
normalizing the RGB values of the image according to the following formula:
Figure FDA0003503671190000031
wherein d isrGray value representing red, dgGray value representing green, dbDenotes a gray value of blue, R'sRGB、G'sRGBAnd B'sRGBRespectively representing the gray value normalization results of red, green and blue;
and carrying out nonlinear transformation on the RGB value of the image after the normalization processing according to the following formula:
Figure FDA0003503671190000032
Figure FDA0003503671190000033
r, G and B respectively represent the nonlinear transformation results after the gray value normalization of red, green and blue;
converting the non-linearly transformed RGB values of the image from the RGB color space to tristimulus values in the XYZ color space according to the following formula:
Figure FDA0003503671190000041
x, Y and Z respectively represent tristimulus values of an XYZ color space, and if X, Y or Z is less than 0, the value is 0; if X, Y or Z is greater than 1, the value is 1;
converting the tristimulus values from the XYZ color space to luminance values and two chrominance values of a La b color model, comprising:
calculating the brightness value of the La b color model according to the following formula:
Figure FDA0003503671190000042
two colorimetric values of La × b color model were calculated according to the following formula:
Figure FDA0003503671190000043
wherein the content of the first and second substances,
Figure FDA0003503671190000044
Figure FDA0003503671190000045
Figure FDA0003503671190000051
wherein X, Y and Z are the tristimulus values, X, of the XYZ color space, respectivelyn、YnAnd ZnIs a standard tristimulus value of a predetermined XYZ color space.
6. The electronic colposcopic image adjustment method of claim 4 wherein identifying the cervical opening image in the image comprises:
acquiring RGB values of an image;
converting the RGB value of the image from an RGB color space into three primary colors CMYK value of a CMYK color space;
performing threshold segmentation on the three primary colors CMYK value through an Otsu algorithm, and outputting a threshold corresponding to C channel data;
obtaining a binary image of the image according to a threshold value corresponding to the channel C data;
performing expansion processing on the binary image;
identifying the cervical orifice region in the binarized image after the expansion processing according to the preset maximum value and minimum value of the cervical orifice region area;
according to the average distance from each pixel point in the cervical orifice region to the center of the binarized image after the expansion processing, excluding the peripheral region in the binarized image after the expansion processing;
and determining the boundary of the cervical orifice region by an active contour method to obtain a cervical orifice image.
7. An electronic colposcopic image adjustment system, comprising:
the acetic acid reaction image adjusting module is used for collecting an acetic acid reaction image from a set time point when the acetic acid reaction is started, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the acetic acid reaction image so as to collect and store the acetic acid reaction image meeting the first image quality requirement;
the first green light image adjusting module is used for acquiring a green light image of the acetic acid reaction image meeting the first image quality requirement, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the green light image of the acetic acid reaction image so as to acquire and store the green light image of the acetic acid reaction image meeting the second image quality requirement;
the iodine reaction image adjusting module is used for acquiring an iodine reaction image during iodine reaction, and adjusting the equipment parameters of the electronic colposcope according to the RGB value of the iodine reaction image so as to acquire and store an iodine reaction image meeting the third image quality requirement;
the acetic acid reaction image adjusting module is specifically used for:
calculating the color deviation of the acetic acid reaction image through a color deviation detection algorithm according to the RGB value of the acetic acid reaction image;
adjusting the parameters of a camera module of the electronic colposcope according to the color deviation of the acetic acid reaction image until the color deviation of the acetic acid reaction image reaches a first color deviation; the camera module parameters comprise aperture priority and shutter priority parameters, and R values and B values;
detecting the definition of the acetic acid reaction image by an image definition detection method according to the RGB value of the acetic acid reaction image;
adjusting acquisition card parameters of the electronic colposcope according to the definition of the acetic acid reaction image until the definition of the acetic acid reaction image reaches a first definition; wherein the acquisition card parameters comprise brightness, contrast, hue and saturation;
and when the color deviation of the acetic acid reaction image reaches a first color deviation value and the definition reaches a first definition, acquiring and storing the acetic acid reaction image.
8. A terminal device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any of claims 1 to 6 when executing the computer program.
9. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 6.
CN201810133584.8A 2018-02-09 2018-02-09 Electronic colposcope image adjusting method and system and terminal equipment Active CN110123254B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810133584.8A CN110123254B (en) 2018-02-09 2018-02-09 Electronic colposcope image adjusting method and system and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810133584.8A CN110123254B (en) 2018-02-09 2018-02-09 Electronic colposcope image adjusting method and system and terminal equipment

Publications (2)

Publication Number Publication Date
CN110123254A CN110123254A (en) 2019-08-16
CN110123254B true CN110123254B (en) 2022-04-05

Family

ID=67567744

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810133584.8A Active CN110123254B (en) 2018-02-09 2018-02-09 Electronic colposcope image adjusting method and system and terminal equipment

Country Status (1)

Country Link
CN (1) CN110123254B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115715663A (en) * 2019-10-22 2023-02-28 上海法路源医疗器械有限公司 Accurate screening system for cervical cancer

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5856733B2 (en) * 2010-11-02 2016-02-10 オリンパス株式会社 Imaging device
WO2012123881A2 (en) * 2011-03-16 2012-09-20 Koninklijke Philips Electronics N.V. Medical instrument for examining the cervix
CN103325128B (en) * 2013-05-16 2016-08-17 深圳市理邦精密仪器股份有限公司 A kind of method and device of Intelligent Recognition gynecatoptron acquired image feature
US10028649B2 (en) * 2013-12-02 2018-07-24 Welch Allyn, Inc. Digital colposcope system
CN103750810B (en) * 2013-12-30 2015-10-07 深圳市理邦精密仪器股份有限公司 Method and the device that image carries out feature analysis is obtained to electronic colposcope
CN103767658B (en) * 2013-12-30 2017-02-08 深圳市理邦精密仪器股份有限公司 Collection method of electronic colposcope images and device
CN105476598B (en) * 2016-01-12 2017-05-03 深圳市理邦精密仪器股份有限公司 Adjusting method and device for working distance of colposcope

Also Published As

Publication number Publication date
CN110123254A (en) 2019-08-16

Similar Documents

Publication Publication Date Title
CN110505459B (en) Image color correction method, device and storage medium suitable for endoscope
US9071761B2 (en) Information processing apparatus, information processing method, program, and imaging apparatus including optical microscope
US8289421B2 (en) Image-signal processing device and image signal processing program
WO2020119504A1 (en) Image processing method and system
JPH05223642A (en) Method and apparatus for colorimetry
CN108230407B (en) Image processing method and device
CN111161188B (en) Method for reducing image color noise, computer device and readable storage medium
CN110123254B (en) Electronic colposcope image adjusting method and system and terminal equipment
CN109729259B (en) Image processing apparatus, method thereof, system thereof, and computer readable medium
US8441543B2 (en) Image processing apparatus, image processing method, and computer program
TWM458747U (en) Image processing module
JP5074066B2 (en) Image processing apparatus and image processing method
WO2022057506A1 (en) Image sensor, terminal, data processing method and apparatus, and storage medium
US20230342934A1 (en) Oral cavity examination method, oral cavity examination device and computer-readable storage medium
CN110809145B (en) Image brightness conversion method, device and equipment based on Craik-O' Brien effect
CN113129356B (en) Capsule endoscope system, image staining area recognition method thereof, and storage medium
CN112070096B (en) Color recognition method, device, terminal equipment and storage medium
JP2002117402A (en) Image processing method and device thereof
CN113936017A (en) Image processing method and device
JP6413210B2 (en) Image processing apparatus, imaging apparatus, and program
CN113781330A (en) Image processing method, device and electronic system
CN101483784B (en) Fake color inhibition method for digital image
Constantinou et al. A comparison of color correction algorithms for endoscopic cameras
JP5983137B2 (en) Image processing apparatus, imaging apparatus, and program
WO2021147316A1 (en) Object recognition method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant