Endoscope processor, program, method for operating the endoscope processor, and method for controlling the focus lens.

The endoscope processor and control method address misjudgments in autofocus by using a proximity determination mode to ensure accurate transitions between observation states, preventing unnecessary autofocus and improving lesion detection during screening.

JP7848074B2Active Publication Date: 2026-04-20OLYMPUS MEDICAL SYST CORP
View PDF 8 Cites 0 Cited by

Patent Information

Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
OLYMPUS MEDICAL SYST CORP
Filing Date
2022-07-20
Publication Date
2026-04-20

AI Technical Summary

Technical Problem

Existing endoscope systems with autofocus functions risk misjudging observation states due to accidental changes in contrast values, leading to unnecessary autofocus activation during screening, which can make it difficult to detect lesions and stress the user.

Method used

An endoscope processor and control method that includes a proximity determination mode to detect transitions from a screening state to a close-up state by monitoring the change in image height and position of the focus lens, ensuring autofocus is only activated when necessary.

Benefits of technology

Prevents misjudgments and unnecessary autofocus during screening, enhancing the ability to detect lesions by maintaining focus without user stress.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007848074000001
    Figure 0007848074000001
  • Figure 0007848074000002
    Figure 0007848074000002
  • Figure 0007848074000003
    Figure 0007848074000003
Patent Text Reader

Abstract

To provide an endoscope processor, etc. capable of suppressing erroneous determination and preventing unnecessary auto-focusing in a screening state.SOLUTION: An endoscope processor includes a processor 30a that can be connected to an endoscope 10 having a moving mechanism 13 for a focus lens 11a of an objective optical system 11, and an imaging device 12. In the case where a variation in an image height of an effective image range accompanying control of the moving mechanism 13 in a proximity determination mode is 1% of less, the processor 30a determines whether or not a screening state is shifted to a proximity state on the basis of the position information on the focus lens 11a and the image, finishes the proximity determination mode if it determines that the state is shifted to the proximity state, and controls the moving mechanism 13 in an auto-focus mode.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to an endoscope processor that moves a focus lens of an endoscope by a moving mechanism to acquire an image, a program for controlling the endoscope, and a method for controlling the focus lens.

Background Art

[0002] When the imaging device has a higher pixel count and the size of one pixel becomes smaller, the depth of field becomes shallower. In endoscopes as well, the pixel count of the imaging device is increasing, and there are cases where the position of the subject goes out of the depth of field during imaging. In order to cope with such cases, endoscopes equipped with an autofocus function have been proposed.

[0003] By the way, there are roughly two observation scenes for observing a subject with an endoscope.

[0004] One of the observation scenes is an observation scene in a screening state for observing a subject in a wide distance range from a long shot to a close-up to detect a lesion. In the screening state, it is preferable to fix the position of the focus lens at the far point end so that the focus is in focus over as wide a distance range as possible from the long shot to the close-up.

[0005] The other observation scene is an observation scene in a proximity state in which the tip of the insertion portion of the endoscope is brought close to the lesion in order to diagnose the lesion found in the screening state in more detail. In the proximity state, it is preferable that autofocus operates so that the lesion remains in focus.

[0006] When autofocus operates in the screening state, the distance range to the subject portion that is in focus changes, which may make it difficult to detect a lesion and may stress the user. Therefore, techniques for preventing unnecessary autofocus have been proposed in the past.

[0007] For example, Japanese Patent No. 6177387 discloses a technology that determines whether the observation state is a screening observation state or a close-up magnification observation state based on the amount of change in the contrast value over time, and if it is determined to be the close-up magnification observation state, it automatically switches to autofocus control and starts autofocus control. [Prior art documents] [Patent Documents]

[0008] [Patent Document 1] Japanese Patent No. 6177387 [Overview of the Initiative] [Problems that the invention aims to solve]

[0009] However, Japanese Patent No. 6177387 determines the observation state based on the change in contrast value accompanying the movement of the endoscope manually by the user. Therefore, there is a risk that the system may mistakenly determine that the state has shifted to close-up if the contrast value changes accidentally due to parallel movement relative to the subject, or if the image becomes blurred due to the user's abrupt movement of the endoscope.

[0010] This invention has been made in view of the above circumstances, and aims to provide an endoscope processor, program, and control method for a focus lens that can suppress misjudgments and prevent unnecessary autofocus during screening. [Means for solving the problem]

[0011] An endoscope processor according to one aspect of the present invention is connectable to an endoscope comprising: an objective optical system including a focus lens that forms an optical image of a subject; a moving mechanism for moving the focus lens; and an imaging device that captures the optical image and acquires an image, and comprises a processor, the processor controlling the moving mechanism in either an autofocus mode for automatically focusing on the subject or a proximity determination mode for determining whether or not the state has transitioned from a screening state to a close-up state, the processor executing the proximity determination mode while the autofocus mode is off, and during the proximity determination mode, if the change in image height of the effective image range due to the control of the moving mechanism is 1% or less, the processor determining whether or not the state has transitioned from a screening state to a close-up state based on the position information of the focus lens and the change in the image, and if it is determined that the state has transitioned to a close-up state, the processor ending the proximity determination mode and controlling the moving mechanism in the autofocus mode.

[0012] A program according to one aspect of the present invention causes a computer controlling an endoscope to control a movement mechanism that moves a focus lens included in the objective optical system of the endoscope, either an autofocus mode for automatically focusing on a subject or a proximity determination mode for determining whether or not the system has transitioned from a screening state to a close-up state; while the autofocus mode is off, the computer causes the computer to execute the proximity determination mode; during the proximity determination mode, if the fluctuation in the image height of the effective image range is 1% or less, the computer causes the computer to determine whether or not the system has transitioned from a screening state to a close-up state based on the position information of the focus lens and the changes in the image acquired by the imaging device provided by the endoscope; and if it is determined that the system has transitioned to a close-up state, the computer causes the computer to terminate the proximity determination mode and control the movement mechanism in autofocus mode.

[0013] According to one aspect of the present invention How to operate an endoscope processor teeth, An endoscope processor that can be connected to an endoscope,An image is acquired from the endoscope, position information of the endoscope's focus lens is acquired, and while the movement mechanism of the endoscope's focus lens is controlled in proximity detection mode, if the fluctuation in the image height of the effective image range is 1% or less, it is determined whether the system has transitioned from the screening state to the proximity state based on the position information of the focus lens and the change in the image. If it is determined that the system has transitioned to the proximity state, the proximity detection mode is terminated and the movement mechanism is controlled in autofocus mode. A method for controlling a focus lens according to one aspect of the present invention involves an image processing device acquiring an image from an endoscope, a focus lens controller acquiring position information of the focus lens of the endoscope, and while the focus lens controller is controlling the movement mechanism of the focus lens of the endoscope in proximity determination mode, a proximity state determination device determines whether a transition from a screening state to a proximity state has occurred based on the position information of the focus lens and the change in the image, when the fluctuation in the image height of the effective image range is 1% or less, and if the proximity state determination device determines that a transition to the proximity state has occurred, the focus lens controller terminates the proximity determination mode and controls the movement mechanism in autofocus mode. [Effects of the Invention]

[0014] According to the endoscope processor, program, and focus lens control method of the present invention, misjudgments can be suppressed and unnecessary autofocus can be prevented during the screening state. [Brief explanation of the drawing]

