The present invention relates to a medicine loading device for loading a medicine based on prescription information, and a medicine recovery method.
There is generally known medicine dispensing devices which automatically dispense a prescribed medicine based on a prescription. For example, the applicant of the present application has developed a medicine dispensing device described in patent document 1, and this medicine dispensing device has gained a good reputation and has obtained high evaluation that efficiencies of prescription operations have been increased from prescription operators.
In a conventional medicine dispensing device, various medicines to be dispensed are stored in a plurality of cassettes. When the medicines have been dispensed and the medicines in the cassette has been lack of short, the prescription operator needs to remove the cassette from the device, discriminates medicines and refills them into the medicine cassette with his/her own hands.
On the other hand, although it is preferable that an amount of the prescribed medicines and a dosage of the prescribed medicines should match a required amount depending on a treatment content for a patient, in general, it is often found that there are unused medicines and time-expired medicines due to forgetfulness of taking medicines of the patient or a change in a medical treatment content. Since annual unused medicines and time-expired medicines are generally in enormous quantities, if these unused or time-expired medicines are wasted as they are, it would be significant wasteful and thus it is required to appropriately recover these medicines.
However, if a package or identification information for the unused medicines or time-expired medicines breaks, there is often a case that the medicines are brought in an unpacked state, for example. In this case, the prescription operator is forced to discriminate the type of the medicines by his/her own eyes from only appearance of the medicines, and at this time, a mistake that an improper medicine is refilled into the cassette may occur.
One of objects of the present invention is to prevent the improper medicine from being refilled into the medicine dispensing cassette.
Patent document 1: WO 2010/110360
The present invention provides a medicine loading device which can prevent an improper medicine from being loaded based on prescription information.
A first aspect of the present invention relates to a medicine loading device for loading a medicine based on prescription information. This medicine loading device has a main body, a medicine dispensing cassette and medicine discriminating means. The at least one medicine dispensing cassette is provided in the main body. An openable/closable lid is provided at the medicine dispensing cassette. Further, a locking mechanism for locking the lid is provided at the medicine dispensing cassette. When a type of a medicine detected by the medicine discriminating means and a type of a medicine to be contained in the medicine dispensing cassette match each other, the locking mechanism is released.
It is preferable that the medicine discriminating means further has a medicine information obtaining part for reading cassette information provided at either one of the medicine dispensing cassette and the lid and medicine information provided on the medicine and an information processing part connected to the medicine information obtaining part. The information processing part preferably discriminates the type of the medicine based on information on the medicine obtained by the medicine information obtaining part.
It is preferable that the medicine information obtaining part has a photographing device for obtaining an image in which the information on the medicine which is a discrimination target is indicated and at least one of a first reading device which can read a code in which the information on the medicine which is the discrimination target is indicated and a second reading device which can read a signal indicating the medicine information of the discrimination target.
It is preferable that he image in which the medicine which is the discrimination target is indicated is an image of an engraved mark or a print image of the medicine, and the code in which the medicine which is the discrimination target is indicated is any one of a bar code, a two-dimensional code and a three-dimensional code indicating the medicine information on the medicine.
It is preferable that the locking mechanism further has a trigger for allowing a lock to be released. This trigger can further return the locking mechanism to a locked state after releasing the locking mechanism. The trigger more preferably allows the cassette to be removed from the medicine loading device and the trigger is returned from a releasing state of the lock to an original state. Further, it is more preferable that the trigger has a receiving part for receiving an instruction for allowing the trigger to return from the releasing state of the lock to the original state from an outside after the cassette has completed a loading operation, Further, it is preferable that the trigger further has a timer part and the trigger is returned from the releasing state of the lock to the original state when a predetermined time elapses after the locking mechanism has been released by this timer part.
It is preferable that the medicine loading device further has a storage part which can store predetermined medicine information in advance and further store the information on the medicine detected by the medicine discriminating means, and this storage part stores an image of the medicine, a numerical value or a rank indicating a degree of possibility of correctness and the engraved mark or a print code of the medicine.
It is preferable that the medicine loading device further has a control part which creates template image data based on the stored information on the medicine and performs pattern matching for calculating a score serving as an index of a degree of matching between image data of the engraved mark and/or a print of the medicine and the template image data to discriminate the medicine.
It is preferable that the medicine loading device further has a display and this display displays a result of comparing the information on the medicine detected by the medicine discriminating means with the information on the medicine stored in the storage part.
It is preferable that the medicine loading device further has an alert part for alerting an operator when the type of the medicine detected by the medicine discriminating means and the type of the medicine to be contained in the medicine dispensing cassette do not match each other.
A second aspect of the present invention relates to a medicine recovery method for recovering a medicine based on prescription information. This medicine recover method has a step of obtaining medicine information indicating a type of a medicine which is a discrimination target, a step of comparing the medicine information with cassette information indicating a type of a medicine to be contained in a medicine dispensing cassette, a step of determining whether the medicine information and the cassette information match each other, and a step of releasing a locking mechanism provided at the medicine dispensing cassette when the medicine information and the cassette information match each other.
A third aspect of the present invention relates to a medicine loading support device for preventing an improper medicine from being loaded into medicine holding means. This medicine loading device has a main body, at least one medicine holding means contained in the main body, an opening and closing part attached to the medicine holding means, a locking mechanism for locking the opening and closing part, and discriminating means for discriminating a type of a medicine. When the type of the medicine discriminated by the discriminating means and a type of a medicine to be contained in the medicine holding means match each other, the locking mechanism is released.
According to the present invention, it is possible to prevent the improper medicine from being refilled into the medicine dispensing cassette.
§ 1 Summary of medicine loading device
Details of this medicine dispensing device 100 have been disclosed in WO 2010/110360. Further, details of a mechanism for enabling a cassette attached to the cassette arranged portion 150 to dispense the medicine have been disclosed in WO 2013/035692. Thus, in the following description, an overview of the medicine dispensing device 100 will be briefly described.
As shown in
The touch panel display 160 has both a function as a display device and a function as an input device. In addition, it can display a result of comparing information on the medicine detected by the medicine discriminating means with information on the medicine stored in a storage part. The scanner 170 can read a scanner reading symbol such as an image, a bar code, a two-dimensional code and an RF signal in which the information on the medicine is indicated. The control device 190 controls operations of various devices included in the medicine dispensing device 100 based on input information from the touch panel display 160, the scanner 170 and the like.
When the medicine dispensing device 100 dispenses the medicine, the scanner 170 first scans the symbol attached to a prescription to obtain prescription information. When the medicine dispensing device 100 receives an input of the prescription information and receives an input of a medicine dispensing instruction from a prescription operator, the vial bottle feeding device 110 first feeds a vial bottle to the label attachment device 120. Next, the label attachment device 120 prints a label based on the input prescription information and attaches this label to the vial bottle. Thereafter, the vial bottle carrying device 130 carries the vial bottle to which the label is attached into the vicinity of the medicine dispensing cassette 200 in which the prescribed medicines are stored. Then, the medicine dispensing cassette 200 dispenses the prescribed medicines into the vial bottle by a prescribed number. When the prescribed medicines are loaded in the vial bottle, the vial bottle carrying device 130 carries the vial bottle to the discharge port 140. Then, the prescription operator such as a pharmacist or a technician takes out the vial bottle discharged from the discharge port 140.
While the medicine dispensing device 100 is dispensing medicines, one of the medicine dispensing cassettes 200 is emptied in due course of time. In that case, the prescription operator needs to refill new medicines into this medicine dispensing cassette 200. However, in the medicine dispensing cassette 200, a lid 310 of the cassette is locked so that the lid 310 cannot be opened in a normal state. Therefore, at the time of refilling the medicines, the prescription operator needs to perform a predetermined operation for releasing the lock of the lid 310.
First, the prescription operator places the medicine dispensing cassette 200 to be refilled onto the medicine refilling portion 180. As shown in
At the time of refilling the medicine, the prescription operator makes the scanner 170 read the medicine to identify the type of the medicine to be refilled, which has been recovered from a warehouse or a patient. With this configuration, the medicine dispensing device 100 can identify the medicine to be refilled. The medicine dispensing device 100 has an unlocking device 182 for releasing the lock of the lid 310 of the medicine dispensing cassette 200 at the medicine refilling portion 180. Only when the medicine whose type has been identified is proper as the medicine to be refilled into the medicine dispensing cassette 200, the medicine dispensing device 100 drives the unlocking device 182 to release the lock of the lid 310 of the medicine dispensing cassette 200. With this configuration, the prescription operator can open the lid 310 and refill the new medicine into the medicine dispensing cassette 200. The medicine dispensing cassette 200 of the present embodiment has one feature regarding a locking mechanism for locking the lid 310. Hereinafter, the medicine dispensing cassette 200 including this locking mechanism will be described in detail.
§ 2 Summary of the medicine dispensing cassette 200
As shown in
The medicine dispensing cassette 200 has a locking mechanism 800 for locking the lid 310 therein.
§ 2.1 Structure of the lid 310
§ 2.2 Structure of the locking mechanism 800
The locking mechanism 800 further has a trigger for allowing the lock to be released and can use this trigger to release the locking mechanism 800 and then again return it to a locked state. Specifically, it can allow the cassette to be removed from the medicine loading device and return the trigger from a releasing state of the lock to an original state and further it can return to the locked state by receiving an instruction for returning the trigger from the releasing state of the lock to the original state from the outside after the cassette has completed the loading operation. Further, it is to return the trigger from the releasing state of the lock to the original state when a predetermined time elapses after the locking mechanism has been released,
As shown in
As shown in
An inclined surface of the inclined portion 810 is configured to contact with a protruding bar portion and is located vertically above the hole 212 as shown in
As described above, the unlocking device 182 of the medicine dispensing device 100 can push the inclined portion 810 through the hole 212 (see
As described above, the shaft 820 is biased in the front direction by the biasing member 830. More specifically, in a state that the shaft 820 is moving relative to the rear direction, a curved angle of the curved portion 832 is reduced. In the curved portion 832 in this state, elastic force occurs so as to increase the curved angle. Therefore, when the unlocking device 182 is spaced apart from the inclined portion 810, the locking mechanism 800 returns to the state as shown in
§2.3 Advantage of the medicine dispensing cassette 200 In the medicine dispensing cassette 200, whereas the medicine dispensing device 100 can release the lock of the lid 310, the user cannot easily release the lock. Accordingly, when the medicine dispensing cassette 200 is used in the medicine dispensing device 100, it is prevented that the improper medicine is refilled at the time of refilling the medicine into the emptied medicine dispensing cassette 200. This is because the medicine dispensing device 100 scans the bar code attached to the label of the bottle containing the medicine to be refilled and releases the lock of the lid 310 only when the medicine in the bottle is proper as the medicine to be refilled. With this configuration, the specification of the medicine dispensing device 100 of the above embodiment can be a closed loop specification.
The closed loop is a specification for improving the management for the medicines by using an identification device to identify the medicines more accurately and attaching labels or the like to the containers containing the medicines in order to promote the safe use of the medicines and prevent misconception of different medicines. In particular, in the case of recovering the medicines, the recovered medicines can be safely reused by a closed loop recovery for the medicines. Usually, sources of the medicines to be recovered are mainly three sources containing return from the pharmacy, unused medicines in a hospital and return from outpatient visitors. Since distribution routes of the medicines and the states of the medicines recovered from each source generally differ from each other greatly, for example, the unused medicines in the hospital are often recovered in an almost unopened state, while the returned medicines from the outpatient visitors may be opened and damaged. As described above, when there are the plurality of recover routes, it is generally difficult to recover the medicines. In the closed loop specification of the present invention, since recovery processes can be appropriately performed with respect to the medicine dispensing device 100 on the basis of the discrimination information after the discrimination for the medicine has been performed, it is possible to prevent an error of the prescription operator and reduce labor of the prescription operator.
§ 3 Medicine recovery method A medicine recovery method by the above-described medicine loading device based on the prescription information is shown. Specifically, in the method of the present invention, it has a step of obtaining medicine information indicating a type of a medicine which is a discrimination target, a step of comparing medicine information with cassette information indicating a type of a medicine to be contained in a medicine dispensing cassette, a step of determining whether the medicine information and the cassette information match each other and a step of releasing a locking mechanism provided at the medicine dispensing cassette when the medicine information and the cassette information match each other.
Medicine discriminating means further has a medicine information obtaining part and an information processing part connected to the medicine information obtaining part. The medicine discriminating means reads the cassette information provided at either one of the medicine dispensing cassette and the lid and the medicine information provided on the medicine to discriminate the type of the medicine based on this obtained information on the medicine. Further, the medicine information obtaining part includes at least one of a photographing device for obtaining an image in which information on the medicine which is a discrimination target is indicated, a first reading device for reading a code in which information on the medicine which is the discrimination target is indicated and a second reading device for reading a signal indicating the medicine information on the discrimination target. Hereinafter, as an example of the medicine information obtaining part of the medicine photographing device, description will be given to how to discriminate each medicine in the photographed image in detail.
§ 3.1 Medicine photographing device
§ 3.1.1 Outer configuration of the medicine photographing device As shown in
The lower case 911 covers the lower portion 902 of the medicine photographing device 900. The cutout portion 912 extending in the horizontal direction is formed on an upper surface of the lower case 911. This cutout portion 912 is opened in the left-right direction and the front direction of the medicine photographing device 900. The user can insert long packaging paper into the medicine photographing device 900 through this cutout portion 912. Specifically, the packaging paper is spread in the horizontal direction and inserted into the cutout portion 912 from the front side. Then, the packaging paper is moved into the vicinity of the central portion of the medicine photographing device 900. As a result, a built-in camera of the medicine photographing device 900 can photograph the medicine enclosed in the packaging paper without cutting the packaging paper. Since an internal space of the medicine photographing device 900 communicates with the external space in the left-right direction through the cutout portion 912, even if the packaging paper is longer than a width of the medicine photographing device 900, the user can easily insert the packaging paper into the medicine photographing device 900 in a state that the packaging paper is rewound.
The tray support member 921 for supporting a member for containing the medicines is provided immediately above the cutout portion 912. Specifically, the tray 400 is placed onto the tray support member 921. This tray support member 921 is a substantially square plate-like member in which the circular hole 922 is opened at its central portion as shown in
As shown in
As shown in
A lower end of the inclined portion 915 is located on the rear side than outer front surfaces of the guide members 930 and the lower case 911. Namely, a distance from the rear surface of the medicine photographing device 900 to the lower end of the inclined portion 915 is smaller than a distance from the rear surface of the medicine photographing device 900 to the outer front surfaces of the guide members 930 and the outer front surface of the lower case 911. With this configuration, the user can more easily insert the tray 400 into the upper internal space 940,
Furthermore, a slope 916 other than the inclined portion 915 is provided on the front side outer surface of the upper case 913. More specifically, the slope 916 is provided in a U shape of the substantially inverted U-shaped inclined portion 915. This slope 916 is provided in front of a first camera 710 (see
As shown in
§ 3.1.2 internal configuration of the medicine photographing device
As shown in
As shown in
The tray support member 921 is provided in the vicinity of the central portion of the medicine photographing device 900. Further, the guide members 930 are provided immediately above the tray support member 921. The third light source 750 is provided on the upper side of the guide members 930. Furthermore, the first camera 710 is provided at a position higher than the third light source 750, that is, in the vicinity of the upper surface of the medicine photographing device 900. The second light source 740 is provided on the lower side of the tray support member 921 with being apart from the tray support member 921 by a predetermined distance. The fourth light source 760 is provided at a position lower than the second light source 740 and in the vicinity of the side surface of the medicine photographing device 900. The second camera 720 is provided at a position lower than the fourth light source 760, that is, in the vicinity of the bottom surface of the medicine photographing device 900. As described above, in the medicine photographing device 900, an upper light source is constituted of the first light source 730 and the third light source 750. Further, in the medicine photographing device 900, a lower light source is constituted of the second light source 740 and the fourth light source 760.
As described above, the tray support member 921 is provided in the vicinity of the central portion of the medicine photographing device 900 and on the upper side of a space 917 for the cutout portion 912. As shown in
As shown in
As shown in
As shown in
Each of the first bar light 751 and the second bar light 752 includes a polarization filter and the light diffuses through this polarization filter and reaches the medicine. Specifically, it is configured so that direct light from the first bar light 751 and the second bar light 752 is cut by the polarization filters and the light diffused by the polarization filters reaches the medicine through the hole 922 of the tray support member 921, that is, the inside of the ring of the first ring light 731. Namely, the third light source 750 serves as a diffused light source or an indirect light source. Thus, the upper portion of the medicine is suitably illuminated. The present inventor has found that it is possible to clearly photograph the print attached to the surface of the medicine by configuring the third light source 750 as described above. Furthermore, regardless of whether the medicine is a tablet or a capsule, it is possible to clearly photograph the print.
As shown in
In this regard, although each of the third light source 750 and the fourth light source 760 is constituted of the two bar lights in the present embodiment, four bar lights may be provided in other embodiments. In this case, it is preferable to arrange the bar lights so that the four bar lights form a square shape and surround the placing portion 920.
The first camera 710 is provided on the upper side of the first bar light 751 and the second bar light 752. This first camera 710 is attached to the second column 952 through an attachment member 1011. Then, the first camera 710 is fixed by this attachment member 1011 so as to be located vertically above the placing portion 920 and face the placing portion 920. When the medicine photographing device 900 is viewed in the planar view from the upper side, a photographing area of the first camera 710 contains the hole 922 of the tray support member 921 and the inside of the ring of the first ring light 731. Thus, the first camera 710 can suitably take an image of the upper surface of the medicine placed on the placing portion 920, that is, an image of the medicine viewed from directly above.
The second camera 720 is provided on the lower side of the third bar light 761 and the fourth bar light 762, This second camera 720 is attached to the second column 952 through an attachment member 1021. Then, the second camera 720 is fixed by this attachment member 1021 so as to be located vertically below the placing portion 920 and face the placing portion 920. When the medicine photographing device 900 is viewed in the planar view from the lower side, a photographing area of the second camera 720 contains the inside of the ring of the second ring light 741. Thus, the second camera 720 can suitably take an image of the lower surface of the medicine placed on the placing portion 920, that is, an image of the medicine viewed from directly below. Both of the first camera 710 and the second camera 720 described above can take a color image.
§ 3.1.3 Configuration of placing item The tray 400 as shown in
Further, a capsule placing member 414 which is preferably made of a black opaque material is provided on the bottom surface 411 of the petri dish 410. An approximately half of the bottom surface 411 of the petri dish 410 is occupied by the capsule placing member 414 and the transparent material constituting the bottom surface 411 is exposed in the other half thereof. A portion of the bottom surface 411 where this transparent material is exposed is referred to as a transparent portion 415. It is recommended that the tablet should be placed on this transparent portion 415. On the other hand, it is recommended that capsule types such as capsules and soft capsules should be placed on the capsule placing member 414 in principle. The capsule placing member 414 has a planar shape close to a trapezoidal shape. Specifically, the capsule placing member 414 has a long side and a short side in a lengthwise direction thereof and has two hypotenuse sides having substantially the same length in the transverse direction. A distance between hypotenuse sides thereof decreases from the long side toward the short side. By setting the planar shape of the capsule placing member 414 to such a shape, it becomes possible to place more the capsules per part area. When the capsule placing member 414 is viewed from the lateral side, the capsule placing member 414 has a portion having a wavy shape on its upper surface. In other words, the capsule placing member 414 has groove-shaped concave portions 416 and 417 on its upper surface. A width and a depth of the concave portion 416 are set to be larger than a width and a depth of the concave portion 417. Further, a length of the concave portion 416 is larger than a length of the concave portion 417. Thus, a relatively large capsule can be easily placed in the concave portion 416 and a relatively small capsule can be easily placed in the concave portion 417. The capsule is placed in the concave portions 416 or 417 so that the printed characters of the capsule are directed toward the upper side. Since the concave portions 416 or 417 prevents the capsule from rolling, the first camera 710 can accurately photograph the print characters of the capsule.
As described above, the tray 400 is placed onto the tray support member 921 (see
§ 3.2 Medicine discrimination
<Step 110> Medicine supplying The user first places the medicines to be discriminated in the petri dish of the tray of the medicine discriminating means. For example, it is recommended that the tablet should be placed directly on the transparent portion of the bottom surface of the petri dish and the capsule should be placed on the capsule placing member. Next, the user places this tray onto the placing portion of the medicine photographing device.
<Step 120> Medicine image obtaining When the computer receives an input to start to photograph the medicines from the user, the computer drives the medicine photographing device to take the image of the petri dish. Specifically, the computer obtains four images of the following “image 1” to “image 4”. At this time, the computer sets photographing conditions of the camera based on setting values (e.g., a focus of the camera, an exposure time and each gain of RGB) obtained at steps of “focus adjustment of the camera” and “brightness and color calibration” described later. This improves the reproducibility of the image quality. [Image 1] The image 1 is an image obtained by photographing the petri dish from the upper side under the illumination by the first light source. This image can be obtained by turning on the first ring light and performing photographing with the first camera, [Image 2] The image 2 is an image obtained by photographing the petri dish from the lower side under the illumination by the second light source. This image can be obtained by turning on the second ring light and performing photographing with the second camera, [Image 3] The image 3 is an image obtained by photographing the petri dish from the upper side under the illumination by the third light source. This image can be obtained by turning on the first bar light and the second bar light and performing photographing with the first camera. [Image 4] The image 4 is an image obtained by photographing the petri dish from the lower side under the illumination by the fourth light source. This image can be obtained by turning on the third bar light and the fourth bar light and performing photographing with the second camera.
<Step 130> Image correction As described later, in the medicine discriminating means, calibration is performed in advance and the computer holds calibration information obtained by this calibration as data. The computer corrects the photographed images based on this calibration information. Specifically, correction of coordinates of the photographed images is performed based on the calibration information. Thus, coordinate axes of the images photographed by the first camera coincide with coordinate axes of the images photographed by the second camera.
<Step 140> Medicine area extraction After the image correction, an area occupied by each medicine is extracted in the images. For this purpose, the “image 1” and the “image 2” are suitably used, each of which has a tendency that the brightness greatly changes between the background and the medicine. This area extraction is performed by binarizing the brightness of each pixel with a threshold value (below the threshold value=background, over the threshold value=medicine) and separating areas over the threshold value.
<Step 210> Association of the medicines in the upper and lower images The medicine directly placed on the transparent portion of the petri dish appears in both of the images captured from the upper side (the “image 1” and the “image 3”) and the images captured from the lower side (the “image 2” and the “image 4”). Due to this step, the area occupied by the one medicine in the image captured from the upper side and the area occupied by this medicine in the image captured from the bottom side are associated with each other. Specifically, when one image of the “image 1” and the “image 2” corrected at step 130 is reversed horizontally or vertically, the area occupied by the medicine in one of the images substantially matches the area occupied by the same medicine in the other one of the images. This matched area is an area occupied by the one medicine in each of the two images. Namely, one area in the non-inverted image and an area obtained by returning the area in the inverted image overlapping with it due to the inversion release are areas respectively corresponding to the one medicine. At this time, an overlapping area in which the two images are overlapped with each other when the two images are inverted may be used as a corresponding area.
<Step 220> Tablet/capsule determination After the association process for the medicine area has been performed, the computer determines whether the medicine is a tablet or a capsule. Since the tablet is placed onto the transparent portion of the petri dish, the upper surface of the tablet appears in the image captured from the upper side and the lower surface of the tablet appears in the image captured from the lower side. Namely, when the two images (the “image 1” and the “image 2”) are compared, if the medicine is a tablet, an area corresponding to the medicine exists in each of the image captured from the upper side and the image captured from the lower side. Therefore, in the case where the association for one area with respect to the two images can be performed at step 210, namely, in the case where the occupied area of the medicine recognized in the image captured from the upper side is associated with the occupied area of the medicine recognized in the image captured from the lower side, the medicine is determined as the tablet.
On the other hand, the capsule is placed on the opaque capsule placing member. Thus, although the upper surface of the capsule appears in the image captured from the upper side, the capsule does not appear in the image captured from the lower side. Namely, when the two images (the “image 1” and the “image 2”) are compared, if the medicine is the capsule, whereas an area occupied by the medicine exists in the image captured from the upper side, an area occupied by the medicine does not exist in the image captured from the lower side. Therefore, in the case where the association for one area with respect to the two images at step 210 cannot be performed, namely, in the case where the area corresponding to the occupied area of the medicine recognized in the image captured from upper side is not recognized in the image captured from the lower side, the medicine is determined as the capsule.
<Step 300> Tablet discrimination If one medicine selected by the computer is determined as the tablet, the process proceeds to a tablet discrimination process 300.
<Step 310> Circle determination The computer calculates a circularity of the area occupied by the medicine. If the circularity is equal to or more than a predetermined value, the computer determines that the medicine is circular. When the circularity is less than the predetermined value, the computer determines that the medicine is non-circular. If the medicine is determined to be circular, the computer calculates a center position and a radius of the circle. If the medicine is determined to be non-circular, the computer rotates the area occupied by the medicine so that a long axis of the area occupied by the medicine is parallel to the X axis and a short axis of the area is parallel to the Y axis. In addition, the computer calculates lengths of the long axis and the short axis of the medicine and a ratio of the lengths of the long axis and the short axis of the medicine.
<Step 320> Engraved mark extraction The computer performs an engraved mark extraction process on the “image 1” and the “image 2”, that is, the images captured under the illumination of the first light source and the second light source. The present inventor has found that it is possible to capture the image of the medicine in which the engraved mark is emphasized when the medicine is photographed under the illumination of the first light source and the second light source.
<Step 330> Print extraction The computer performs a print extraction process on the “image 3” and the “image 4”, that is, the images captured under the illumination of the third light source and the fourth light source, The present inventor has found that it is possible to capture the image of the medicine in which the print is emphasized when the medicine is photographed under the illumination of the third light source and the fourth light source.
<Step 340> Engraved mark/print determination As described above, an image in which the engraved mark attached to the surface of the medicine is suitably extracted can be obtained by performing the engraved mark extraction process (step 320) on the images captured under the illumination of the first ring light and the second ring light. Further, an image in which the print attached to the surface of the medicine is suitably extracted by performing the print extraction process (step 330) on the images captured under the illumination of the first bar light, the second bar light, the third bar light and the fourth bar light (see the above equation 1). On the basis of these engraved mark extracted image and print extracted image, the computer determines whether the information attached to the surface of the medicine is the engraved mark or the print, that is, whether or not the engraved mark and the print are attached to the surface of the medicine.
In order to determine whether or not the engraved mark is attached to the medicine, the computer first performs the binarization process on the engraved mark extracted image obtained at step 320 with using a predetermined threshold value as a criterion. Next, the computer takes an average value of the values of the engraved mark extracted image with using this binarized image as a mask. When the average value is equal to or larger than the threshold value, the computer determines that the engraved mark exists and when the average value is smaller than the threshold value, the computer determines that the engraved mark does not exist. Similarly, in order to determine whether or not the print is attached to the medicine, the computer first performs the binarization process on the print extracted image obtained at step 330 with using on a predetermined threshold value as a criterion. Next, the computer takes an average value of the values of the print extracted image with using the binarized image as a mask. When the average value is equal to or larger than the threshold value, the computer determines that the print exists and when the average value is smaller than the threshold value, the computer determines that print does not exist.
<Step 350> Dividing line area extraction The computer performs a dividing line area extraction process on the engraved mark extracted image obtained at step 320. Specifically, the computer determines whether or not the dividing line exists on the medicine. When it is determined that the dividing line exists, the medicine is divided into an area where the dividing line exists and an area other than it.
<Step 360> Representative color extraction Next, the computer separately extracts the representative color of the medicine for each of the area where the engraved mark or the print is attached and the area other than it. The representative color extraction can be suitably performed by performing clustering on colors constituting the pixels. In addition, in another embodiment, instead of extracting the representative color, a determination for a color density of “white”, “light color” and “dark color” is performed on the image of the medicine, or the area where the engraved mark or the print is attached and the area other than it. This can be performed by determining to be “dark color” if the color in the area is less than a first threshold value, the “light color” if it is equal to or greater than the first threshold value and less than a second threshold value and the “white” if it is equal to or greater than the second threshold value.
<Step 370> Narrowing down The computer accesses the database. Then, a search for the candidate medicines is performed based on the data obtained at the above steps. First, as a first step, narrowing down with respect to search target medicines is performed. Specifically, the computer narrows down the search target medicines based on at least one of the following: the type of the medicine (tablet or other type medicine), the shape of the medicine (circular or non-circular, or the ratio of the lengths of the long axis and the short axis in the case of non-circular), the size of the medicine (the diameter of the medicine in the case of circular, the length of the long axis and the length of the short axis of the medicine in the case of non-circular), the presence or absence of the engraved mark, the presence or absence of the print, the presence or absence of the dividing line, the representative color of the medicine (the representative color of the area where the engraved mark is attached, the representative color of the area where the print is attached and the representative color of the area other than it). In this regard, if the computer can access a prescription history of the patient (for example, the data of the medicine handbook), the computer can limit the search target medicines to medicines contained in the prescription history. For example, if the computer can access the data of the medicine handbook stored in a smart phone of the patient, the computer can access the data of the medicine handbook to obtain information on the medicine prescribed to the patient. When there is a medicine handbook printed on paper, the medicine handbook is scanned and converted into text data by OCR (optical character recognition), and the search target medicines can be narrowed down based on the text data. As a result, the speed of the medicine search can be increased.
<Step 380> Template matching Thereafter, the template matching (also referred to as pattern matching) is performed between the engraved marked extracted image and/or the print extracted image obtained at the aforementioned steps and an engraved mark template image and/or a print template image for each medicine stored in the database to pick up medicines having a high possibility of matching with the discrimination target medicine. In this regard, in the case where the tablet is circular, the area of the image occupied by the medicine is moved and corrected so that the center of the circle coincides with the center of the image prior to the template matching. In another embodiment, the extracted image and the template image may be corrected so that the center of gravity of the engraved mark and/or the print coincides with the center of the image. Further, when the tablet is circular, the extracted image and/or the template image is rotated so that the result of the template matching is maximized. Thereafter, the template matching is performed on both images to calculate a score. This score indicates a degree of coincidence of the both images as a numerical value. When the score of the template matching is equal to or larger than a predetermined value or when the score is within a predetermined rank from the top rank, the computer picks up the medicine to which the template image belongs as a candidate medicine. In this regard, when the tablet has the dividing line, both of the template matching in a state that the dividing line exists and the template matching in a state that the dividing line is removed may be performed. Further, when the print or the engraved mark is constituted of words, the computer may perform the template matching on each word as one unit or may divide each word into characters, numbers and symbols to perform the template matching on each character, number and symbol. Further, the computer may extract text information from the engraved mark or the printed image with OCR and perform the template matching based on this text information.
<Step 400> Capsule discrimination Referring back to step 220 in
<Step 410> Area dividing First, the computer divides the medicine into the two areas. In particular, the color information of the image of the medicine, specifically, the colors of the pixels are clustered. Next, the clustered color information is grouped and an area to which this color group belongs is categorized as one area. Thus, the capsule whose color is constituted of different colors on a right half side and a left half side thereof is suitably divided into the two areas.
<Step 420> Representative color extraction Next, the computer extracts the representative color of each area of the medicine. This can be suitably performed by clustering the color information of the pixels constituting each area.
<Step 430> Print extraction The computer performs the same process as that of step 330 on each area divided at step 410 to extract the print from each area. The present inventor has found that it is possible to more suitably extract the print from the capsule by dividing the image of the capsule into the two areas and separately performing the extraction process for the print image on these areas.
<Step 440> Print determination The computer performs the same process as that of step 340 on each divided area of the medicine to determine whether or not the print is attached to each area.
<Step 450> Narrowing down The computer narrows down the candidate medicines with the same manner as that of step 360. Specifically, the computer narrows down the search target medicines based on at least one of the type of the medicine (capsule or other type medicine), the shape of the medicine (the ratio of the lengths of the long axis and the short axis of the medicine), the size of the medicine (the lengths of the long axis and the short axis of the medicine), the representative color and the presence or absence of the print in the areas to which each representative color belongs.
<Step 460> Template matching The computer cuts out a printed portion from the print extracted image (input image) obtained at step 430, Next, the template matching is performed on the print extracted image for each area of the print extracted image divided at step 410 with the same manner as that of step 370 to pick up the candidate medicines.
§ 4 Additional process of medicine discrimination software § 4.1 Additional process at “step 370” At step 370 described above, it is assumed that the template image corresponding to the engraved mark extracted image and/or the print extracted image is stored in the database accessed by the computer. In some cases, however, only a photograph of the medicine may be stored. In that case, an area of the medicine may be obtained from this image data and the print extraction and the engraved mark extraction may be performed in the same manner as the above-described case to use the obtained print extracted image and the obtained engraved mark extracted image as the template image. Further, this method can be used to create a template image to be stored in the database. Note that the area of the medicine can be obtained from the image data as follows. First, a background color is obtained and a portion other than the background color and characters is determined to be an area occupied by the medicine. If one or three or more areas are found, it is determined as an error. Next, a position of the center of gravity of each area is obtained and the right side and left side of the medicine are determined from the position of the center of gravity.
§ 4.2 Calibration for camera In order to suitably practice the above embodiment, the first camera and the second camera need to be in focus. Further, it is necessary to coincide the photographing area of the first camera with the photographing area of the second camera. Furthermore, the brightness and the color of the photographed image should also be within a predetermined value range. For this reason, the calibration as described below is performed before shipping the medicine discriminating system from a factory or at the time of setting up the medicine discriminating system at a delivery destination. Note that once this calibration is performed, it is usually not necessary to perform the calibration again.
§ 4.2.1 Camera positioning In this calibration, camera positioning is first performed. First, the tray on which the petri dish is set is set onto the placing portion 220 of the medicine photographing device 200. Next, the petri dish is photographed by the first camera and this photographed image is displayed on the display device of the computer. At this time, a virtual image having a cross mark at a predetermined position is superimposed on the image of the petri dish and displayed. Then, the position and the angle of the first camera are finely adjusted so that this cross mark is located inside the petri dish. The same operation is performed for the second camera.
§ 4.2.2 Camera focus adjustment Next, the focus of the camera is adjusted. First, a template with predetermined characters, symbols or diagrams is set onto the placing portion of the medicine photographing device and this template is photographed with a low magnification. Then, the focus of the camera is roughly adjusted so that the indications of the template becomes the clearest in the photographed image. After this operation has been completed, the magnification is increased and the same operation is performed to finely adjust the focus.
§ 4.2.3 Calibration of photographing area The coordinates of the photographing areas of the upper and lower cameras can be matched by this calibration. Further, the resolutions of the cameras can also be obtained. First, a calibration sheet 910, which is a calibration tool as shown in
§ 4.2.4 Calibration of brightness and color The color reproducibility of the photographed image can be enhanced by this calibration. In the same manner as the case described above, the following (a) to (b) are repeatedly performed in a state that the calibration sheet 910 is placed on the placing portion. (a) Exposure adjustment: Photographing is performed by the first camera with a predetermined exposure time in a state that the first light source is turned on. Further, photographing is performed by the second camera with a predetermined exposure time in a state that the second light source is turned on. Then, the brightness of each predetermined point of the photographed image is calculated. If this brightness is higher than a target value, the exposure time of the camera is decreased. If this brightness is lower than the target value, the exposure time of the camera is increased. (b) Color (white balance) adjustment: the RGB value of each predetermined point of the photographed image is calculated. When B (blue) is larger than R (red), the gain for R is increased. When B is smaller than R, the gain for R is lowered. When B is larger than G (green), the gain for G is increased. When B is smaller than G, the gain of G is lowered. The above steps (a)-(b) are repeated until each value reaches the target value. With this operation, setting values for the camera at the time of photographing is obtained. The same operation is also performed with the third light source and the first camera and with the fourth light source and the second camera.
100 . . . medicine dispensing device 110 . . . vial bottle feeding device 120 . . . label attachment device 130 . . . vial bottle carrying device 140 . . . discharge port 150 . . . cassette arranged portion 160 . . . touch panel display 170 . . . optical scanner 180 . . . medicine supplying part 181 . . . RF tag reading device 182 . . . unlocking device 190 . . . control part 200 . . . medicine dispensing cassette 210 . . . main body 211 . . . RF tag 212 . . . hole 213 . . . right side inner wall 220 . . . first rotating body 230 . . . cylindrical portion 300 . . . first sub-member 310 . . . lid 311 . . . hinge 320 . . . engaging portion 321 . . . protruding portion 322 . . . slit 323 . . . rib 400 . . . tray 410 . . . petri dish 411 . . . bottom portion 412 . . . side surface 413 . . . ring 414 . . . capsule placing member 415 . . . transparent portion 416 . . . concave portion 417 . . . concave portion 420 . . . main body 421 . . . hole 422 . . . cylinder 500 . . . main member 600 . . . third sub-member 710 . . . first camera 720 . . . second camera 730 . . . first light source 731 . . . first ring light 740 . . . second light source 741 . . . second ring light 742 . . . lower support plate 743 . . . upper light source 750 . . . third light source 751 . . . first bar light 760 . . . fourth light source 761 . . . third bar light 762 . . . fourth bar light 800 . . . locking mechanism 810 . . . inclined portion 820 . . . shaft 830 . . . biasing member 831 . . . base end portion 832 . . . curved portion 833 . . . tip end portion 840 . . . engaging member 900 . . . medicine photographing device 910 . . . case 911 . . . lower case 912 . . . cutout portion 913 . . . upper case 914 . . . cover 915 . . . inclined portion 916 . . . slope 917 . . . cutout space 920 . . . placing portion 921 . . . tray support member 922 . . . hole 923 . . . engaging portion 930 vguide member 931 . . . slope 940 . . . upper internal space 950 . . . frame
Number | Date | Country | Kind |
---|---|---|---|
2018-159036 | Aug 2018 | JP | national |
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/JP2019/032465 | 8/20/2019 | WO | 00 |