Image shooting, attribute information determination method, device and electronic equipment
By setting up a reference logo in the target area and placing an object to be photographed, the image obtained includes the reference signs and specific areas to be photographed. It solves the problem of obtaining pig attribute information that is difficult to obtain piglets through images. Efficiency.
Patent Information
- Application Number
- CN202211735126.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-30
- Publication Date
- 2025-01-28
- Estimated Expiration
- 2042-12-30
AI Technical Summary
When performing insurance claims for livestock farming, it is difficult to obtain sufficient information through image shooting to determine specific attributes of pigs, such as body length or weight, and automatic identification methods are lacking.
By setting up a reference logo (such as horizontal line) in the target area and placing the objects to be taken to the position that meets the preset association requirements. Its attribute information.
The specific attribute information of the pigs is obtained through the image, the problem of automatic recognition is solved, and the efficiency and accuracy of the claims process is improved.
Smart Images

Figure CN116261039B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of insurance technology, and in particular to an image shooting method, a method and device for determining attribute information of a target object, an electronic device and a computer-readable storage medium. Background Art
[0002] In order to reduce farmers' breeding risks, insurance companies have launched livestock breeding insurance.
[0003] For this type of insurance, when making a claim, the insurance company usually needs to collect images of the livestock (such as pigs) being claimed, and estimate the information of the specific attributes of the pigs (such as body length or weight) based on the images, and then determine the claim amount.
[0004] In order to accurately estimate the specific attributes of live pigs, some staff members proposed setting up reference objects relative to the live pigs and then taking images. However, the problems are:
[0005] 1. What reference objects should be set and what objects should be photographed so that the images obtained contain enough information to determine the specific attributes of the pigs;
[0006] 2. How to automatically identify information about specific attributes of live pigs based on captured images. Summary of the invention
[0007] The purpose of an embodiment of the present invention is to provide an image capturing method to solve the problem of how to set a reference object and which objects to capture so that the captured image contains sufficient information for use in determining information on specific attributes of the object to be captured (such as a pig).
[0008] The embodiment of the present invention further provides a method for determining attribute information of a target object to solve the problem of how to automatically identify information on specific attributes of a target object to be detected (such as a pig) based on a captured image.
[0009] The embodiments of the present application also provide a device for determining attribute information of a target object, an electronic device, and a computer-readable storage medium.
[0010] To solve the above technical problems, the embodiments of the present invention are implemented as follows:
[0011] In a first aspect, an embodiment of the present invention provides an image capturing method, comprising:
[0012] A reference mark is set in a first sub-area included in the target area; an object to be photographed is placed in a second sub-area included in the target area, so that the posture of the target object placed in the second sub-area meets the preset association requirements with the first sub-area; and the target area where the object to be photographed is placed is photographed, so that the first sub-area and the second sub-area appear in the same image obtained by the photographing.
[0013] In one implementation, setting a reference mark in a first sub-region included in the target region includes: setting a dotted horizontal line in the first sub-region.
[0014] In a second aspect, an embodiment of the present invention provides a method for determining attribute information of a target object, including:
[0015] Acquire a target image; based on the target image, acquire information on designated attributes of a target reference marker in a specific image region of the target image; wherein the specific image region is an image region that meets preset association requirements with the posture of a target object to be detected in the target image; the association requirements are set based on the attributes to be detected of the target object to be detected and possible postures of the target object to be detected in the target image; determine information on the attributes to be detected of the target object to be detected based on information on designated attributes of the target reference marker and a mapping relationship between information on the designated attributes of the preset reference marker and information on the attributes to be detected.
[0016] In a third aspect, an embodiment of the present invention provides an insurance claim method, comprising: obtaining information on the attributes to be measured of the target object to be detected; determining a claim amount based on the information on the attributes to be measured of the target object to be detected; wherein the target object to be detected is livestock; and the attributes to be measured include at least one of body length and weight.
[0017] In a fourth aspect, an embodiment of the present invention provides a method for training a target recognition model, comprising: obtaining a sample image data set, wherein a single sample image contains multiple target objects and target reference marks; inputting the sample image data set into an initial recognition model, and using the position information of the first circumscribed rectangular box of each target object in the multiple target objects, the category information of the first circumscribed rectangular box, the position information of the second circumscribed rectangular box of the target reference mark, and the category information of the second circumscribed rectangular box as model outputs to train the initial recognition model to obtain a trained target recognition model.
[0018] In a fifth aspect, an embodiment of the present invention provides a device for determining attribute information of a target, comprising: an acquisition module for acquiring a target image; an attribute information acquisition module for acquiring, based on the target image, information on specified attributes of a target reference mark in a specific image area of the target image; wherein the specific image area is an image area that meets a preset association requirement with the posture of a target object to be detected in the target image; the association requirement is set based on the attributes to be measured of the target object to be detected and the possible postures of the target object to be detected in the target image; a determination module for determining the information on the attributes to be measured of the target object to be detected based on the information on the specified attributes of the target reference mark and the mapping relationship between the information on the specified attributes of the preset reference mark and the information on the attributes to be measured.
[0019] In a sixth aspect, an embodiment of the present invention provides an insurance claims settlement device, including:
[0020] The module for acquiring information on attributes to be measured is used to acquire information on attributes to be measured of the target object to be detected; the module for determining the claim amount is used to determine the claim amount based on the information on attributes to be measured of the target object to be detected; wherein the information on attributes to be measured of the target object to be detected is livestock, and the attributes to be measured include at least one of body length and weight.
[0021] In the seventh aspect, an embodiment of the present invention provides a training device for a target recognition model, comprising: a sample image data set acquisition module, used to acquire a sample image data set, wherein a single sample image contains multiple target objects and target reference marks; a training module, used to input the sample image data set into an initial recognition model, and use the position information of the first circumscribed rectangular frame of each target object in the multiple target objects, the category information of the first circumscribed rectangular frame, the position information of the second circumscribed rectangular frame of the target reference mark, and the category information of the second circumscribed rectangular frame as model outputs to train the initial recognition model to obtain a trained target recognition model.
[0022] In an eighth aspect, an embodiment of the present invention provides an electronic device for a method for determining attribute information of a target object, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the method for determining attribute information of a target object provided in the above embodiment.
[0023] In the ninth aspect, an embodiment of the present invention provides a computer-readable storage medium, characterized in that a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method for determining the attribute information of the target object provided in the above embodiment are implemented.
[0024] It can be seen from the technical solution provided by the above embodiments of the present invention that in the embodiments of the present invention, by setting reference marks in a specific area and placing the target to be detected in a specific position, it is ensured that the captured image contains the target to be detected and the reference marks in the specific area, thereby avoiding the problem of insufficient information in the captured image.
[0025] Based on the target image, information on designated attributes of the target reference mark in a specific image area of the target image is obtained, and further, based on the information on designated attributes of the target reference mark and a mapping relationship between information on designated attributes of a preset reference mark and information on attributes to be measured, information on the attributes to be measured of the target object to be detected can be determined, thereby solving the problem of how to automatically identify information on specific attributes of a target to be detected (such as a pig) based on a captured image. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0027] Figure 1a A schematic diagram of a flow chart of an image capturing method provided by an embodiment of the present invention;
[0028] Figure 1b A schematic diagram of the location of part of the first sub-area provided in an embodiment of the present invention;
[0029] Figure 2a A schematic diagram of a flow chart of a method for determining attribute information of a target object provided by an embodiment of the present invention;
[0030] Figure 2b A schematic diagram of the positional relationship between a detection frame and an object, and the coordinate values of the four corners of the detection frame in the image coordinate system provided by an embodiment of the present invention;
[0031] Figure 2c A schematic diagram of the types and positions of target objects to be detected and reference marks provided in an embodiment of the present invention;
[0032] Figure 2d A schematic diagram of location information of some specific areas provided by an embodiment of the present invention;
[0033] Figure 2e A schematic diagram of the position information of the area to be cropped provided by an embodiment of the present invention;
[0034] Figure 2fA schematic diagram of a cropped image provided by an embodiment of the present invention;
[0035] Figure 2g A schematic diagram of another type of position information of a region to be cropped provided by an embodiment of the present invention;
[0036] Figure 2h A schematic diagram of another method of cropping an image provided by an embodiment of the present invention;
[0037] Figure 3 A flowchart of an insurance claim settlement method provided by an embodiment of the present invention;
[0038] Figure 4 A schematic diagram of a flow chart of a method for training a target recognition model provided by an embodiment of the present invention;
[0039] Figure 5 A schematic diagram of an implementation flow of a method for determining attribute information of a target provided by an embodiment of the present invention;
[0040] Figure 6 A schematic diagram of the structure of a device for determining attribute information of a target object provided by an embodiment of the present invention;
[0041] Figure 7 A schematic diagram of the structure of an insurance claims settlement device provided by an embodiment of the present invention;
[0042] Figure 8 A schematic diagram of the structure of a training device for a target recognition model provided by an embodiment of the present invention;
[0043] Fig. 9 A schematic diagram of the structure of an electronic device for determining attribute information of a target object provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0044] The embodiments of the present invention provide a method, device and electronic device for image shooting and determining attribute information.
[0045] In order to enable those skilled in the art to better understand the technical solutions in the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0046] Embodiment 1
[0047] In the scenario of making claims for livestock (such as pigs), you can consider setting up reference objects next to the pigs. By acquiring images between the live pigs on site and the reference objects, you can analyze the information on the specific attributes between the pigs and the reference objects. Based on the information on the specific attributes (such as the weight or length of the pigs), you can calculate the claim amount based on the weight or length.
[0048] However, if the live pigs and the reference are not placed properly, the information in the acquired on-site images cannot be used to obtain the information on the specific attributes between the live pigs and the reference objects. At the same time, the difference in the information content acquired during the image acquisition process will also result in the inability to determine the information on the specific attributes between the live pigs and the reference objects from the images. Therefore, how to set the reference objects, how to place the live pigs, and what to shoot are urgent issues to be resolved by those skilled in the art.
[0049] In order to solve the above problem and ensure that the acquired image contains information that can be used to determine the specific attributes of the pig, an embodiment of the present invention provides an image shooting method.
[0050] The inventive concept can be summarized as follows: before acquiring the on-site image, dotted and horizontal line reference marks are first set in the first sub-area of the target area, and the posture of the object to be photographed is placed in the second sub-area of the target area in a manner that meets the preset association requirements with the first sub-area. Furthermore, the target area where the object to be photographed is placed is photographed so that the first sub-area and the second sub-area appear in the same image obtained by photographing. Therefore, in the embodiments of the present invention, information used to determine the specific attributes between the live pig and the reference object can be obtained from the image by reasonably setting the target to be photographed and the reference mark marks and standardizing the shooting content.
[0051] The execution subject of the following method includes but is not limited to a terminal or a server.
[0052] like Figure 1a As shown, the method may specifically include the following steps:
[0053] Step S11: setting a reference mark in a first sub-region included in the target region.
[0054] The target area includes a first sub-area for setting a reference mark.
[0055] The reference mark may be a dotted line, a dotted curve, or a dotted horizontal line. Preferably, in this embodiment, the reference mark is a dotted horizontal line.
[0056] In order to ensure that the reference mark can be captured more clearly by the camera, the color of the reference mark cannot be the same as the color of the shooting site.
[0057] In one implementation, when the insured livestock (such as pigs) of a farmer dies, the insurance company needs to collect evidence and pay compensation. Therefore, the insurance claims adjuster needs to be at the evidence collection site and can follow the following procedures: Figure 1b In the manner shown, dotted and horizontal reference marks are set in the gray area.
[0058] Step S12, placing the object to be photographed in a second sub-area included in the target area, so that the posture of the target object placed in the second sub-area meets the preset association requirement with the first sub-area.
[0059] The target area further includes a second sub-area for placing the object to be photographed. The object to be photographed may be, for example, livestock. The livestock may specifically be at least one of pigs, cattle, and sheep.
[0060] The following is an introduction using the example of a live pig as the object to be photographed.
[0061] Taking into account that more accurate data can be obtained from the captured images later, the method for placing the object to be photographed can be performed in a manner that meets the association requirements between the posture of the target object in the second sub-area and the arrangement of the reference marks in the first sub-area.
[0062] Among them, the association requirement can be a pre-set association requirement rule, that is, the corresponding relationship between what kind of reference mark should correspond to what kind of posture of the target object. For example, when the reference mark is a dotted horizontal line and is set to be parallel to the X-axis, in the process of placing the target object, if the head and tail of the target object are used as the reference line, the target object is placed in a specific area of the reference mark in a manner that the reference line of the target object is kept horizontal with the Y-axis. Taking the target object as a pig as an example, the specific area at this time can be expressed as an area formed by the position above the head of the pig to the upper boundary of the target image as the length of the specific area and the width of the pig's trunk as the width of the specific area; when the reference mark is a dotted horizontal line and is set to be parallel to the Y-axis, in the process of placing the target object, if the head and tail of the target object are used as the reference line, the target object is placed in a specific area of the reference mark in a manner that the reference line of the target object is kept horizontal with the X-axis. Taking the target object as a pig as an example, the specific area at this time can be expressed as an area formed by the position above the head of the pig to the right boundary of the target image as the length of the specific area and the width of the pig's trunk as the width of the specific area.
[0063] In one implementation, Figure 1bAs shown, following the contents of the embodiment in step S11, at the evidence collection site, the insurance claims adjuster sets dotted and horizontal line reference marks in the gray area, and places the pig on the dotted and horizontal line reference marks based on the set dotted and horizontal line positions and styles, taking the connecting line of the pig's head and tail as a reference to maintain a vertical position relationship with the dotted and horizontal lines, and aligning the pig's tail position with the horizontal line mark, and keeping the pig's head position and the dot mark on the same vertical line. At the same time, ensure that the pig is in a side-lying posture, that is, the pig's limbs are not blocked by the trunk.
[0064] Step S13, photographing the target area where the object to be photographed is placed, so that the first sub-area and the second sub-area appear in the same photographed image.
[0065] In one implementation, following the embodiment of step S12, after the insurance claims adjuster has placed the live pigs on the reference mark in a positional relationship that matches the reference mark, the scene is photographed using a camera, wherein in a single image, the content of the image includes a gray area of the reference mark with dotted and horizontal lines and the live pigs placed on the dotted and horizontal lines.
[0066] An embodiment of the present invention provides an image capturing method, which ensures that the captured image contains the target to be detected and the reference mark in the specific area by setting a reference mark in the specific area and placing the target to be detected in a specific position, thereby avoiding the problem of insufficient information in the captured image.
[0067] Embodiment 2
[0068] In order to solve the problem of how to automatically identify information about specific attributes of a live pig based on captured images, an embodiment of the present application provides a method for determining attribute information of a target object.
[0069] See also Figure 2a , Figure 2a 1 is a flow chart of a method for determining the attribute information of a target object provided by an embodiment of the present invention. The method for determining the attribute information of a target object can be applied to a user terminal, and the method is executed by an application software installed in the user terminal. The user terminal can be, for example, a desktop computer, a laptop computer, a tablet computer or a mobile phone, a smart wearable device, etc. The method can also be applied to a server.
[0070] The different steps of the method may be implemented by the same execution subject or by different execution subjects. The embodiment of the present application does not limit the execution subject used to implement the method.
[0071] In addition, the execution order of different steps is not limited in the embodiment of the present application. When using the method provided in the embodiment of the present application, the execution order of different steps can be adjusted according to actual needs.
[0072] For ease of description, the method provided in the embodiment of the present application is described in detail below by taking a server device for determining the attribute information of a target object as an example of the execution subject of the method.
[0073] The method comprises the following steps:
[0074] Step S21, acquiring a target image.
[0075] Among them, the target image can be obtained by taking a photo with a terminal device, uploading the target image to a server through a local device, or obtaining the target image in the server by calling the interface of the server corresponding to the storage target image.
[0076] In one implementation, for an insurance claim scenario, a camera may be used to photograph the claim site to obtain a target image.
[0077] Step S22, based on the target image, obtaining information of a specified attribute of a target reference mark in a specific image area of the target image;
[0078] The specific image region is an image region that meets a preset association requirement with the posture of the target object to be detected in the target image.
[0079] Generally, whether there is an image area (i.e., a specific image area) in the target image that meets the preset association requirements with the posture of the target object to be detected (such as a live pig) can be determined by direct observation by the staff. If such an image area exists, the staff can input such a target image into the server device as the target image described in step S21. In this way, the server device can directly obtain the information of the specified attribute of the target reference mark from the specific image area according to the preset position information of the specific image area in the target image (such as the upper half of the image).
[0080] Alternatively, the server device may also identify the target object to be detected and its posture through an image recognition algorithm, and then determine from the target image an image area that meets preset association requirements with the posture of the target object to be detected as a specific image area; and then obtain information on specified attributes of the target reference mark from the specific image area.
[0081] The association requirement is set based on the attributes of the target object to be detected and the possible postures of the target object to be detected in the target image, as illustrated below:
[0082] Take the target object to be detected as a pig as an example. In one case, the line connecting the head and tail of the pig is used as the baseline, and the head of the pig is used as the positive direction of the baseline. If the posture of the pig is that the head is facing the positive direction of the Y-axis of the coordinate system, and the corresponding baseline of the pig is horizontal with the Y-axis, then the specific area at this time can be expressed as: the width of the specific area is equal to the width of the pig's trunk, and the length of the specific area is equal to the length of the boundary directly above the pig's head that does not exceed the length of the boundary directly above the pig's head that does not exceed the positive direction of the X-axis of the target image. In another case, the line connecting the head and tail of the pig is used as the baseline, and the head of the pig is used as the positive direction of the baseline. If the posture of the pig is that the head is facing the positive direction of the X-axis of the coordinate system, and the corresponding baseline of the pig is horizontal with the X-axis, then the specific area at this time can be expressed as: the width of the specific area is equal to the width of the pig's trunk, and the length of the specific area is equal to the length of the boundary directly above the pig's head that does not exceed the positive direction of the X-axis of the target image.
[0083] Among them, the specified attribute information of the target reference mark can be pre-set information for characterizing the attributes of the target reference mark, such as quantity attributes, area attributes, color attributes, etc. In the scenario of this solution, the above-mentioned specified attribute information is preferably quantity attribute information.
[0084] In this embodiment, in order to improve the efficiency of obtaining the specified attribute information, a method for obtaining the specified attribute information of the target reference mark is further provided, which specifically includes the following steps S221 to S222:
[0085] Step S221: using a target recognition model to recognize the target image to identify whether the target reference mark exists in the specific image area.
[0086] Among them, the target recognition model can be used for target detection, which is called Object Detection in English. It refers to determining the location and category of objects from the input image data (there are often many objects in the image data). It is a very core and basic task in computer vision. Image data segmentation, object tracking, key point detection, etc. usually rely on target detection.
[0087] Generally, the task objective of the object detection task is to output the class of the object and the position of the bounding box corresponding to the object. The bounding box is the detection box for the object, also known as the object detection box, the external box or the boundary box. The shape is generally rectangular, so there is a way to call it the external rectangular box.
[0088] like Figure 2b As shown, the positional relationship between the circumscribed rectangular frame and the object, and the position information of the target object are shown. The position information can be represented by the coordinate values of the four corners of the circumscribed rectangular frame in the image data coordinate system.
[0089] Generally, there are three formats to express the location of the bounding rectangle:
[0090] XYXY, that is, (X1, Y1, X2, Y2), where (X1, Y1) is the coordinate of the upper left corner of the bounding rectangle, and (X2, Y2) is the coordinate of the lower right corner of the bounding rectangle;
[0091] XYwh, that is, (X, Y, w, h), where (X, Y) is the coordinate of the upper left corner of the bounding rectangle, w is the width of the bounding rectangle, and h is the height of the bounding rectangle; w and h can be referred to Figure 2;
[0092] cXcYwh, that is, (Xc, Yc, w, h), where (Xc, Yc) are the coordinates of the center point of the circumscribed rectangular box, w is the width of the circumscribed rectangular box, and h is the height of the circumscribed rectangular box.
[0093] The data in the above three formats can all be called the four-dimensional data of the circumscribed rectangular box. In particular, (X1, Y1, X2, Y2) is called the four-dimensional coordinates of the circumscribed rectangular box.
[0094] Among them, the target recognition model can be trained by taking a sample image containing a target object and a target reference mark as a model input, and taking the position information of the first circumscribed rectangular frame of each target object in the target, the category information of the first circumscribed rectangular frame, the position information of the second circumscribed rectangular frame of the target reference mark, and the category information of the second circumscribed rectangular frame as model output.
[0095] In one implementation, when insurance claims are being processed in a scenario where live pigs are the objects of insurance claims, the target recognition model may be trained using a labeled sample image containing live pigs and dot and horizontal line reference marks as model input, and using an externally bounded rectangular box for marking the live pig's position information, an externally bounded rectangular box for marking the live pig's category information, an externally bounded rectangular box for marking the dot and horizontal line reference mark position information, and an externally bounded rectangular box for marking the dot and horizontal line category information as model outputs.
[0096] Among them, considering that the sizes and postures of the target objects contained in the target detection target image are different, if the target recognition model is used to detect the target image, there may be a situation where the target reference mark cannot be detected. Therefore, the preferred method may be to first determine whether the target reference mark exists in the specific image area.
[0097] In a specific implementation scenario, there may be the following two situations. First, if the body length of the pig is within the range of the target reference mark that can be used to identify the specified attribute information of the pig, the pig is placed so that it does not block all the target reference marks, and thus, the target reference mark exists in the specific image area. Second, if the body length of the pig exceeds the range of the target reference mark that can be used to identify the specified attribute information of the pig, the target recognition model cannot recognize the existence of the target reference mark in the specific area, that is, the number of target reference marks defaults to zero.
[0098] Step S222: Determine information on the specified attributes of the target reference mark based on the recognition result.
[0099] The recognition result may include at least one of the presence and absence of the target reference marker, and then, based on the presence of the target reference marker in the recognition result, the number of the target reference markers is counted to determine the information of the specified attributes of the target reference marker.
[0100] The information of the specified attribute of the target reference marker in the scenario of this embodiment may be the quantity information of the target reference marker.
[0101] like Figure 2c As shown, the target recognition model can be used to identify the target reference mark as well as the target object to be detected. Specifically, the target recognition model can be a target detection model. According to the function of the target detection model, its recognition result generally includes: type and position. Specifically, for example, the type and position of the target object to be detected and the target reference mark are identified. More specifically, when the target to be detected is a live pig, the type is "live pig"; when the target reference mark includes a red dot, the type can be "red dot" or "reference mark".
[0102] In one implementation, when conducting insurance claims in a scenario where live pigs are the object of insurance claims, the target recognition model can recognize at least one of two types of information on specified attributes: if red dots can be recognized, the number of recognized red dots is counted as the information on the specified attributes of the target reference mark; if red dots cannot be recognized, the default number "0" can be used as the information on the specified attributes of the target reference mark.
[0103] Step S23, determining the information of the attribute to be measured of the target object to be detected based on the information of the designated attribute of the target reference mark and the mapping relationship between the preset information of the designated attribute of the reference mark and the information of the attribute to be measured.
[0104] The mapping relationship may be set using the method shown in Table 1 below.
[0105] Table 1:
[0106] Serial number Specify the attribute information Information about the attribute to be tested 1 0 Greater than or equal to 120cm 2 1 100-110cm 3 2 90-100cm 4 3 80-90cm 5 ... ...
[0107] The information of the attribute to be measured may be the body length information, weight information, etc. of the target object to be measured. In the present embodiment, the body length information is preferred.
[0108] Considering that in order to further improve the accuracy and detection efficiency of the information of the specified attribute detected, in the embodiment of the present application, the following steps S231 to S232 are also included, including:
[0109] Step S231: adopting a preset image cropping strategy to crop the target image to obtain a cropped image that includes an area where a single target object to be detected is located and a corresponding specific image area.
[0110] The preset strategies include a preset cutting strategy for improving cutting efficiency and a preset cutting strategy for improving cutting accuracy.
[0111] Among them, the preset cutting strategies for improving cutting efficiency include:
[0112] Step S2311: If it is identified that the target reference mark exists in the target image, and the target image contains a plurality of the target objects to be detected, then based on the position information of each of the target objects to be detected in the target image, the posture of the target object to be detected, and the association requirement, the position information of the specific image area corresponding to each of the target objects to be detected is determined, wherein: Figure 2d The location information of the specific area shown is one of the ways to present the location information of the specific area.
[0113] In one implementation, when an insurance claim is being settled in a scenario where the object of the insurance claim is a live pig, a target recognition model is used to identify the claim scene image. If a red dot mark can be identified in the image, and the image contains multiple live pigs, based on the correspondence between the position information of the live pigs in the image and the posture of the live pigs, wherein the correspondence has been described in detail in step S2 of the second embodiment, the position information of the areas to be cropped corresponding to each live pig is determined, wherein: Figure 2e The position of the area to be cropped is shown as one of the presentation methods.
[0114] The area to be cropped is cropped to obtain a cropped image.
[0115] Step S2312: based on the position information of each of the targets to be detected and the position information of each of the specific image regions, cropping images that respectively include the region where a single target object to be detected is located and the corresponding specific image region are cropped from the target image.
[0116] like Figure 2c As shown, in one implementation, the position information of the target to be detected can be the position of the circumscribed rectangular frame around the pig in the figure, the position information of the specific area, such as Figure 2c As shown, the position of the dotted rectangular frame of the red dot reference mark on the pig's head can be obtained. Finally, according to the position of the pig and the position of the red dot reference mark, a cropped image is obtained, such as Figure 2e As shown in the figure, the position of the dotted rectangular box is the position of the cropped image, Figure 2f Shown is a cropped image.
[0117] Among them, the cropping preset strategies used to improve cropping accuracy include:
[0118] Step S2321: if it is identified that the target reference mark exists in the target image, then according to a preset distribution rule of multiple target reference marks, position information of each specific image area is determined;
[0119] The size of the specific image area can be adjusted manually. For example, the width of the specific area can be adjusted accordingly according to the width of the target image, or the width of the specific image area can be adjusted according to the width of the object to be detected.
[0120] like Figure 2g As shown, in one implementation, the target recognition model is used to recognize the claim scene scene image, which is the same as the scenario in which the user's preset strategy for improving cropping efficiency is located. If the dotted and horizontal line reference marks are recognized in the image, the location information of the area of the dotted and horizontal line reference marks corresponding to the body length of each pig is determined according to the preset current distribution rule of the dotted and horizontal line reference marks. Then, according to the location information, cropped images containing the area where a pig is located and the area where the dotted and horizontal line reference mark image is located are cropped from the claim scene scene image, wherein the cropped image, such as Figure 2h shown.
[0121] Step S2322: based on the position information of each specific image area, cropped images each including an area where a single target object to be detected is located and a corresponding specific image area are cropped from the target image.
[0122] Considering that when shooting images of the claims scene, in order to ensure that enough content is captured, a wide-angle lens will be used during the shooting process, or due to the different heights and angles of the camera equipment, the non-image center area of the captured image will have a certain degree of stretching and deformation. Therefore, in order to ensure that the cropped image is not affected by image stretching, it is necessary to adjust each cropped image area to ensure that the adjacent target objects to be detected and reference marks are not cropped in during the cropping process, thereby ensuring the accuracy of the content contained in the cropped image.
[0123] To solve the above problem, the present embodiment provides the following method, which crops a cropped image containing a region where a single target object to be detected is located and a corresponding specific image region from a target image, including:
[0124] According to the curvature of the line and the preset correlation between the curvature of the line and the size of the cropped image, the target image is cropped to obtain a cropped image containing the area where a single target object to be detected is located and the corresponding specific image area.
[0125] In one implementation, the correlation between the degree of line curvature and the size of the cropped image can be expressed as follows: when the curvature of the line is 5 radians, the width of the cropping frame is shortened by 0.2 centimeters, and when the curvature of the line is 10 radians, the width of the cropping frame is shortened by 0.5 centimeters.
[0126] Step S232: Based on the cropped images, respectively obtain information on designated attributes of target reference marks in specific image areas respectively included in the cropped images.
[0127] In one implementation, based on the cropped image, the number of points in the dot-horizontal-line reference mark can be obtained from the cropped image, that is, the specified attribute information of the reference mark.
[0128] An embodiment of the present invention provides a method for determining the attribute information of a target object. Based on the target image, information on the specified attributes of a target reference mark in a specific image area of the target image is obtained. Further, based on the information on the specified attributes of the target reference mark and a mapping relationship between the information on the specified attributes of a preset reference mark and the information on the attributes to be measured, the information on the attributes to be measured of the target object to be detected can be determined. Ultimately, the problem of not being able to automatically identify information on specific attributes of live pigs based on captured images is solved.
[0129] Embodiment 3
[0130] An embodiment of the present application provides an insurance claims method based on the method for determining the attribute information of the target object provided in the above embodiment, which is used to provide on-site claims personnel with a method for quickly and batch-acquire the claim amounts of claim objects.
[0131] The executor of the method may be any computing device that can implement the method, such as a server, a mobile phone, a personal computer, a smart wearable device, a smart robot, and the like.
[0132] The different steps of the method may be implemented by the same execution subject or by different execution subjects. The embodiment of the present application does not limit the execution subject used to implement the method.
[0133] In addition, the execution order of different steps is not limited in the embodiment of the present application. When using the method provided in the embodiment of the present application, the execution order of different steps can be adjusted according to actual needs.
[0134] For the convenience of description, the server device of the following insurance claim settlement method is taken as an example as the execution subject of the method to introduce the method provided in the embodiment of the present application in detail.
[0135] The insurance claim settlement method may include: Figure 3 The following steps are shown:
[0136] Step S31: obtaining information on the properties of the target object to be detected;
[0137] Step S32: Determine the claim amount based on the information of the attribute to be detected of the target object to be detected; wherein the target object to be detected is livestock; and the attribute to be detected includes any one of body length and weight.
[0138] In one embodiment, following the specific scenario in Example 2, when the claims adjuster makes a claim for the live pig at the claims site, the number of red dots in the dotted and horizontal line reference marks corresponding to the live pig is obtained, and the range of the live pig's body length is determined according to the number of red dots. For example, when the number of red dots is 4, the live pig's body length is the minimum length range of 80 cm; when the number of red dots is 3, the live pig's body length range is 80-90 cm; when the number of red dots is 2, the live pig's body length range is 90-10 0cm; when the number of red dots is 1, the body length of the pig ranges from 100-110cm, and then the claim amount corresponding to the body length is determined according to the body length of the pig. For example, if the body length of the pig is less than 80cm, the claim amount is 800 yuan, if the body length of the pig is 80-90cm, the claim amount is 1000 yuan, if the body length of the pig is 90-100cm, the claim amount is 1200 yuan, and if the body length of the pig is 100-110cm, the claim amount is 1400 yuan.
[0139] The embodiment of the present invention provides an insurance claim method, which can determine the claim amount based on the information of the properties to be detected of the target object to be detected. Since there is no need to manually calculate the claim amount for each target object separately, the claim amount can be obtained quickly.
[0140] Embodiment 4
[0141] An embodiment of the present application provides a method for training a target recognition model based on the method for determining the attribute information of the target object provided in the above embodiments.
[0142] The executor of the method may be any computing device that can implement the method, such as a server, a mobile phone, a personal computer, a smart wearable device, a smart robot, and the like.
[0143] The different steps of the method may be implemented by the same execution subject or by different execution subjects. The embodiment of the present application does not limit the execution subject used to implement the method.
[0144] In addition, the execution order of different steps is not limited in the embodiment of the present application. When using the method provided in the embodiment of the present application, the execution order of different steps can be adjusted according to actual needs.
[0145] For ease of description, the method provided in the embodiment of the present application is described in detail below by taking a model training device as the executor of the method as an example.
[0146] The training method of the target recognition model may specifically include: Figure 4 The following steps are shown:
[0147] Step S41: obtaining a sample image data set, wherein a single sample image contains multiple target objects and target reference marks;
[0148] It should be noted that the target object and the target reference mark have been described in the first and second embodiments.
[0149] Step S42: Input the sample image data set into the initial recognition model, and use the position information of the first circumscribed rectangular frame of each target object in the multiple target objects, the category information of the first circumscribed rectangular frame, the position information of the second circumscribed rectangular frame of the target reference mark, and the category information of the second circumscribed rectangular frame as model outputs to train the initial recognition model to obtain a trained target recognition model.
[0150] It should be noted that the position information of the first circumscribed rectangular frame, the category information of the first circumscribed rectangular frame, the position information of the second circumscribed rectangular frame of the target reference mark, and the category information of the second circumscribed rectangular frame have been described in detail in the second embodiment.
[0151] Before model training, in order to ensure the compatibility of the layout equipment of the trained model with the initial model, so as to ensure better performance of the trained target recognition model, the following operations need to be performed:
[0152] Determine a device type of a device running the initial recognition model, and determine a type of the initial recognition model according to the device type;
[0153] If the types of the initial recognition model include yolov5s and yolov5x, then according to the device type, the type of the initial recognition model is determined, including:
[0154] If the device type is a terminal device and the model recognition efficiency needs to be improved, the type of the initial recognition model is determined to be yolov5s; if the device type is a server and the accuracy of the recognition model needs to be guaranteed, the type of the initial recognition model is determined to be yolov5x.
[0155] In the process of model training, the parameters of the model can be adjusted by detecting the recognition results. For example, if the recognition results have repetitions exceeding the threshold, the model accuracy can be improved by adjusting the intersection-over-union ratio threshold, confidence threshold and other parameters.
[0156] The device type may be a mobile device terminal or a server.
[0157] By adopting the above model training method, the trained target recognition model can have higher recognition accuracy and faster recognition speed.
[0158] Embodiment five:
[0159] The method is executed by the client. The following describes how the method provided by the embodiment of the present invention is applied in practice in combination with actual scenarios.
[0160] See also Figure 5 , is a schematic diagram of an implementation flow of a method for determining attribute information of a target provided in an embodiment of the present application. The process specifically includes the following steps:
[0161] S51, receiving an image to be recognized.
[0162] The image to be identified can be selected from the terminal's gallery and photo library and transmitted to the terminal, or connected to a camera device to transmit the image to be identified captured by the camera device to the terminal.
[0163] S52, based on the received image to be recognized, the image to be recognized is recognized according to the fast recognition model or the precise recognition mode selected by the user on the client.
[0164] Among them, the client has two recognition modes, namely the fast recognition model and the precise recognition mode;
[0165] If the user selects the fast recognition model, the user is required to adaptively adjust the width of the cropping frame to be adjusted according to the curvature of the white line reference mark, so that the cropping frame does not contain adjacent red dot reference marks, and finally in the cropped image, each cropping frame contains only one target to be recognized (for example, a pig) and no more than a preset number of red dot reference marks that are adapted to the posture and position of the pig;
[0166] Among them, if the user selects the precise recognition mode, the user is required to set the cropping coordinates according to the curvature of the white line reference mark in the image and determine the cropping frame size so that the cropping frame contains four adjacent red dot reference marks or contains a live pig and no more than a preset number of red dot reference marks.
[0167] S53, displays the pig body length data and the corresponding claim amount.
[0168] Based on the above content, the present embodiment is used to identify the image to be identified, and the specific attribute information of the newborn pig can be identified based on different recognition modes. Therefore, the problem of how to automatically identify the specific attribute information of the newborn pig based on the captured image in the prior art is solved. Based on this method, the recognition efficiency and accuracy can be improved.
[0169] Embodiment 6
[0170] The above is a method for determining the attribute information of a target object provided by an embodiment of the present invention. Based on the same idea, an embodiment of the present invention also provides a device 60 for determining the attribute information of a target object. Figure 6 shown.
[0171] The device for determining the attribute information of the target object includes: an acquisition module 61, an attribute information acquisition module 62 and a determination module 63, wherein:
[0172] An acquisition module 61, used for acquiring a target image;
[0173] The attribute information acquisition module 62 is used to acquire information on the specified attributes of the target reference mark in a specific image area of the target image based on the target image; wherein the specific image area is an image area that meets a preset association requirement with the posture of the target object to be detected in the target image; the association requirement is set based on the attribute to be detected of the target object to be detected and the posture that may exist in the target image of the target object to be detected;
[0174] The determination module 63 is used to determine the information of the attribute to be measured of the target object to be detected based on the information of the designated attribute of the target reference mark and the mapping relationship between the preset information of the designated attribute of the reference mark and the information of the attribute to be measured.
[0175] In one implementation, the attribute information acquisition module includes:
[0176] The target recognition submodule 621 is used to recognize the target image using a target recognition model to identify whether the target reference mark exists in the specific image area.
[0177] The attribute information determination submodule 622 determines information of a specified attribute of the target reference mark according to the recognition result.
[0178] Among them, the target recognition model is trained by using a sample image containing a target object and a target reference mark as a model input, and using the position information of the first circumscribed rectangular frame of each target object in the target, the category information of the first circumscribed rectangular frame, the position information of the second circumscribed rectangular frame of the target reference mark, and the category information of the second circumscribed rectangular frame as model output.
[0179] In one implementation, the attribute information determination submodule includes:
[0180] The cropping unit 6221 is used to crop the target image using a preset image cropping strategy to obtain a cropped image that includes an area where a single target object to be detected is located and a corresponding specific image area.
[0181] The attribute information acquisition unit 6222 is used to acquire, based on the cropped images, information on specified attributes of the target reference markers in the specific image areas respectively contained in the cropped images.
[0182] In one implementation, the cropping unit includes:
[0183] The first position information determining subunit 62221 is used to determine the position information of the specific image area corresponding to each of the target objects to be detected based on the position information of each of the target objects to be detected in the target image, the posture of the target object to be detected and the association requirement, if the target reference mark is recognized to exist in the target image and the target image contains multiple target objects to be detected;
[0184] The first cropping subunit 62222 is used to crop, from the target image, cropped images containing the area where a single target object to be detected is located and the corresponding specific image area based on the position information of each target to be detected and the position information of each specific image area.
[0185] In one implementation, the cropping unit includes:
[0186] The second position information determining subunit 62223 is used to determine the position information of each specific image area according to a preset distribution rule of multiple target reference marks if the target reference mark is identified to exist in the target image.
[0187] The second cropping subunit 62224 is used to crop, from the target image, cropped images that respectively include an area where a single target object to be detected is located and a corresponding specific image area according to position information of each specific image area.
[0188] An embodiment of the present invention provides a device for determining attribute information of a target, wherein an acquisition module 21 acquires information of specified attributes of a target reference mark in a specific image area of the target image, and then an attribute information acquisition module 22 can acquire information of specified attributes of the target reference mark, as well as a mapping relationship between information of the specified attributes of a preset reference mark and information of the attribute to be measured. Finally, a determination module 23 determines information of the attribute to be measured of the target object to be detected, thereby solving the problem of not being able to automatically identify information of specific attributes of live pigs based on captured images.
[0189] Embodiment 7
[0190] The above is an insurance claim settlement method provided by an embodiment of the present invention. Based on the same idea, an insurance claim settlement device 70 is also provided by an embodiment of the present invention. Figure 7 shown.
[0191] The insurance claim settlement device comprises: a module 71 for acquiring attribute information to be measured and a module 72 for determining the claim settlement amount, wherein:
[0192] The property information acquisition module 71 is used to acquire the property information of the target object to be detected;
[0193] The claim amount determination module 72 is used to determine the claim amount based on the information of the attribute to be detected of the target object to be detected; wherein the target object to be detected is livestock; and the attribute to be detected includes any one of body length and weight.
[0194] An embodiment of the present invention provides an insurance claims device, wherein a module 71 for acquiring information on attributes to be measured can acquire information on attributes of a target object to be detected, and a claim amount determination module 72 is used to determine the claim amount. Since there is no need to manually calculate the claim amount for each target object separately, the claim amount can be obtained quickly.
[0195] Embodiment 8
[0196] The above is a method for training a target recognition model provided by an embodiment of the present invention. Based on the same idea, an embodiment of the present invention also provides a training device 80 for a target recognition model, such as Figure 8 shown.
[0197] The sample image data set acquisition module 81 is used to acquire a sample image data set, wherein a single sample image contains a plurality of target objects to be detected and target reference marks corresponding to information of specified attributes of the reference marks;
[0198] The training module 82 is used to input the sample image data set into the initial recognition model for training to obtain a trained target recognition model.
[0199] An embodiment of the present invention provides a training device for a target recognition model, a sample image data set acquisition module 81, which is used to acquire a sample image data set, and a training module 82, which inputs the sample image data set into an initial recognition model for training to obtain a trained target recognition model. By using the above-mentioned model training device, the trained target recognition model can have higher recognition accuracy and faster recognition speed.
[0200] Embodiment 9
[0201] Fig. 9 A hardware structure diagram of an electronic device for determining attribute information of a target object in various embodiments of the present invention is provided, wherein the electronic device is used to solve the problem of how to automatically identify specific attribute information of live pigs based on captured images, thereby improving recognition efficiency.
[0202] The electronic device 900 for determining the attribute information of the target object includes but is not limited to: a radio frequency unit 901, a network module 902, an audio output unit 903, an input unit 904, a sensor 905, a display unit 906, a user input unit 907, an interface unit 908, a memory 909, a processor 910, and a power supply 911. Those skilled in the art can understand that Fig. 9 The structure of the electronic device for determining the attribute information of the target object shown in the figure does not constitute a limitation on the electronic device for determining the attribute information of the target object. The electronic device for determining the attribute information of the target object may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently. In an embodiment of the present invention, the electronic device for determining the attribute information of the target object includes but is not limited to a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted terminal, a wearable device, and a pedometer.
[0203] Among them, the processor 910 is used to obtain a target image; based on the target image, obtain information on specified attributes of a target reference mark in a specific image area of the target image; wherein the specific image area is an image area that meets a preset association requirement with the posture of a target object to be detected in the target image; the association requirement is set based on the attributes to be measured of the target object to be detected and the possible postures of the target object to be detected in the target image; based on the information on the specified attributes of the target reference mark, and the mapping relationship between the information on the specified attributes of the preset reference mark and the information on the attributes to be measured, determine the information on the attributes to be measured of the target object to be detected.
[0204] In one implementation, the processor 910 is also used to obtain information on specified attributes of a target reference marker in a specific image area of the target image based on the target image, and use a target recognition model to recognize the target image to identify whether there is a target reference marker in the specific image area; based on the recognition result, determine the information on the specified attributes of the target reference marker; wherein the target recognition model is trained using a sample image containing a target object and a target reference marker as a model input, and using position information of a first bounding rectangular frame of each target object in the target, category information of the first bounding rectangular frame, position information of a second bounding rectangular frame of the target reference marker, and category information of the second bounding rectangular frame as model outputs.
[0205] In one implementation, the processor 910 is also used to determine the information of the specified attributes of the target reference mark based on the recognition result, and use a preset image cropping strategy to crop the target image to obtain cropped images that respectively contain the area where a single target object to be detected is located and the corresponding specific image area; based on the cropped images, the information of the specified attributes of the target reference mark in the specific image areas respectively contained in each cropped image is obtained.
[0206] In one implementation, the processor 910 is also used to adopt a preset image cropping strategy to crop the target image to obtain cropped images that respectively contain the area where a single target object to be detected is located and the corresponding specific image area. If a target reference mark is identified in the target image and the target image contains multiple target objects to be detected, then based on the position information of each target object to be detected in the target image, the posture of the target object to be detected and the association requirements, the position information of the specific image area corresponding to each target to be detected is determined; based on the position information of each target to be detected and the position information of each specific image area, cropped images that respectively contain the area where a single target object to be detected is located and the corresponding specific image area are cropped from the target image.
[0207] In one implementation, the processor 910 is also used to adopt a preset image cropping strategy to crop the target image to obtain cropped images that respectively contain the area where a single target object to be detected is located and the corresponding specific image area. If a target reference mark is identified in the target image and the target image contains multiple target objects to be detected, then based on the position information of each target object to be detected in the target image, the posture of the target object to be detected and the association requirements, the position information of the specific image area corresponding to each target to be detected is determined; based on the position information of each target to be detected and the position information of each specific image area, cropped images that respectively contain the area where a single target object to be detected is located and the corresponding specific image area are cropped from the target image.
[0208] In one implementation, the processor 910 is also used to crop the target image using a preset image cropping strategy to obtain cropped images that respectively contain an area where a single target object to be detected is located and a corresponding specific image area. If a target reference mark is identified as existing in the target image, the position information of each specific image area is determined according to a preset distribution rule of multiple target reference marks; based on the position information of each specific image area, cropped images that respectively contain an area where a single target object to be detected is located and a corresponding specific image area are cropped from the target image.
[0209] In one implementation, the processor 910 is also used for target reference marks, including lines; then, from the target image, cropped images are cropped that respectively contain the area where a single target object to be detected is located and the corresponding specific image area, and the target image is cropped according to the curvature of the line and the preset correlation between the curvature of the line and the size of the cropped image to obtain cropped images that respectively contain the area where a single target object to be detected is located and the corresponding specific image area.
[0210] An embodiment of the present invention provides an electronic device for determining the attribute information of a target object. Based on the target image, information on the specified attributes of a target reference mark in a specific image area of the target image is obtained. Further, based on the information on the specified attributes of the target reference mark and a mapping relationship between the information on the specified attributes of a preset reference mark and the information on the attributes to be measured, information on the attributes to be measured of the target object to be detected can be determined. Ultimately, the problem of not being able to automatically identify information on specific attributes of live pigs based on captured images is solved.
[0211] It should be understood that in the embodiment of the present invention, the radio frequency unit 901 can be used for receiving and sending signals during information transmission or calls. Specifically, after receiving downlink data from the base station, it is sent to the processor 910 for processing; in addition, the uplink data is sent to the base station. Generally, the radio frequency unit 901 includes but is not limited to an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, etc. In addition, the radio frequency unit 901 can also communicate with the network and other electronic devices that determine the attribute information of the target object through the wireless communication system.
[0212] The electronic device whose attribute information of the target object is determined provides the user with wireless broadband Internet access through the network module 902, such as helping the user to send and receive emails, browse web pages and access streaming media.
[0213] The audio output unit 903 can convert the audio data received by the RF unit 901 or the network module 902 or stored in the memory 909 into an audio signal and output it as sound. Moreover, the audio output unit 903 can also provide an audio output related to a specific function performed by the electronic device 900 according to the determination of the attribute information of the target object (for example, a call signal reception sound, a message reception sound, etc.). The audio output unit 903 includes a speaker, a buzzer, a receiver, etc.
[0214] The input unit 904 is used to receive audio or video signals. The input unit 904 may include a graphics processor (GPU) 9041 and a microphone 9042, and the graphics processor 9041 processes the image data of a static picture or video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The processed image frame can be displayed on the display unit 906. The image frame processed by the graphics processor 9041 can be stored in the memory 909 (or other storage medium) or sent via the radio frequency unit 901 or the network module 902. The microphone 9042 can receive sound and can process such sound into audio data. The processed audio data can be converted into a format output that can be sent to a mobile communication base station via the radio frequency unit 901 in the case of a telephone call mode.
[0215] The electronic device 900 for determining the attribute information of the target object also includes at least one sensor 905, such as a light sensor, a motion sensor and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor, wherein the ambient light sensor can adjust the brightness of the display panel 9051 according to the brightness of the ambient light, and the proximity sensor can turn off the display panel 9051 and / or the backlight when the electronic device 900 for determining the attribute information of the target object is moved to the ear. As a kind of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in each direction (generally three axes), and can detect the magnitude and direction of gravity when stationary, which can be used to identify the electronic device posture (such as horizontal and vertical screen switching, related games, magnetometer posture calibration) for determining the attribute information of the target object, vibration recognition related functions (such as pedometer, knocking), etc.; the sensor 905 can also include a fingerprint sensor, a pressure sensor, an iris sensor, a molecular sensor, a gyroscope, a barometer, a hygrometer, a thermometer, an infrared sensor, etc., which will not be repeated here.
[0216] The display unit 906 is used to display information input by the user or information provided to the user. The display unit 906 may include a display panel 9051, which may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), etc.
[0217] The user input unit 907 can be used to receive input digital or character information, and generate key signal input related to user settings and function control of electronic devices that determine the attribute information of the target object. Specifically, the user input unit 907 includes a touch panel 9071 and other input devices 9072. The touch panel 9071, also known as a touch screen, can collect user touch operations on or near it (such as operations performed by users using any suitable objects or accessories such as fingers, styluses, etc. on the touch panel 9071 or near the touch panel 9071). The touch panel 9071 may include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the processor 910, receives the command sent by the processor 910 and executes it. In addition, the touch panel 9071 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch panel 9071, the user input unit 907 may also include other input devices 9072. Specifically, other input devices 9072 may include but are not limited to physical keyboards, function keys (such as volume control keys, switch keys, etc.), trackballs, mice, and joysticks, which are not described in detail here.
[0218] Further, the touch panel 9071 may be covered on the display panel 9061. When the touch panel 9071 detects a touch operation on or near it, it is transmitted to the processor 910 to determine the type of the touch event, and then the processor 910 provides a corresponding visual output on the display panel 9051 according to the type of the touch event. The touch panel 9071 and the display panel 9051 are two independent components to implement the input and output functions of the electronic device for determining the attribute information of the target object. However, in some embodiments, the touch panel 9071 and the display panel 9051 can be integrated to implement the input and output functions of the electronic device for determining the attribute information of the target object, which is not limited here.
[0219] The interface unit 908 is an interface for connecting an external device to the electronic device 900 for determining the attribute information of the target object. For example, the external device may include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, an audio input / output (I / O) port, a video I / O port, a headphone port, etc. The interface unit 908 may be used to receive input (e.g., data information, power, etc.) from an external device and transmit the received input to one or more elements within the electronic device 900 for determining the attribute information of the target object or may be used to transmit data between the electronic device 900 for determining the attribute information of the target object and an external device.
[0220] The memory 909 can be used to store software programs and various data. The memory 909 can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area can store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory 909 can include a high-speed random access memory, and can also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0221] The processor 910 is the control center of the electronic device for determining the attribute information of the target object. It uses various interfaces and lines to connect various parts of the electronic device for determining the attribute information of the entire target object. By running or executing the software program and / or module stored in the memory 909, and calling the data stored in the memory 909, the electronic device for determining the attribute information of the target object performs various functions and processes data, thereby monitoring the electronic device for determining the attribute information of the target object as a whole. The processor 910 may include one or more processing units; preferably, the processor 910 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 910.
[0222] The electronic device 900 for determining the attribute information of the target object may also include a power supply 911 (such as a battery) for supplying power to each component. Preferably, the power supply 911 may be logically connected to the processor 910 through a power management system, thereby implementing functions such as charging, discharging, and power consumption management through the power management system.
[0223] Preferably, an embodiment of the present invention also provides an electronic device for determining the attribute information of a target object, including a processor 910, a memory 909, and a computer program stored in the memory 909 and executable on the processor 910. When the computer program is executed by the processor 910, each process of the method embodiment for determining the attribute information of the target object described above is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be described here.
[0224] Embodiment 10
[0225] The embodiment of the present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, each process of the method embodiment for determining the attribute information of the target object is implemented, and the same technical effect can be achieved. To avoid repetition, it is not repeated here. The computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0226] An embodiment of the present invention provides a computer-readable storage medium, which obtains information on specified attributes of a target reference marker in a specific image area of the target image based on the target image, and further determines information on the attributes to be measured of the target object to be detected based on the information on the specified attributes of the target reference marker and a mapping relationship between the information on the specified attributes of a preset reference marker and the information on the attributes to be measured. Ultimately, the problem of not being able to automatically identify information on specific attributes of live pigs based on captured images is solved.
[0227] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0228] The present invention is described with reference to the flowchart and / or block diagram of the method, device (system), and computer program product according to the embodiment of the present invention. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the process and / or box in the flowchart and / or block diagram can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce a device for implementing the functions specified in one or more processes in the flowchart and / or one or more boxes in the block diagram.
[0229] These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device that implements the functions specified in one or more processes in the flowchart and / or one or more boxes in the block diagram.
[0230] These computer program instructions may also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, whereby the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one or more processes in the flowchart and / or one or more boxes in the block diagram.
[0231] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0232] The memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.
[0233] Computer-readable media include permanent and non-permanent, removable and non-removable media that can be used to store information by any method or technology. Information can be computer-readable instructions, data structures, modules of programs or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. According to the definition in this article, computer-readable media does not include temporary computer-readable media (transitory media), such as modulated data signals and carrier waves.
[0234] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0235] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0236] The above description is only an embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent substitution, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of the claims of the present invention.
Claims
1. A method for determining attribute information of a target object, characterized in that: The method comprises: Get the target image; Based on the target image, information on the specified attributes of the target reference mark in a specific image area of the target image is obtained; wherein the specific image area is an image area that meets a preset association requirement with the posture of the target object to be detected in the target image; the association requirement is set based on the attributes to be detected of the target object to be detected and the postures that may exist in the target image of the target object to be detected; Determine the information of the attribute to be measured of the target object to be detected based on the information of the designated attribute of the target reference mark and the mapping relationship between the information of the designated attribute of the preset reference mark and the information of the attribute to be measured; The process of determining the specific image area includes: When the reference mark is a dotted horizontal line and is set to be parallel to the X-axis, in the process of placing the target object, if the head and tail of the target object are used as the reference line, the target object is placed in the specific area of the reference mark in a manner such that the reference line of the target object is kept horizontal with the Y-axis. At this time, the specific area is represented as an area formed by taking the position above the head of the target object to the upper boundary of the target image as the length of the specific area and taking the width of the target object as the width of the specific area; When the reference mark is a dotted horizontal line and is set to be parallel to the Y-axis, during the process of placing the target object, if the head and tail of the target object are used as the baseline, the target object is placed in a specific area of the reference mark in such a way that the baseline of the target object is kept horizontal with the X-axis. At this time, the specific area is represented by the position above the head of the target object to the right side boundary of the target image as the length of the specific area, and the width of the target object as the width of the specific area.
2. The method according to claim 1, characterized in that Based on the target image, obtaining information of a specified attribute of a target reference mark in a specific image area of the target image includes: Using a target recognition model to recognize the target image, so as to identify whether the target reference mark exists in the specific image area; Determining information of a specified attribute of the target reference mark according to the recognition result; Among them, the target recognition model is trained by using a sample image containing a target object and a target reference mark as a model input, and using the position information of the first circumscribed rectangular box of each target object in the target, the category information of the first circumscribed rectangular box, the position information of the second circumscribed rectangular box of the target reference mark, and the category information of the second circumscribed rectangular box as model output.
3. The method according to claim 2, characterized in that According to the recognition result, information of the specified attribute of the target reference mark is determined, including: Using a preset image cropping strategy, the target image is cropped to obtain a cropped image containing a region where a single target object to be detected is located and a corresponding specific image region; Based on the cropped images, information on designated attributes of target reference marks in specific image regions respectively included in the cropped images is respectively acquired.
4. The method according to claim 3, characterized in that: The target image is cropped using a preset image cropping strategy to obtain cropped images containing the region where the single target object to be detected is located and the corresponding specific image region, including: If it is recognized that the target reference mark exists in the target image, and the target image contains a plurality of the target objects to be detected, then based on the position information of each of the target objects to be detected in the target image, the posture of the target object to be detected, and the association requirement, determine the position information of the specific image area corresponding to each of the target objects to be detected; Based on the position information of each of the targets to be detected and the position information of each of the specific image regions, cropped images containing the region where a single target object to be detected is located and the corresponding specific image region are cropped from the target image.
5. The method according to claim 3, characterized in that: The target image is cropped using a preset image cropping strategy to obtain cropped images containing the region where the single target object to be detected is located and the corresponding specific image region, including: If the target reference mark is identified to exist in the target image, the position information of each specific image area is determined according to a preset distribution rule of multiple target reference marks; According to the position information of each specific image area, cropped images respectively including the area where a single target object to be detected is located and the corresponding specific image area are cropped from the target image.
6. The method according to claim 4 or 5, characterized in that: The target reference mark includes a line; then, Cropping out a cropped image containing a region where a single target object to be detected is located and a corresponding specific image region from the target image, including: According to the curvature of the line and the preset correlation between the curvature of the line and the size of the cropped image, the target image is cropped to obtain a cropped image containing the area where a single target object to be detected is located and the corresponding specific image area.
7. The method according to claim 2, characterized in that The target recognition model is obtained by the following steps: Acquire a sample image data set, wherein a single sample image contains multiple target objects and target reference marks; The sample image data set is input into an initial recognition model, and the initial recognition model is trained using the position information of the first circumscribed rectangular frame of each target object among the multiple target objects, the category information of the first circumscribed rectangular frame, the position information of the second circumscribed rectangular frame of the target reference marker, and the category information of the second circumscribed rectangular frame as model outputs to obtain a trained target recognition model.
8. An insurance claim settlement method based on the method for determining the attribute information of a target object according to claim 1, characterized in that: include: Obtain information about the properties of the target object to be detected; The claim amount is determined based on the information of the attribute to be detected of the target object to be detected; wherein the target object to be detected is livestock; and the attribute to be detected includes at least one of body length and weight.
9. A device for determining attribute information of a target, characterized in that: The device comprises: An acquisition module, used for acquiring a target image; An attribute information acquisition module is used to acquire information on a specified attribute of a target reference mark in a specific image area of the target image based on the target image; wherein the specific image area is an image area that meets a preset association requirement with the posture of the target object to be detected in the target image; the association requirement is set based on the attribute to be detected of the target object to be detected and the posture that may exist in the target image of the target object to be detected; A determination module, configured to determine the information of the attribute to be measured of the target object to be detected based on the information of the designated attribute of the target reference mark and a mapping relationship between the information of the designated attribute of the preset reference mark and the information of the attribute to be measured; The process of determining the specific image area includes: When the reference mark is a dotted horizontal line and is set to be parallel to the X-axis, in the process of placing the target object, if the head and tail of the target object are used as the reference line, the target object is placed in the specific area of the reference mark in a manner such that the reference line of the target object is kept horizontal with the Y-axis. At this time, the specific area is represented as an area formed by taking the position above the head of the target object to the upper boundary of the target image as the length of the specific area and taking the width of the target object as the width of the specific area; When the reference mark is a dotted horizontal line and is set to be parallel to the Y-axis, during the process of placing the target object, if the head and tail of the target object are used as the baseline, the target object is placed in a specific area of the reference mark in such a way that the baseline of the target object is kept horizontal with the X-axis. At this time, the specific area is represented by the position above the head of the target object to the right side boundary of the target image as the length of the specific area, and the width of the target object as the width of the specific area.
10. The device according to claim 9, characterized in that The device also includes: A sample image data set acquisition module is used to acquire a sample image data set, wherein a single sample image contains multiple target objects and target reference marks; A training module is used to input the sample image data set into an initial recognition model, and use the position information of the first circumscribed rectangular frame of each target object among the multiple target objects, the category information of the first circumscribed rectangular frame, the position information of the second circumscribed rectangular frame of the target reference mark, and the category information of the second circumscribed rectangular frame as model outputs to train the initial recognition model to obtain a trained target recognition model.
11. An insurance claim settlement device based on the device for determining the attribute information of a target object according to claim 9, characterized in that: include: The module for acquiring the information of the attribute to be tested is used to acquire the information of the attribute to be tested of the target object to be tested; The claim amount determination module is used to determine the claim amount based on the information of the attribute to be detected of the target object to be detected; wherein the information of the attribute to be detected of the target object to be detected is livestock, and the attribute to be detected includes at least one of body length and weight.
12. An electronic device, characterized in that: The invention comprises a processor, a memory and a computer program stored in the memory and executable on the processor, wherein when the computer program is executed by the processor, the steps of the method for determining the attribute information of the target object according to any one of claims 1 to 7 are implemented.
13. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for determining the attribute information of the target object according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Length acquisition method and device, insurance claim settlement system, medium and electronic equipment
CN110175503A
Animal body online claim settlement method and apparatus based on monocular camera, and storage medium
WO2021139494A1