[0015] [Figure 1] This block diagram shows the structural and functional configuration of the endoscope system according to the first embodiment of the present invention. [Figure 2] This is a block diagram showing an example of the hardware configuration of the endoscope processor according to the first embodiment described above. [Figure 3] This timing chart shows an example of the process by which the focus lens controller moves the focus lens to the moving mechanism based on the control of the system controller in the first embodiment described above. [Figure 4] This is a diagram illustrating the image height of the effective image range in the first embodiment described above. [Figure 5] This is a timing chart showing an example in the first embodiment described above where the focus lens makes one reciprocating motion from the far point end to the near-far point end. [Figure 6] This graph shows an example of the contrast difference between the far-point image and the near-far-point image, depending on the distance to the subject, in the first embodiment described above. [Figure 7]It is a block diagram showing the structural and functional configurations of the endoscope system according to the modification of the first embodiment described above. [Figure 8] It is a block diagram showing the structural and functional configurations of the endoscope system according to the second embodiment of the present invention. [Figure 9] In the endoscope system according to the second embodiment described above, it is a graph showing an example in which a magnitude relationship occurs between the contrast difference of the first image and the contrast difference of the second image due to the reciprocating movement of the focus lens. [Figure 10] In the endoscope system according to the second embodiment described above, it is a graph showing an example in which the difference between the contrast differences is used for determination when the contrast difference of the first image and the contrast difference of the second image change due to the reciprocating movement of the focus lens. [Figure 11] It is a block diagram showing the structural and functional configurations of the endoscope system according to the third embodiment of the present invention. [Figure 12] It is a flowchart showing the operation of the endoscope system according to the third embodiment described above. [Embodiments for Carrying Out the Invention]

[0016] Hereinafter, embodiments of the present invention will be described with reference to the drawings. However, the present invention is not limited by the embodiments described below. [First Embodiment]

[0017] FIGS. 1 to 6 show the first embodiment of the present invention, and FIG. 1 is a block diagram showing the structural and functional configurations of the endoscope system according to the first embodiment. In FIG. 1 (and FIGS. 8 and 11 described later as well), solid arrows mainly indicate the flow of image signals, and dotted arrows mainly indicate the flow of control signals.

[0018] The endoscope system includes an endoscope 10, a light source device 20, an endoscope processor 30, an external interface (external I / F) 40, and a monitor 50.

[0019] The endoscope 10 is equipped with an insertion portion 10a that is inserted into a subject. Here, the subject into which the insertion portion 10a is inserted may be a living organism such as a person or an animal, or it may be a non-living object such as a machine or a building.

[0020] The endoscope 10 is configured as an electronic endoscope, and the tip of the insertion section 10a is equipped with an objective optical system 11, an image sensor 12, a movement mechanism 13, and an illumination lens 14.

[0021] The objective optical system 11 forms an optical image of the subject within the specimen onto the image sensor 12. The objective optical system 11 includes a focus lens 11a, the focus lens 11a is movable along the optical axis of the objective optical system 11 at position P. When the position P of the focus lens 11a is moved, the in-focus portion (the portion of the subject that is in focus) of the subject in the optical image formed on the image sensor 12 changes.

[0022] In this invention, the subject refers to the part that the user wants to observe. For example, in screening mode, the entire organ is the subject. In close-up observation mode, the subject is a part suspected of being a lesion, such as polyps, inflammation, tumors, neovascularization, mucosal deformities, or areas with a different color.

[0023] The image sensor 12 constitutes an imaging device and has pixels arranged in a two-dimensional manner that convert incident light into electrical signals. The image sensor 12 captures the optical image formed by the focus lens 11a to acquire an image and outputs it, for example, as an analog imaging signal. The image sensor 12 captures images, for example, on a frame-by-frame basis and sequentially outputs imaging signals related to multiple frames in a time series.

[0024] Examples of image sensors 12 include solid-state image sensors such as CMOS (Complementary Metal-Oxide Semiconductor) image sensors and CCD (Charge Coupled Device) image sensors, but are not limited to a specific configuration. Furthermore, image sensors 12 may be either color or monochrome image sensors. If image sensors 12 are color image sensors, they may be equipped with primary color filters, complementary color filters, etc., and the filter array may be a Bayer array or other filter arrays. In addition, image sensors 12 may be image-plane phase-detection AF type image sensors equipped with phase-detection pixels that receive light from the objective optical system 11 by pupil division. An example of image sensors 12 being image-plane phase-detection AF type image sensors will be explained later.

[0025] The moving mechanism 13 is a mechanism that moves the focus lens 11a along the optical axis of the objective optical system 11. The moving mechanism 13 includes, for example, an actuator as a drive source.

[0026] The illumination lens 14 projects illumination light transmitted via the light guide 15 (described later) onto the subject.

[0027] A light guide 15 is installed inside the endoscope 10, including the insertion section 10a. The exit end of the light guide 15 faces the illumination lens 14, and the input end of the light guide 15 is connected to the light source device 20.

[0028] The light source device 20 comprises a light source controller 21 and a light source 22.

[0029] The light source controller 21 controls the light intensity of the light source 22 according to the control of the system controller 36 in the endoscope processor 30, which will be described later. The light intensity of the light source 22 by the light source controller 21 may be controlled using appropriate control methods such as controlling the luminescence brightness or controlling the duty cycle in PWM (Pulse Width Modulation).

[0030] The light source 22 emits illumination light using a light-emitting device. The light source 22 can be equipped with one or more types of light-emitting devices, such as an LED (Light Emitting Diode) light source, a laser light source, or a xenon light source. However, the light-emitting device is not limited to the examples given herein, and publicly known technologies can be used as appropriate.

[0031] Illumination light emitted from the light source 22 enters the incident end of the light guide 15. The light guide 15 transmits the illumination light that entered from the incident end to the exit end. The transmitted illumination light is emitted from the exit end of the light guide 15 and illuminates the subject by the illumination lens 14.

[0032] The endoscope processor 30 performs image processing on the imaging signal acquired by the image sensor 12 of the endoscope 10. The endoscope processor 30 may also control the entire endoscope system, including not only the endoscope but also the monitor and other components.

[0033] The endoscope processor 30 includes, as hardware, a preprocessing device 31 equipped with an AD (analog-to-digital) converter 32 and an image processing device 33, a proximity state determination device 34, a focus lens controller 35, and a system controller 36.

[0034] Figure 1 is a block diagram showing the functional configuration of each hardware component of the endoscope processor 30, while Figure 2 is a block diagram showing an example of the configuration of the endoscope processor 30 of the first embodiment when viewed in terms of structural units.

[0035] As shown in Figure 2, the endoscope processor 30 comprises a processor 30a and a memory 30b. The processor 30a includes, for example, an ASIC (Application Specific Integrated Circuit) including a CPU (Central Processing Unit), an FPGA (Field Programmable Gate Array), and the like.

[0036] The memory 30b includes, for example, a volatile storage medium such as RAM (Random Access Memory) and a non-volatile storage medium such as ROM (Read Only Memory) (or EEPROM (Electrically Erasable Programmable Read-Only Memory)). The RAM temporarily stores various information such as the image to be processed, processing parameters at runtime, and user settings input from the external I / F 40. The ROM non-volatilely stores various information such as the processing program (computer program), default values ​​for processing parameters, and user settings that should be retained even when the power of the endoscope system is turned off.

[0037] The processor 30a shown in Figure 2 reads and executes the processing program stored in the memory 30b, thereby performing the various functions of the endoscope processor 30 as shown in Figure 1. However, all or part of the functions of the endoscope processor 30 may be performed by a dedicated electronic circuit.

[0038] Furthermore, although this example describes a scenario where the processing program is stored in memory 30b, the processing program (or at least a part of the processing program) may also be stored on a portable storage medium such as a flexible disk or CD (Compact Disc)-ROM, a storage medium such as a hard disk or SSD (Solid State Drive), or a storage medium in the cloud. In this case, the processing program can be read from the external storage medium via the external I / F 40 and stored in memory 30b, and the processor 30a can then execute the processing program.

[0039] The AD converter 32 converts the analog imaging signal output from the image sensor 12 into a digital image and outputs it to the image processing device 33. Note that if the image sensor 12 is a digital image sensor that outputs a digital imaging signal, the AD converter 32 may be omitted.

[0040] The image processing device 33 performs various image processing operations on the images output sequentially frame by frame from the AD converter 32, such as white balance processing, demosaicing (simultaneous processing), noise reduction processing, color conversion processing, gradation conversion processing, or edge enhancement processing. The images processed by the image processing device 33 are output to the proximity state determination device 34 and the monitor 50. The images are also output to the focus lens controller 35, for example, via the proximity state determination device 34 (however, the focus lens controller 35 may directly acquire the image from the preprocessor 31).

[0041] Here, we have described an example in which the image processing device 33 outputs an image that has undergone a series of image processing steps to the proximity state determination device 34, but this is not the only example. That is, since the proximity state determination device 34 performs determinations related to autofocus (AF) control, real-time performance is required. Therefore, the image output from the image processing device 33 to the proximity state determination device 34 can be any of the following: an image that has only undergone AD conversion (RAW image), an image that has undergone demosaicing in addition to AD conversion, or an image in which some of the multiple image processing steps have been omitted.

[0042] Furthermore, the image output from the image processing device 33 to the proximity state determination device 34 and the focus lens controller 35 does not have to be the entire image. For example, the system controller 36, which is a control device, functions as a region setting unit and sets an AF region (which also serves as a determination region for the proximity state determination device 34 to determine whether or not the image has entered a close-up state) in at least a part of the image acquired by the image sensor 12.

[0043] The system controller 36 may set the AF area to the center of the image, to the periphery of the image, or to multiple areas. Furthermore, the system controller 36 may arbitrarily set the AF area in response to input from the external I / F 40, for example, in response to user operation.

[0044] Alternatively, the system controller 36 may detect a specific subject or part of a subject in the image (e.g., a lesion) and move the AF area to track the movement of the specific subject or part of a subject. The system controller 36 may also detect an area in the image that is likely to be of interest to the user (e.g., an area with proper exposure) and set that as the AF area.

[0045] The proximity state determination unit 34 determines, based on the position P information of the focus lens 11a and the image output from the image processing device 33, whether the tip of the insertion section 10a of the endoscope 10 has transitioned from a state where it is not close to the subject (screening state) to a state where it is close (proximity state). Here, the tip refers to a predetermined area including the objective optical system 11. If the proximity state determination unit 34 determines that the state has transitioned to the proximity state, it outputs an AF start signal to the focus lens controller 35.

[0046] The focus lens controller 35 sends a control command to the moving mechanism 13 to move the focus lens 11a to the moving mechanism 13. The focus lens controller 35 controls the moving mechanism 13 in either the AF (autofocus) mode (AF control mode) which automatically focuses on the subject, or the proximity detection mode (proximity detection control mode) which determines whether or not the subject has entered a close-up state, and moves the focus lens 11a.

[0047] Here, there are two main types of observation scenarios when observing a subject with an endoscope.

[0048] One observation scenario is the screening scenario. The screening scenario involves observing subjects across a wide distance range, from distant to near, to detect lesions. When the position P of the focus lens 11a is fixed at the far point Pf (see Figures 3 and 5) or near the far point, a wide distance range from distant to near is in focus (i.e., the depth of field becomes as deep as possible), which is preferable for a screening scenario. When the position P of the focus lens 11a is fixed at the far point Pf, the depth of field is maximized.

[0049] Furthermore, if autofocus is activated during screening, the distance range to the in-focus subject changes, which may make it difficult to detect lesions in certain areas. Also, the change in the in-focus subject area can cause stress to the user. Therefore, the focus lens controller 35 controls the system using proximity detection mode to prevent autofocus from operating during screening.

[0050] Another observation scenario is the close-up observation scenario. When a lesion is found in the screening state, the tip of the insertion part 10a is brought closer to the lesion in order to diagnose the discovered lesion in more detail. In the close-up state, the tip of the insertion part 10a is closer to the subject than in the screening state. If the focus lens 11a is fixed at its far end Pf in the screening state and the device is brought close to the lesion, the lesion to be observed will fall out of the depth of field. Therefore, in the close-up state, the focus lens controller 35 controls the device using AF mode so that autofocus operates and the lesion remains in focus.

[0051] The AF mode (AF control mode) is a mode in which the focus lens 11a is automatically moved by performing AF control so that the subject remains in focus even if the distance from the tip of the insertion part 10a to the subject changes. The AF control by the focus lens controller 35 may be performed by contrast AF, phase-detection AF, or any other AF control method, and is not limited to a specific method.

[0052] Contrast AF is performed by the focus lens controller 35 acquiring multiple frames of images while changing the position of the focus lens 11a, extracting the contrast component from the images as is well known, and moving the focus lens 11a to the position where the contrast component takes its maximum value.

[0053] Furthermore, when the image sensor 12 is, for example, an image-plane phase-difference AF image sensor, phase-difference AF is performed based on phase-difference information acquired from the phase-difference pixels of the image sensor 12. Using an image-plane phase-difference AF image sensor 12 eliminates the need for a separate phase-difference AF sensor, thus having the advantage of not increasing the size of the endoscope 10.

[0054] As mentioned above, autofocus is generally not operated in the screening state, but it is necessary to determine whether the observation scene has transitioned from the screening state to the close-up state. For this reason, in the close-up determination mode (control mode for determining the close-up state), the focus lens controller 35 controls the position P of the focus lens 11a to a degree that does not interfere with the observation of the user performing the screening (i.e., to a degree that the distance range to the in-focus subject part does not change significantly), and determines whether the scene has transitioned to the close-up state based on the image acquired with the position P changed. The processing in this close-up determination mode will be explained in more detail later.

[0055] When the focus lens controller 35 receives an AF start signal from the proximity state detector 34 while controlling in proximity detection mode, it terminates proximity detection mode and switches to AF mode. Once control in AF mode is performed, the movement mechanism 13 controls the focus lens 11a using AF.

[0056] Furthermore, when the focus lens controller 35 receives an AF termination signal while controlling in AF mode, it terminates the AF mode and switches to proximity detection mode. In this embodiment, the AF termination signal is output, for example, when the proximity state determination device 34 determines that the proximity state is over (i.e., has transitioned to the screening state). (Therefore, in this embodiment, the proximity state determination device 34 also functions as the screening state determination device 37, as described in the third embodiment described later.) However, as described in the third embodiment, a screening state determination device 37 that outputs an AF termination signal when it determines that the state has transitioned from the proximity state to the screening state may be provided separately from the proximity state determination device 34.

[0057] The system controller 36 is a control device that receives input signals from the external I / F 40 and controls the entire endoscope system, including the image sensor 12, image processing device 33, focus lens controller 35, and light source controller 21. The system controller 36 outputs control signals to the image sensor 12, causing the image sensor 12 to acquire an image. The system controller 36 outputs control signals to the image processing device 33 based on various processing parameters necessary for image processing, causing the image processing device 33 to process the image acquired from the image sensor 12. The system controller 36 receives the image from the image processing device 33 and sends control signals to the light source controller 21 so that the subject is at an appropriate brightness.

[0058] External I / F40 is an interface for the user to operate and input to the endoscope system. External I / F40 may include operating devices such as a keyboard, mouse, or trackball that are connected to the endoscope processor 30. External I / F40 may also include connection interfaces for connecting to an in-hospital system or the cloud.

[0059] The external I / F 40 includes, for example, setting buttons for setting AF mode / proximity detection mode, and setting buttons for setting processing parameters used when image processing is performed by the image processing device 33. At least some of the setting buttons described here as being included in the external I / F 40 may be provided on the endoscope processor 30 itself, or on an operating unit connected to the proximal end of the insertion section 10a of the endoscope 10.

[0060] The monitor 50 displays images output sequentially from the endoscope processor 30. The images are displayed chronologically, for example, in frames, and are observed as moving images. The images output from the endoscope processor 30 may also be images that have been processed by the image processing device 33 and overlaid with various information such as text information and guide information for operating the endoscope 10.

[0061] The system controller 36 described above further transmits a control signal corresponding to the proximity detection mode or AF mode to the focus lens controller 35, causing the focus lens controller 35 to control the movement mechanism 13.

[0062] In AF mode, the system controller 36 causes the focus lens controller 35 to control the movement mechanism 13 so that the subject within the AF area remains in focus.

[0063] Furthermore, in proximity detection mode, the system controller 36 basically causes the focus lens controller 35 to control the movement mechanism 13 so that the position P of the focus lens 11a becomes the far end Pf.

[0064] However, as described above, in proximity detection mode, in order to determine whether or not the system has transitioned from the screening state to the proximity state, the system controller 36 causes the focus lens controller 35 to control the movement mechanism 13 so that the position P of the focus lens 11a changes slightly from the far point Pf.

[0065] Figure 3 is a timing chart showing an example of the process in which the focus lens controller 35 moves the focus lens 11a to the movement mechanism 13 based on the control of the system controller 36 in the first embodiment.

[0066] As shown in Figure 3, in the proximity detection mode performed in the screening state, the position P of the focus lens 11a is basically fixed at the far point end Pf. However, in the proximity detection mode, the focus lens controller 35 periodically or aperiodicly moves the focus lens 11a from the far point end Pf towards the near point by a small amplitude A and then returns it to the far point end Pf. Hereafter, the position P (a position different from the far point end) where the focus lens 11a has moved from the far point end Pf towards the near point by an amplitude A will be referred to as the quasi-far point end Pqf.

[0067] Here, as described above, amplitude A is an amplitude that slightly changes the position P of the focus lens 11a to such an extent that the distance range to the in-focus subject remains almost unchanged. Since the in-focus subject remains almost unchanged even when amplitude A is moved back and forth, the observation of the user performing the screening is not hindered.

[0068] When the focusing lens 11a moves to the near-far point Pqf, the image sensor 12 acquires at least one frame of image. To further reduce user discomfort by shortening the time the focusing lens 11a is at the near-far point Pqf, it is advisable to set the image acquired by the image sensor 12 at the near-far point Pqf to, for example, one frame for each round trip movement.

[0069] Figure 3 shows an example where a reciprocating motion with amplitude A is performed N times (N=2 in the illustrated example) for each period T.

[0070] In the example in Figure 3, at the beginning of the period T along time t, the focus lens 11a is moved to the near-far point Pqf to acquire one frame of image. After acquiring the image, the focus lens 11a is immediately moved back to the far point Pf to acquire the next frame of image. Subsequently, the focus lens 11a is moved to the near-far point Pqf to acquire one frame of image, and the focus lens 11a is immediately moved back to the far point Pf. After that, multiple images are continuously acquired at the far point Pf on a frame-by-frame basis until, for example, the period T ends.

[0071] In proximity detection mode, the focus lens controller 35 moves the focus lens 11a to an extent that does not interfere with screen observation, preferably to an extent that is imperceptible to the user. The amount of movement of the focus lens 11a is preferably such that the variation in the image height h of the effective image range EIA (see column A in Figure 4) is 1% or less, more preferably 0.5% or less, and even more preferably 0.1% or less. In this invention, the effective image range EIA is the range of the image displayed on the monitor 50.

[0072] Figure 4 is a diagram illustrating the image height h of the effective image area (EIA) in the first embodiment. Column A of Figure 4 shows a perspective view, and column B shows a plane perpendicular to the effective image area (EIA) that includes the image height h. As shown in Figure 4, the image height h can be calculated from half the field of view (θ) and the focal length (f) using Equation 1. [Formula 1] h = f × tanθ

[0073] The focusing lens 11a moves in at least one direction, preferably toward the near-field, more preferably toward the far-field after moving toward the near-field, and even more preferably reciprocating. For example, the focusing lens 11a may perform a periodic reciprocating motion as shown in Figure 3, every period T.

[0074] By setting the number of round-trip movements to N=2 and acquiring multiple images at the quasi-far point Pqf, the measurement error can be reduced compared to when N=1, and the user discomfort can be reduced compared to when N≧3. However, it is also acceptable to further reduce user discomfort by setting N=1. Alternatively, by setting N≧3, the transition to the near-field state can be detected with higher accuracy.

[0075] Furthermore, when the reciprocating motion of the focus lens 11a is performed periodically, the period T may be shortened so that the transition to the close-up state can be detected at the shortest possible frame interval (i.e., as close to real-time as possible). In addition, the amplitude A may be made as large as possible without causing discomfort to the user so that the transition to the close-up state can be detected with higher accuracy.

[0076] On the other hand, if the reciprocating motion of the focus lens 11a is performed aperiodically, for example, the focus lens 11a may be moved back and forth at random timings based on the frame period.

[0077] Furthermore, non-periodic reciprocating motion may be achieved by performing a reciprocating motion of the focus lens 11a when it is detected that the acquired image is an image of a specific scene, and not performing a reciprocating motion of the focus lens 11a when it is not detected that the acquired image is an image of a specific scene. Here, an example of a specific scene is a scene that is likely to be in close proximity. Detection of a specific scene may be performed, for example, by an AI (Artificial Intelligence) that has been trained on images of close proximity. Alternatively, detection of a specific scene may be performed based on the change in brightness of multiple images acquired in a time series, and / or motion vectors detected from the images (see the description of the third embodiment below).

[0078] The starting point when moving the focus lens 11a toward the near point, or the ending point when moving the focus lens 11a toward the far point, is preferably within a predetermined range from the far point end, and more preferably at the far point end.

[0079] Next, a method for determining whether the focus lens 11a has transitioned from the screening state to the close-up state by moving it back and forth will be described with reference to Figures 5 and 6. Figure 5 is a timing chart showing an example in the first embodiment in which the focus lens 11a moves back and forth once from the far point end Pf to the near-far point end Pqf. Figure 6 is a graph showing an example of the contrast difference C between the far point end image and the near-far point end image according to the distance d to the subject in the first embodiment.

[0080] In Figure 5, time t1 and time t2 differ by only one frame period, and time t2 and time t3 also differ by only one frame period.

[0081] At time t1, when the focusing lens 11a is at the far point Pf, the far point image (Pf:t1) is acquired; at time t2, when the focusing lens 11a is at the near-far point Pqf, the near-far point image (Pqf:t2) is acquired; and at time t3, when the focusing lens 11a is at the far point Pf, the far point image (Pf:t3) is acquired. In other words, the far point image (Pf:t1), the near-far point image (Pqf:t2), and the far point image (Pf:t3) are multiple images with different focus positions over time, obtained when the focusing lens 11a is moved back and forth.

[0082] The proximity state determination unit 34 determines whether or not the image has entered a close-up state based on the changes in the image when the focus position is changed. More specifically, the proximity state determination unit 34 calculates image information for multiple images with different focus positions. For example, the proximity state determination unit 34 calculates the contrast of the far-point image (Pf:t1) and the near-far-point image (Pqf:t2) as image information. More specifically, the proximity state determination unit 34 calculates the contrast value of each pixel within the AF region, which is the region for calculating image information, and further calculates the contrast value of each image as the average (or sum, etc.) of the contrast values ​​within the AF region. In the following explanation, the contrast value of an image will be described as referring to the average (or sum) of the contrast values ​​within the AF region in the image.

[0083] Furthermore, using the average or sum has the advantage of reducing the amount of computation and suppressing the increase in cost due to a larger buffer size. On the other hand, comparing the contrast value of each pixel within the AF area across multiple images with different time-sequentially consecutive focus positions has the advantage of enabling precise calculations, and the latter can also be adopted in this invention.

[0084] In this case, the part of the image within the depth of field is in focus, the part of the image outside the depth of field is out of focus, and the contrast value of the image is high in the in-focus area and low in the out-of-focus area.

[0085] For example, the portion of the image that is in the central part of the depth of field in the far-point image (Pf:t1) is also within the depth of field in the near-far-point image (Pqf:t2), which is obtained by slightly changing the position P of the focus lens 11a, and is therefore in focus in both images. For this reason, there is almost no difference in contrast value (simply called the "contrast difference") between the far-point image (Pf:t1) and the near-far-point image (Pqf:t2).

[0086] Furthermore, the portion of the image that is far outside the depth of field in the far-point image (Pf:t1) is also far outside the depth of field in the near-far-point image (Pqf:t2), resulting in significant blurring in both images. Therefore, the contrast difference between the far-point image (Pf:t1) and the near-far-point image (Pqf:t2) is small.

[0087] On one hand, the depth of field indicating the distance range to the in-focus subject part has a depth end on the far point side and a depth end on the near point side. For example, in the vicinity outside the depth end on the near point side of the depth of field, what was in a "blurred state" in the far point end image (Pf:t1) changes to an "in-focus state" in the quasi-far point end image (Pqf:t2). Also, in the vicinity outside the depth end on the far point side of the depth of field, what was in an "in-focus state" in the far point end image (Pf:t1) changes to a "blurred state" in the quasi-far point end image (Pqf:t2). Therefore, the contrast difference between the far point end image (Pf:t1) and the quasi-far point end image (Pqf:t2) is larger at the depth end of the depth of field than at the central part of the depth of field and at parts that are greatly outside the depth of field.

[0088] Figure 6 shows how the contrast difference C changes according to the distance d to the subject.

[0089] The contrast difference C is calculated, for example, as the absolute value of the value obtained by subtracting the contrast value of the far point end image (Pf:t1) from the contrast value of the quasi-far point end image (Pqf:t2).

[0090] The reason for calculating the absolute value here is to avoid the complexity caused by the sign changing depending on whether the depth end is the depth end on the far point side or the depth end on the near point side, and which one is subtracted from which between the quasi-far point end image (Pqf:t2) and the far point end image (Pf:t1). However, if case-by-case classification is done according to the sign, it is not necessary to take the absolute value. When doing case-by-case classification, for example, not only the maximum value (see Figure 6) described later but also the minimum value may need to be considered in some cases.

[0091] In the example shown in Figure 6, in the range where the distance d to the subject is d1 or more and d3 or less, the contrast difference C is Th or more, and the contrast difference C takes the maximum value when the distance d is d2 (d1 < d2 < d3).

[0092] If the contrast difference C is, for example, greater than or equal to the threshold Th, it can be determined that the AF area has changed from within the depth of field (where the contrast of the AF area is relatively high) to outside the depth of field (where the contrast of the AF area is relatively low) (or from outside the depth of field to within the depth of field) (that is, the value of the threshold Th is set so that this determination is possible).

[0093] The proximity state determination device 34 determines, for example, that if the contrast difference C is greater than or equal to a threshold Th, the system has transitioned from a screening state, in which the focus lens 11a is fixed to the far end Pf and used to search for lesions, to a proximity state, in which the system is used to observe a specific lesion at close range.

[0094] In the above description, the contrast difference C was calculated by comparing the contrast value of the far-point image (Pf:t1) with the contrast value of the near-far-point image (Pqf:t2). Alternatively, the contrast difference C may be calculated by comparing the contrast value of the near-far-point image (Pqf:t2) with the contrast value of the far-point image (Pf:t3).

[0095] Alternatively, calculating the contrast difference C by comparing the average of the contrast values ​​of the far-point image (Pf:t1) and the far-point image (Pf:t3) with the contrast value of the near-far-point image (Pqf:t2) will result in a higher temporal correlation and improved accuracy of the determination.

[0096] Furthermore, while the change in contrast value was calculated as a contrast difference as described above, it is also acceptable to calculate it as a ratio of contrast values ​​(simply called the "contrast ratio"). The contrast ratio can be any of the following: the ratio of the contrast value of the far-point image (Pf:t1) to the contrast value of the near-far-point image (Pqf:t2); the ratio of the contrast value of the far-point image (Pf:t3) to the contrast value of the near-far-point image (Pqf:t2); or the ratio of the average of the contrast values ​​of the far-point image (Pf:t1) and the far-point image (Pf:t3) to the contrast value of the near-far-point image (Pqf:t2).

[0097] In addition, as described above, a preferred example was given in which the position P of the focus lens 11a is fixed at the far point Pf in the screening state in order to maximize the depth of field, but this is not the only example. For example, the focus lens controller 35 may, in the screening state, fix the position P of the focus lens 11a at a specific position (which does not have to be the far point Pf), and then slightly shift the position P of the focus lens 11a from that specific position. The proximity state determination device 34 may then determine that the state has transitioned from the screening state to the proximity state based on multiple images with different focus positions acquired at each position.

[0098] Furthermore, the image information used by the proximity state determination device 34 for determination may be phase difference information obtained from phase difference pixels instead of contrast.

[0099] The distance to the subject can be determined using phase difference information obtained from phase difference pixels. Phase difference increases when the subject is not in focus, and a larger phase difference improves the accuracy of the distance measurement.

[0100] When the focus lens 11a is moved back and forth to acquire images at different focus positions (for example, the far-point end image and the near-far-point end image), the depth end on the far-point side of the depth of field is shifted more significantly from focus in the near-far-point end image, resulting in a larger phase difference and improved distance measurement accuracy. For this reason, the proximity state determination device 34 may compare the distance calculated based on the phase difference information acquired from the phase difference pixels of the near-far-point end image with a threshold, and determine that the system has transitioned from a screening state to a proximity state when the distance changes from a state where it is greater than the threshold to a state where it is less than or equal to the threshold. Alternatively, as shown in the modified example described later, the determination of whether or not the system has transitioned to a proximity state may also be made by taking into account the determination result by the reliability determination device 38 (see Figure 7).

[0101] As a result, compared to when the focus lens 11a is not moved back and forth, it is possible to determine that the system has transitioned from the screening state to the close-up state at a stage slightly before the part of the image at the far end of the image goes out of the depth of field (i.e., slightly before it loses focus), and then transition from the close-up detection mode to the AF mode.

[0102] Furthermore, the difference or ratio of the phase difference between the images before and after the reciprocating motion of the focus lens 11a (for example, the far-point image and the near-far-point image) becomes larger at the depth end of the depth of field. For this reason, the proximity state determination device 34 may determine that the system has transitioned from the screening state to the proximity state when, for example, the difference or ratio between the phase difference of the far-point image and the phase difference of the near-far-point image changes from a state where it is smaller than a threshold to a state where it is greater than or equal to a threshold.

[0103] In this first embodiment, the focus lens 11a is moved slightly back and forth in the optical axis direction during the screening state, and based on the characteristic that the change in the image acquired at the depth edge of the depth of field is maximized, it is determined whether the positional relationship between the subject and the endoscope has shifted from the screening state to the close-up state. Then, autofocus is turned off when the subject is in depth during the screening state, and turned on when the positional relationship has shifted from the screening state to the close-up state, thereby preventing unnecessary autofocus during the screening state.

[0104] Furthermore, since the determination is made based on multiple images acquired by slightly reciprocating the focus lens 11a in the optical axis direction, a dedicated subject distance detection device is not required, thus preventing the endoscope from becoming larger. [Modified version of the first embodiment]

[0105] In the first embodiment, it was determined whether or not the device had transitioned to a close-up state based on image changes such as a change in contrast. However, in addition to the technology of the first embodiment, the image, the state of the endoscope, or the state of the subject may also be taken into consideration to determine whether the image change when the focus position is changed is a change obtained because the endoscope has transitioned to a close-up state, or a change due to other factors and whether the endoscope has not actually transitioned to a close-up state.

[0106] Specifically, as shown in Figure 7, the proximity state determination device 34 may include a reliability determination device 38. Figure 7 is a block diagram showing the structural and functional configuration of an endoscope system of a modified example of the first embodiment.

[0107] The confidence level 38 calculates confidence based on, for example, image information. This image information may include motion information, brightness information, contrast information, or color information.

[0108] By incorporating motion information into the reliability determination, it is possible to prevent misjudgments that occur when image blurring occurs due to rapid movement of the tip of the endoscope 10 and / or the subject, and the system mistakenly determines that the image state has transitioned to a close-up detection state. In this case, for example, if the amount of motion exceeds a predetermined value, the system is set not to switch to autofocus mode. The amount of motion is obtained by calculating the similarity between the images of the previous frame and the current frame, and determining where the image position in the previous frame has moved to in the current frame.

[0109] By incorporating brightness information into the reliability determination, it is possible to prevent misjudgments such as the system mistakenly determining that a proximity detection state has been reached due to increased brightness caused by reflections from bodily fluids, for example. In this case, for example, the system can be set not to switch to autofocus mode if the brightness exceeds a predetermined value.

[0110] By incorporating contrast information into the reliability determination, it is possible to prevent misjudgments such as the system mistakenly determining that the contrast value has changed and the system has entered a proximity detection state as a result of, for example, the tip of the endoscope 10 or a treatment instrument with a sharp edge appearing in the image. In this case, for example, if the contrast value at the location where the tip of the endoscope 10 or a treatment instrument is visible is above a predetermined value, the system is set not to switch to autofocus mode.

[0111] By incorporating color information into the reliability determination, it is possible to prevent misjudgments such as the appearance of treatment instruments, mist, bubbles, or liquid puddles in the image, or the tip of the endoscope 10 being submerged in liquid, which would result in a change in the contrast value and a shift to a proximity detection state. In this case, for example, if the color distance of the current frame's image to the color distribution of the treatment instrument, mist, bubbles, and liquid puddle in the color space is below a predetermined value, the system is set not to switch to autofocus mode.

[0112] The reliability grader 38 calculates reliability based, for example, on light emission information. Light emission information includes the intensity, duration, or wavelength of the illumination light. The duration of the illumination may include the charge readout period.

[0113] When observing at close range, the amount of illumination light illuminating the subject usually decreases. Therefore, if the proximity state determination unit 34 determines that a close-range state is occurring even though the light intensity is above a predetermined value, it may be considered a misjudgment and the system may not transition to autofocus mode. The reliability determination unit 38 obtains the amount of illumination light emitted by the light source 22 from the light source controller 21, for example, via the system controller 36.

[0114] If the endoscope system is designed to emit light during the charge readout period, image blur may occur, potentially leading to a false determination that the system has entered a proximity detection state. Therefore, if the system determines that the system is in a proximity state based on the image taken within a predetermined time from the start of charge readout (during the charge readout period), it may be possible to prevent the system from transitioning to autofocus mode, treating this as a false determination.

[0115] Since the subject is often red, images obtained when the wavelength of the illumination light during sequential illumination is red tend to have low contrast. Therefore, if the system determines that the image is in close proximity based on the wavelength of the illumination light during sequential illumination, it may be acceptable to prevent the system from switching to autofocus mode as this is considered a misjudgment.

[0116] The reliability judging unit 38 calculates the reliability based, for example, on the position information of the focus lens 11a. The position information of the focus lens 11a is the difference between the specified position of the focus lens 11a transmitted to the movement mechanism 13 by the proximity state judging unit 34 or the focus lens controller 35, and the actual position. The actual position of the focus lens 11a can be obtained from the movement mechanism 13 or the focus lens controller 35.

[0117] The confidence level assessor 38 may include AI, and may be capable of calculating the confidence level based on the image information described above using machine learning. [Second Embodiment]

[0118] Figures 8 to 10 show a second embodiment of the present invention, with Figure 8 being a block diagram showing the structural and functional configuration of the endoscope system of the second embodiment. In this second embodiment, parts that are the same as those in the first embodiment and the modified version thereof described above are denoted by the same reference numerals, and their descriptions are omitted as appropriate, with only the main differences being described.

[0119] The endoscope system of this embodiment employs EDOF (Extended Depth of Field) technology. In EDOF, the light beam from the objective optical system 11 is divided into multiple (for example, two) light beams by the splitting optical system 16, and multiple optical images are formed by making the optical path lengths of the multiple light beams different. The multiple optical images formed are simultaneously captured by the image sensor 12, and multiple images with different focus positions are acquired. By combining the in-focus parts of the multiple images, a composite image with an expanded depth of field is generated.

[0120] Specifically, the endoscope 10 of this embodiment further includes a segmented optical system 16. The segmented optical system 16 is arranged, for example, between the objective optical system 11 and the image sensor 12.

[0121] The segmented optical system 16 includes, for example, a semi-transparent mirror 16a and a reflective mirror 16b. The light beam emitted from the objective optical system 11 is partially transmitted by the semi-transparent mirror 16a and partially reflected by the other half. The light beam reflected by the semi-transparent mirror 16a is further reflected by the reflective mirror 16b toward the image sensor 12.

[0122] The light beam transmitted by the semi-transparent mirror 16a is imaged on a portion of the image sensor 12, and the light beam reflected by the reflective mirror 16b is imaged on another portion of the image sensor 12. With the above configuration, the optical image formed on a portion of the image sensor 12 and the optical image formed on another portion of the image sensor 12 have different optical path lengths.

[0123] The image sensor 12 simultaneously captures an optical image formed in one part and an optical image formed in another part, thereby acquiring multiple images. Each of the multiple images acquired here has a different focus position.

[0124] Note that the configuration of the split optical system 16 shown in Figure 8 is a simplified model, and the actual configuration of the split optical system 16 may differ from that shown in Figure 8. For example, the semi-transparent mirror 16a and the reflective mirror 16b may be configured as mirror surfaces of a prism. Also, the semi-transparent mirror 16a may be configured as a polarizing beam splitter surface, and may further include a depolarizing plate to eliminate polarization direction bias, a waveplate to convert between linearly polarized and circularly polarized light, etc. Furthermore, the light beam is not limited to being split into two, but may be split into three or more. Moreover, instead of the split light beams being imaged on different parts of the same image sensor 12, they may be imaged on different image sensors.

[0125] Furthermore, the image processing device 33 performs an image synthesis process on multiple images with different focus positions that are simultaneously acquired by the image sensor 12, combining the in-focus areas to generate a composite image with an expanded depth of field.

[0126] For the sake of simplicity, the following explanation will focus on the case where two images are acquired simultaneously.

[0127] The proximity state determination device 34 determines whether the system has transitioned from the screening state to the proximity state by using, for example, two images with different focus positions that are acquired simultaneously (for example, the first image and the second image). In this case, except that the two images are acquired simultaneously and the reciprocating motion of the focus lens 11a is unnecessary, the system can determine whether the system has transitioned from the screening state to the proximity state by performing the processing described in Embodiment 1 above based on the two images.

[0128] Furthermore, the proximity state determination device 34 may, similar to the first embodiment described above, move the focus lens 11a back and forth to acquire two more images, and determine whether or not the state has transitioned from screening to proximity based on a total of four images.

[0129] In this case, the proximity state determination device 34 uses a total of four images for determination: two images acquired before shifting the focus lens 11a (or after shifting it and then returning it to its original position) (for example, the 1a image and the 2a image), and two images acquired with the focus lens 11a shifted (for example, the 1b image and the 2b image).

[0130] Here, among the two images simultaneously acquired by the imaging device 12, "1" is assigned to the image (near-point image) obtained from the optical image with a long optical path length from the objective optical system 11 to the imaging device 12, and "2" is assigned to the image (far-point image) obtained from the optical image with a short optical path length. Also, "a" is assigned to the image acquired at the focus position of the far-point end Pf before shifting the focus lens 11a, and "b" is assigned to the image acquired at the focus position of the quasi-far-point end Pqf in the shifted state.

[0131] When the proximity state determination unit 34 uses, for example, the contrast information of a total of four images acquired two by two in time series for determination, the characteristic that the distance at which the contrast difference between the images acquired before and after shifting the focus lens 11a is equal between the near-point image and the far-point image is near the depth end of the depth of field and is in a proximity state is utilized.

[0132] Assume that the averages of the contrast values in the AF regions of the first a, 1b, 2a, and 2b images are represented by C1a, C1b, C2a, and C2b, respectively. At this time, the proximity state determination unit 34 calculates, for example, the contrast difference C1 = (C1b - C1a) between the first a image and the first b image, and the contrast difference C2 = (C2b - C2a) between the second a image and the second b image. As described in the first embodiment, it is also possible to calculate the absolute values when calculating the contrast differences C1 and C2.

[0133] FIG. 9 is a graph showing an example in which, in the endoscope system according to the second embodiment, a magnitude relationship occurs between the contrast difference C1 of the first image and the contrast difference C2 of the second image due to the reciprocating movement of the focus lens 11a.

[0134] In the example shown in FIG. 9, the contrast difference C1 takes a maximum value when the distance d to the subject is d4, the contrast difference C2 takes a maximum value when the distance d to the subject is d6 (d^4 < d6), and when the distance d to the subject is d5 (d4 < d5 < d6), the magnitude relationship between the contrast difference C1 and the contrast difference C2 is reversed.

[0135] The proximity state determination device 34 determines that when the distance d to the subject is d5, it is near the depth of field limit and has transitioned from the screening state to the proximity state.

[0136] In the determination method described in the first embodiment, it was necessary to set a threshold for the contrast difference and determine the relationship between the contrast difference and the threshold. In contrast, the determination method based on the relationship of contrast differences described here does not depend on the degree of contrast in the texture of the subject, etc., and therefore the determination accuracy can be increased.

[0137] Furthermore, this determination method allows for the detection of a transition to close-up mode before the subject moves out of focus, as shown in Figure 9. Therefore, the camera can switch from close-up mode to AF mode shortly before the subject being observed becomes out of focus.

[0138] Figure 10 is a graph showing an example in the endoscope system of the second embodiment in which the contrast difference C1 of the first image and the contrast difference C2 of the second image change due to the reciprocating motion of the focus lens 11a, and the difference between the contrast differences is used for determination.

[0139] In this case, the proximity state determination device 34 calculates the contrast difference C1 = (C1b - C1a) and the contrast difference C2 = (C2b - C2a), and then calculates the difference between the contrast differences ΔC = C1 - C2 (in the example in Figure 10, the difference ΔC when the distance d = d7 is shown). The proximity state determination device 34 sets a threshold for ΔC, and determines that the device has entered the proximity state when ΔC is greater than or equal to the threshold.

[0140] Here, we calculated the difference between contrast differences ΔC = C1 - C2, but instead, you can calculate the ratio of contrast differences C1 / C2 and compare it with an appropriate threshold.

[0141] Furthermore, in this embodiment as well, the image information used by the proximity state determination device 34 for determination may be phase difference information obtained from phase difference pixels instead of contrast.

[0142] As described above, if multiple images with different focus positions are acquired simultaneously by shifting the position of the focus lens 11a, and for example four images are acquired as described above, the reliability of the phase difference calculation result may be calculated based on the position of the focus lens 11a, the comparison result of the phase difference of two images acquired by moving the focus lens 11a, etc., and the proximity state determination device 34 may determine that the system has transitioned to a close-proximity state using only the highly reliable phase differences.

[0143] Furthermore, the proximity state determination device 34 may determine that the object has entered a proximity state based on the composite image with an expanded depth of field output from the image processing device 33. In this case, for example, the proximity state determination device 34 can make a determination using the method described in the first embodiment, based on the first composite image acquired at the far end Pf and the second composite image acquired at the near-far end Pqf.

[0144] According to this second embodiment, while achieving substantially the same effects as the first embodiment described above, in a configuration in which multiple images (for example, two images) with different focus positions can be simultaneously acquired by the divided optical system 16, a total of four images can be acquired by changing the position of the focus lens 11a, and the transition to a close-up state can be determined based on the relative magnitudes of the contrast differences, or the difference or ratio of the contrast differences, thereby achieving high determination accuracy without depending on the magnitude of the contrast of the subject itself. [Third Embodiment]

[0145] Figures 11 and 12 show a third embodiment of the present invention, with Figure 11 being a block diagram showing the structural and functional configuration of the endoscope system of the third embodiment. In this third embodiment, parts that are the same as those in the first and second embodiments (including modifications of the first embodiment) described above are denoted by the same reference numerals, and their descriptions are omitted as appropriate, with only the main differences being described.

[0146] The endoscope system of this embodiment further includes a screening state determination device 37 in addition to the endoscope processor 30.

[0147] The screening state determination device 37 determines whether the camera has transitioned from the close-up state to the screening state. If it determines that the camera has transitioned to the screening state, it outputs an AF termination signal to the focus lens controller 35.

[0148] As described above, when the focus lens controller 35 receives an AF termination signal while controlling in AF mode, it terminates AF mode and switches to proximity detection mode.

[0149] The screening status determination by the screening status determination device 37 is performed, for example, by the following method.

[0150] The screening state determination device 37 acquires information on the position P of the focus lens 11a being controlled in AF mode from, for example, the moving mechanism 13 or the focus lens controller 35 at appropriate time intervals. The screening state determination device 37 then determines that the system has transitioned to the screening state when the acquired position of the focus lens 11a reaches, for example, the far point Pf (however, it is not limited to the far point Pf, but may be any appropriate position near the far point Pf).

[0151] Furthermore, the endoscope 10 is basically configured to illuminate the subject with illumination light from the light source device 20 in a state where ambient light (such as sunlight or indoor light) cannot be expected, and to observe by receiving the reflected light from the subject. For this reason, the subject becomes darker as it moves away from the tip of the insertion section 10a of the endoscope 10, and brighter as it approaches the tip of the insertion section 10a. Therefore, the screening state determination device 37 may, for example, acquire the brightness value of the image from the image processing device 33, for example, on a frame-by-frame basis. Then, when the average brightness value in the acquired image, for example, within the AF area, becomes smaller than a predetermined threshold, it may be determined that the system has transitioned to the screening state.

[0152] Furthermore, the endoscope system performs dimming to control the light intensity of the light source 22 so that the subject is illuminated with appropriate brightness. The screening state determination device 37, for example, obtains the light intensity of the light source 22 from the light source controller 21, for example, via the system controller 36. The screening state determination device 37 may then determine that the distance to the subject has increased, i.e., that the system has transitioned to the screening state, when the light intensity of the light source 22 exceeds a predetermined threshold.

[0153] In addition, the screening status determination device 37 may employ the following determination method.

[0154] When the endoscope 10 is brought closer to the subject, the motion vector of the image points outward in the radial direction (because when the tip of the insertion part 10a is brought closer to the subject in the center of the image, the part of the subject that was near the center of the image moves towards the periphery of the image).

[0155] Conversely, when the endoscope 10 is moved away from the subject, the motion vector of the image points inward in the radial direction (because when the tip of the insertion part 10a is moved away from the subject in the center of the image, the part of the subject that was outside the field of view comes into the field of view).

[0156] The screening state determination unit 37 then acquires multiple temporally consecutive frames of images from the preprocessor unit 31, performs image recognition, and detects motion vectors. Furthermore, based on the detected motion vectors, the screening state determination unit 37 determines whether the tip of the insertion unit 10a is approaching or moving away from a specific part of the subject (whether the motion vector is outward or inward relative to the center of the image) and the speed of movement (magnitude of the motion vector). The screening state determination unit 37 then determines that the user is attempting to observe the subject from a greater distance, i.e., has transitioned to a screening state, if the state of moving away continues for a predetermined time or longer.

[0157] Figure 12 is a flowchart showing the operation of the endoscope system according to the third embodiment. Note that Figure 12 shows the processing content for one frame, and in the main processing (not shown), the processing shown in Figure 12 is performed each time an image for one frame is acquired.

[0158] When the system moves from the main process (not shown) to the process shown in Figure 12, the system controller 36 determines whether or not it is the first frame image (initial frame) acquired since the endoscope system was started (step S1).

[0159] If it is determined that this is the initial frame, the system controller 36 sets the focus lens controller 35 to proximity detection mode (step S2).

[0160] If the process in step S2 is performed, or if it is determined in step S1 that it is not the initial frame, the system controller 36 determines whether the current control mode is proximity detection mode or AF mode (step S3).

[0161] If it is determined that the proximity detection mode is active (i.e., the previous frame was in the screening state), the proximity state determination device 34 determines whether or not the device is in the proximity state (i.e., whether or not it transitioned from the screening state of the previous frame to the proximity state in the current frame) (step S4).

[0162] If it is determined that the camera has entered a close-up state, the close-up state determination device 34 outputs an AF start signal to the focus lens controller 35 (step S5).

[0163] When the focus lens controller 35 receives an AF start signal, it sets the control mode to AF mode and controls the focus lens 11a via the movement mechanism 13 to perform autofocus so that the subject within the AF area remains in focus (step S6).

[0164] Furthermore, in step S3, if it is determined that the current control mode is AF mode (i.e., the previous frame was in the proximity state), the screening state determination device 37 determines whether or not the system is in the screening state (i.e., whether or not it transitioned from the proximity state of the previous frame to the screening state in the current frame) (step S7).

[0165] If it is determined that the system has entered the screening state, the screening state determination unit 37 outputs an AF termination signal to the focus lens controller 35 (step S8).

[0166] When the focus lens controller 35 receives the AF termination signal, it sets the control mode to proximity detection mode and controls the focus lens 11a via the movement mechanism 13, fixing the position of the focus lens 11a basically to the far end Pf as described above, and performing a reciprocating motion with a small amplitude A periodically or aperiodically (step S9).

[0167] If it is determined in step S4 that the proximity state is not met, if the process in step S6 is performed, if it is determined in step S7 that the screening state is not met, or if the process in step S9 is performed, the process shown in Figure 12 returns to the main process (not shown).

[0168] It should be noted that a configuration in which a screening state determination device 37 is provided separately from the proximity state determination device 34, as shown in Figure 11, may also be applied to the configuration of the second embodiment.

[0169] This third embodiment achieves substantially the same effects as the first and second embodiments described above, and by providing a screening state determination device 37 separate from the proximity state determination device 34 to determine whether or not the device has transitioned to the screening state, various determination methods can be applied, enabling highly accurate determination.

[0170] Although the above description primarily focuses on the case where the present invention is an endoscope processor, it is not limited to this. The present invention may also be a method for controlling a focus lens that performs similar processing to an endoscope processor, or a program for causing a computer to control an endoscope, a non-temporary storage medium readable by the computer that stores the program, and so on.

[0171] Furthermore, the present invention is not limited to the embodiments described above, and the components can be modified and implemented in practice without departing from the spirit of the invention. Also, various forms of the invention can be formed by appropriately combining the multiple components disclosed in the above embodiments. For example, some components may be removed from all the components shown in the embodiments. Furthermore, components from different embodiments may be combined as appropriate. Thus, it goes without saying that various modifications and applications are possible without departing from the spirit of the invention. [Explanation of Symbols]

[0172] 10… Endoscopy 10a... Insertion part 11…Objective optical system 11a... Focus lens 12…Image sensor 13...Movement mechanism 14…Illumination lens 15…Light Guide 16...Divided optical system 16a... Semi-transparent mirror 16b... Reflective mirror 20…Light source device 21…Light source controller 22…Light source 30… Endoscope Processor 30a…Processor 30b...Memory 31…Pretreatment device 32…AD converter 33…Image processing device 34… Proximity detection device 35…Focus lens controller 36... System Controller 37…Screening status determination device 38…Confidence level tester 40…External Interface (External I / F) 50…Monitor EIA…Effective Image Area Pf…Far point end Pqf…quasi-far point end f…focal length h...image height θ...half of the field of view

Claims

1. An objective optical system that includes a focusing lens and forms an optical image of the subject, A moving mechanism for moving the focus lens, An imaging device that captures the aforementioned optical image and acquires an image, Connectable to an endoscope equipped with a processor, Equipped with, The aforementioned processor, The movement mechanism is controlled by either an autofocus mode that automatically focuses on the subject, or a proximity detection mode that determines whether or not the state has transitioned from screening to close-up. While the autofocus mode is off, the proximity detection mode is executed. During the proximity detection mode, When the fluctuation in the image height of the effective image range due to the control of the movement mechanism is 1% or less, it is determined whether or not the state has transitioned from the screening state to the close-up state based on the position information of the focus lens and the change in the image. If it is determined that the device has entered the proximity state, the proximity determination mode is terminated and the movement mechanism is controlled in the autofocus mode. An endoscope processor characterized by the following features.

2. The processor, while controlling the movement mechanism in autofocus mode, further determines whether it has transitioned from the proximity state to the screening state, and if it determines that it has transitioned to the screening state, it terminates the autofocus mode and controls the movement mechanism in proximity determination mode. The endoscope processor according to feature 1.

3. The processor moves the focus lens so that the variation in image height of the effective image range is 1% or less, and when determining whether it has transitioned from the screening state to the close-up state, it moves the focus lens at least in the close-up direction. The endoscope processor according to feature 1.

4. The starting point when moving the focusing lens toward the approach direction is the far end. The endoscope processor according to claim 3.

5. The processor moves the focus lens back and forth so that the fluctuation in the image height of the effective image range due to the control of the movement mechanism is 1% or less. The endoscope processor according to feature 1.

6. The processor determines whether or not the transition to the proximity state has occurred based on the difference or ratio between the contrast value of the image acquired by the imaging device at the far point and the contrast value of the image acquired by the imaging device at a position different from the far point. The endoscope processor according to feature 1.

7. The imaging device is equipped with an image-plane phase-difference AF type image sensor, The processor determines whether or not the transition to the proximity state has occurred based on the difference or ratio between the phase difference acquired by the image sensor at the far point and the phase difference acquired by the image sensor at a position different from the far point edge. The endoscope processor according to feature 1.

8. The endoscope further comprises a splitting optical system that divides the light beam from the objective optical system into a plurality of light beams with different optical path lengths. The imaging device captures multiple optical images from the multiple light beams divided by the divided optical system, thereby simultaneously acquiring multiple images with different focus positions. The endoscope processor according to feature 1.

9. The processor sets a determination area for determining whether or not the proximity state has been reached in the image acquired by the imaging device. The endoscope processor according to feature 1.

10. The aforementioned processor, The reliability when the aforementioned focus lens is moved is calculated, When the focusing lens is moved, in addition to the change in the image and the position information of the focusing lens, it is determined whether or not the state has transitioned from the screening state to the close-up state based on the reliability. The endoscope processor according to feature 1.

11. The processor calculates the reliability from at least one of the following: motion amount, brightness, presence or absence of reflection of the endoscope tip, presence or absence of reflection of the treatment instrument, light intensity, emission period, charge readout period, and wavelength of illumination light. The endoscope processor according to feature 10.

12. The computer that controls the endoscope, Either an autofocus mode that automatically focuses on the subject, or a proximity detection mode that determines whether or not the state has changed from screening to close-up, controls the movement mechanism that moves the focus lens included in the objective optical system of the endoscope. While the autofocus mode is off, the proximity detection mode is executed. During the proximity detection mode, When the variation in image height within the effective image range is 1% or less, the system determines whether or not it has transitioned from the screening state to the close-up state based on the position information of the focus lens and the changes in the image acquired by the imaging device of the endoscope. If it is determined that the state has transitioned to the aforementioned proximity state, the proximity determination mode is terminated and the movement mechanism is controlled in the autofocus mode. A program characterized by the following features.

13. An endoscope processor that can be connected to an endoscope, Images are acquired from the aforementioned endoscope, The position information of the focus lens of the endoscope is acquired, While controlling the movement mechanism of the focus lens of the endoscope in proximity detection mode, if the fluctuation in the image height of the effective image range is 1% or less, it is determined whether or not the state has transitioned from screening to proximity based on the position information of the focus lens and the change in the image. If it is determined that the state has transitioned to the aforementioned proximity state, the proximity determination mode is terminated and the movement mechanism is controlled in autofocus mode. A method for operating an endoscope processor, characterized by the features described above.

14. The image processing device acquires an image from the endoscope, The focus lens controller acquires the position information of the focus lens of the endoscope, While the focus lens controller is controlling the movement mechanism of the focus lens of the endoscope in proximity determination mode, the proximity state determination device determines whether the state has transitioned from screening to proximity state based on the position information of the focus lens and the change in the image, when the variation in the image height of the effective image range is 1% or less. If the proximity state determination device determines that the proximity state has been reached, the focus lens controller terminates the proximity determination mode and controls the movement mechanism in autofocus mode. A method for controlling a focus lens, characterized by the present invention.

Citation Information

Patent Citations

  • Endoscope focusing control method and system

    CN114859544A

  • Laser diode and manufacture thereof

    JP1986077387A

  • Image processing apparatus, endoscope system, image processing method, and program

    JP2013076823A

  • Focus control device of endoscope device, endoscope device, and focus control method of endoscope device

    JP2016195772A

  • An imaging device, method and program for producing images of a scene

    US20200345215A1