WO2022143562A1 - Cargo container state detection method and apparatus - Google Patents
Cargo container state detection method and apparatus Download PDFInfo
- Publication number
- WO2022143562A1 WO2022143562A1 PCT/CN2021/141762 CN2021141762W WO2022143562A1 WO 2022143562 A1 WO2022143562 A1 WO 2022143562A1 CN 2021141762 W CN2021141762 W CN 2021141762W WO 2022143562 A1 WO2022143562 A1 WO 2022143562A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- cargo box
- confidence level
- state
- container
- image
- Prior art date
Links
- 238000001514 detection method Methods 0.000 title claims abstract description 32
- 238000000034 method Methods 0.000 claims abstract description 74
- 238000012545 processing Methods 0.000 claims abstract description 52
- 238000012549 training Methods 0.000 claims description 40
- 230000008569 process Effects 0.000 claims description 25
- 238000010606 normalization Methods 0.000 claims description 22
- 230000002159 abnormal effect Effects 0.000 claims description 19
- 238000007781 pre-processing Methods 0.000 claims description 19
- 230000008859 change Effects 0.000 claims description 14
- 230000005856 abnormality Effects 0.000 claims description 12
- 238000013519 translation Methods 0.000 claims description 8
- 238000005286 illumination Methods 0.000 claims description 6
- 238000010586 diagram Methods 0.000 description 12
- 230000006870 function Effects 0.000 description 12
- 238000009966 trimming Methods 0.000 description 8
- 238000013527 convolutional neural network Methods 0.000 description 5
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 230000009466 transformation Effects 0.000 description 3
- 235000002566 Capsicum Nutrition 0.000 description 2
- 239000006002 Pepper Substances 0.000 description 2
- 241000722363 Piper Species 0.000 description 2
- 235000016761 Piper aduncum Nutrition 0.000 description 2
- 235000017804 Piper guineense Nutrition 0.000 description 2
- 235000008184 Piper nigrum Nutrition 0.000 description 2
- 238000013528 artificial neural network Methods 0.000 description 2
- 238000004891 communication Methods 0.000 description 2
- 230000007613 environmental effect Effects 0.000 description 2
- 150000003839 salts Chemical class 0.000 description 2
- 238000012706 support-vector machine Methods 0.000 description 2
- 238000002759 z-score normalization Methods 0.000 description 2
- 230000003749 cleanliness Effects 0.000 description 1
- 238000007796 conventional method Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000004880 explosion Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 238000003384 imaging method Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 229920001690 polydopamine Polymers 0.000 description 1
- 239000002893 slag Substances 0.000 description 1
- 210000000857 visual cortex Anatomy 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/0002—Inspection of images, e.g. flaw detection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
- G06N3/09—Supervised learning
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/21—Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
- G06F18/214—Generating training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/045—Combinations of networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/11—Region-based segmentation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/20—Image preprocessing
- G06V10/25—Determination of region of interest [ROI] or a volume of interest [VOI]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/82—Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10004—Still image; Photographic image
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20081—Training; Learning
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20084—Artificial neural networks [ANN]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20092—Interactive image processing based on input by user
- G06T2207/20104—Interactive definition of region of interest [ROI]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/30—Subject of image; Context of image processing
- G06T2207/30168—Image quality inspection
Definitions
- the present disclosure relates to the field of cargo box state detection, and in particular, to a method and device for detecting the state of a cargo box.
- the muck trucks will be overloaded and the muck will be scattered during the transportation process. If they cannot be found in time, it will not only affect the cleanliness of the road, but also cause many hidden safety hazards.
- the first time difference and the second time difference are determined respectively by setting the first radar and the second radar, and the microcontroller determines the first side cover and the second time difference according to the first time difference and the second time difference.
- the airtightness of the side roof can identify whether the roof of the muck is effectively closed, and reduce the environmental problems caused by the ineffective closure of the roof of the muck.
- it can be identified whether the roof cover of the muck truck is effectively closed, but it cannot be identified whether the cargo box of the muck truck is loaded with goods; and the use of laser radar in this method is costly.
- the embodiments of the present disclosure provide a method and device for detecting the state of a cargo box, so as to at least solve the technical problem that the method for detecting the state of a cargo box in the related art cannot detect whether goods are loaded in the cargo box.
- a method for detecting the state of a cargo box including: acquiring an image of the cargo box; processing the image of the cargo box by using a first network model to obtain a confidence level of the state of the cargo box; Confidence, determine the status of the cargo box, where the status of the cargo box includes one of the following: the top cover of the cargo box is closed, no cargo is loaded in the cargo box, the amount of cargo loaded in the cargo box meets the preset amount, the camera is abnormal, the cargo box is abnormal The amount of cargo loaded does not meet the preset amount.
- using the first network model to process the image of the cargo box to obtain the confidence level of the state of the cargo box includes: trimming the image of the cargo box to obtain the image of the target area; preprocessing the image of the target area to obtain the processed image ; Input the processed image into the first network model to obtain the confidence level of the state of the container.
- the confidence level of the state of the cargo box includes: a first confidence level for representing the closure of the top cover of the cargo box, a second confidence level for representing no cargo in the cargo box, and a cargo for representing the cargo loaded in the cargo box.
- the third confidence level is used to represent the abnormality of the camera, and the fifth confidence level is used to represent that the amount of goods loaded in the cargo box does not meet the preset amount.
- using the first network model to process the image of the container to obtain the confidence of the state of the container further comprising: extracting the confidence of the state of the multi-frame container corresponding to the images of the multi-frame container; Enter the second network model to obtain the confidence level of the container state.
- determining the state of the container based on the confidence level of the container state includes: extracting the container corresponding to the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level
- the state is the state of the container; or, extracting the state of the container whose first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level are greater than the preset threshold is the container state; or, extracting the first The highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level, and the container state corresponding to the one greater than the preset threshold value is the container state.
- determining the status of the container based on the confidence of the status of the container includes: determining the status of the container based on the confidence of the status of the container and a preset rule, wherein the preset rule is used to represent the priority of the confidence of the status of the container .
- determining the state of the container based on the confidence of the state of the container includes: judging whether the fourth confidence is greater than a fifth preset value; if the fourth confidence is greater than the fifth preset, determining that the state of the container is a camera Abnormal; if the fourth confidence level is less than or equal to the fifth preset value, it is determined whether the first confidence level is greater than the second preset value; if the first confidence level is greater than the second preset value, it is determined that the state of the container is the top of the container The cover is closed; if the first confidence level is less than or equal to the second preset value, it is determined whether the second confidence level is greater than the third preset value; if the second confidence level is greater than the third preset value, it is determined that the state of the cargo box is a cargo box If the second confidence level is less than or equal to the third preset value, it is determined whether the third confidence level is greater than the fourth preset value; if the third confidence level is greater than the fourth preset value, it is determined that
- the preprocessing includes at least one of the following: scaling processing and normalization processing.
- the method further includes: acquiring an image of an original container; processing the image of the original container to obtain multiple sets of training samples; and using multiple sets of training samples to train an initial model to obtain a first network model.
- processing the original cargo box images to obtain multiple sets of training samples including: performing perturbation processing on the original cargo box images to obtain multiple sets of original cargo box images; trimming multiple sets of original cargo box images to obtain multiple sets of original cargo box images. group target area images; preprocess multiple groups of target area images to obtain multiple groups of training samples.
- the perturbation processing includes at least one of the following: rotation, translation, scaling, noise addition, blurring, illumination change and channel change.
- acquiring the image of the cargo box includes: detecting whether the current light intensity is greater than a first preset value; if the current light intensity is greater than the first preset value, using the first camera to acquire the image of the cargo box; if the current light intensity is less than or equal to If the first preset value is used, the image of the cargo box is obtained by using the second camera.
- the method further includes: adding a normalization layer to the initial layer of the initial model, wherein the normalization layer is used to Group training samples are normalized.
- an apparatus for detecting the state of a cargo box including: an acquiring component, configured to acquire an image of the cargo box; and a processing component, configured to process the image of the cargo box by using a first network model , obtain the confidence of the state of the cargo box; the determining component is configured to determine the state of the cargo box based on the confidence of the state of the cargo box, wherein the state of the cargo box includes one of the following: the top cover of the cargo box is closed, the cargo is not loaded in the cargo box, the cargo box The amount of goods loaded in the container meets the preset amount, the camera is abnormal, and the amount of goods loaded in the container does not meet the preset amount.
- a computer-readable storage medium is also provided, where the computer-readable storage medium includes a stored program, wherein when the program is executed, a device where the computer-readable storage medium is located is controlled to execute the above-mentioned cargo box Status detection method.
- a processor is also provided, and the processor is configured to run a program, wherein the above-mentioned method for detecting the state of a cargo box is executed when the program runs.
- FIG. 1 is a flowchart of a method for detecting the state of a cargo box according to an embodiment of the present disclosure
- FIG. 2 is a schematic diagram of a state of a cargo box with a top cover of the cargo box closed according to an embodiment of the present disclosure
- FIG. 3 is a schematic diagram of the state of a cargo box with no goods loaded in the cargo box according to an embodiment of the present disclosure
- FIG. 4 is a schematic diagram of the state of a cargo box in which the amount of goods loaded in a cargo box meets a preset amount according to an embodiment of the present disclosure
- FIG. 5 is a schematic diagram of the state of a cargo box with an abnormal camera according to an embodiment of the present disclosure
- FIG. 6 is a schematic diagram of an optional method for detecting the state of a cargo box according to an embodiment of the present disclosure
- FIG. 7 is a schematic diagram of another optional method for detecting the state of a cargo box according to an embodiment of the present disclosure.
- FIG. 8 is a schematic diagram of an apparatus for detecting the state of a cargo box according to an embodiment of the present disclosure.
- an embodiment of a method for detecting the state of a cargo box is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings may be executed in a computer system such as a set of computer-executable instructions, and , although a logical order is shown in the flowcharts, in some cases steps shown or described may be performed in an order different from that herein.
- FIG. 1 is a method for detecting the state of a cargo box according to an embodiment of the present disclosure. As shown in FIG. 1 , the method includes the following steps:
- Step S102 acquiring the image of the cargo box
- Step S104 using the first network model to process the image of the container to obtain the confidence level of the state of the container;
- Step S106 Determine the status of the cargo box based on the confidence level of the status of the cargo box, wherein the status of the cargo box includes one of the following: the top cover of the cargo box is closed, the cargo box is not loaded with goods, and the amount of goods loaded in the cargo box meets a preset amount , The camera is abnormal, and the amount of goods loaded in the cargo box does not meet the preset amount.
- the first network model is used to process the image of the cargo box to obtain the confidence level of the status of the cargo box, and then the status of the cargo box is determined based on the confidence level of the status of the cargo box, thereby realizing the detection
- the cargo box is in the state, it can not only detect whether the top cover of the shipping box is effectively closed, but also detect whether the cargo box is loaded with goods, and detect the capacity of the goods loaded in the cargo box, and the obtained cargo box image does not show the status of the cargo box.
- the camera is abnormal, it can detect the status of the container effectively.
- only a camera is used to realize detection. Compared with the solution of using radar to realize detection in the prior art, the cost is reduced, and the method of detecting the state of the cargo box in the related art can not detect whether the cargo is loaded in the cargo box. question.
- Step S102 acquiring the image of the cargo box.
- the image of the cargo box in the above steps may be an image of a cargo box of a muck truck, an image of a cargo box of a truck, or an image of a cargo box placed in a warehouse, which is not limited herein.
- the image of the cargo box may be an image of the cargo box obtained by a common camera, or may be an image of an infrared cargo box obtained by an infrared camera.
- the images obtained by ordinary cameras are dim and blurred, and the quality is low, which will affect the accuracy of subsequent detection of the state of the container. Therefore, infrared cameras can be used to collect images in an environment with insufficient light, and high-quality images can be collected in the early stage. The image ensures that the subsequent detection of the condition of the cargo box is realized with high precision.
- the acquired image of the cargo box may be the current image of the cargo box, or may be the image of the historically stored cargo box.
- the image of the cargo box in the above steps can be acquired by a camera mounted on the cargo box, or acquired by a camera mounted on the vehicle body. It should be noted that the camera can acquire an image of the container at a fixed position, and the image of the container can display the state of the top cover of the shipping container and the state of the goods loaded in the container.
- an image of the current cargo box of the muck truck may be acquired through a camera installed on the muck truck.
- Step S104 using the first network model to process the image of the container to obtain the confidence level of the state of the container.
- the first network model in the above steps can be a CNN (Convolution neural network, convolutional neural network), and the first network model can simulate the visual cortex to decompose and analyze image data.
- CNN Convolution neural network, convolutional neural network
- the first network model of the present application can directly obtain the confidence levels of all the container states, that is, the present application only needs one first network model to obtain the confidence levels of the states of multiple containers according to the container image, thereby increasing the confidence level. to determine the speed at which the status of the container is determined.
- the status of the cargo box may be that the top cover of the cargo box is closed, no goods are loaded in the cargo box, the amount of goods loaded in the cargo box meets the preset amount, the camera is abnormal, and the amount of goods loaded in the cargo box does not meet the preset amount.
- the unloaded goods in the container may refer to the empty container, and the amount of goods loaded in the container that meets the preset amount may mean that the container is fully loaded, the container is overloaded, etc. value to be determined.
- the output of the confidence level of the first network model includes not only the opening and closing status of the top cover of the cargo box, but also the detection of the status of the amount of goods in the cargo box and the status of the camera.
- Confidence also known as reliability and confidence level, can be the probability that the estimated value and the overall parameter are within a certain allowable error range.
- the confidence of the state of the container in the above steps may refer to the probability of each state of the container obtained by analyzing the image of the container through the first network model.
- using the first network model to process the image of the cargo box to obtain the confidence level of the state of the cargo box includes: trimming the image of the cargo box to obtain the image of the target area; preprocessing the image of the target area to obtain the processed image ; Input the processed image into the first network model to obtain the confidence level of the state of the container.
- the target area in the above steps may refer to the ROI (Region of Interest) in the image of the cargo box.
- the identification of the status of the cargo box can be based on the preset interest. area carried out. For example, it may refer to the area where the top cover of the cargo box is located in the cargo box image, which may be determined according to actual detection needs.
- the ROI can be used to trim the image to obtain the target area image; the ROI can be used to specify the target area in the read-in image, so that only the target area image where the container is located can be classified and identified, which can reduce the detection processing time and increase the The detection accuracy can bring convenience to image processing.
- Range range function
- Range is a continuous sequence from the start index to the end index; you can also use the rectangle Rect (rectangle function) to frame, specify the coordinates of the upper left corner of the rectangle Rect and the length and width of the rectangle.
- the above-mentioned preprocessing includes at least one of the following: scaling processing and normalization processing.
- the scaling process in the above steps refers to the process of adjusting the size of the digital image.
- Image scaling requires a trade-off between processing efficiency and the smoothness and clarity of the result. As the size of an image increases, the pixels that make up the image become more visible; conversely, shrinking an image will enhance its smoothness and clarity.
- the selection of the fixed size of the image is based on the actual requirements of the recognition speed and recognition accuracy of the first network model, and the same standard is used in the recognition process for different collected images, so as to ensure that the information output by the network is more accurate.
- the target area image can be scaled to a fixed size: 128*128.
- the normalization processing in the above steps refers to limiting the data to a certain range.
- the normalization process does not change the image information, but it can eliminate the initial invalid effect of the network caused by the singular image, and can prevent the gradient explosion after the image enters the first network model.
- the normalization method can be maximum-minimum normalization, Z-score normalization, function transformation, etc. Among them, maximum-minimum normalization refers to the linear change of the original data; Z-score normalization is based on the mean and standard deviation of the original data. Data normalization performed.
- the image of the cargo box can be cropped through the ROI to obtain the target area, and then the target area is scaled to a fixed size: 128*128, and then the scaled target area is normalized, specifically, the pixels of the target area are The value is subtracted from the mean value of 128, and then divided by the variance of 256. Finally, the processed image is input into the convolutional neural network to obtain the confidence level of the state of the container.
- the above-mentioned confidence level of the state of the container includes: a first confidence level for characterizing the closure of the top cover of the container, a second confidence level for characterizing the unloaded goods in the container, and a second confidence level for characterizing the loaded goods in the container.
- the third confidence level is used to characterize the abnormality of the camera, and the fifth confidence level is used to indicate that the quantity of goods loaded in the cargo box does not meet the preset amount.
- a convolutional neural network can be used to process the current cargo box image, and the output result of the first network model is that the confidence level of the top cover of the cargo box being closed is 80%, and the cargo box is not loaded with goods.
- the confidence level is 5%
- the confidence level of the amount of goods loaded in the container meets the preset amount is 5%
- the confidence level of the camera is abnormal is 5%
- the confidence level of the cargo volume loaded in the container does not meet the preset amount is 5%.
- step S106 the state of the container is determined based on the confidence level of the state of the container.
- the status of the cargo box includes one of the following: the top cover of the cargo box is closed, no cargo is loaded in the cargo box, the amount of goods loaded in the cargo box meets the preset amount, the camera is abnormal, and the amount of goods loaded in the cargo box does not meet the predetermined amount. Set the amount.
- Fig. 2 shows a schematic diagram of the state of the cargo box with the top cover of the cargo box closed
- Fig. 3 shows a schematic diagram of the state of the cargo box with no goods loaded in the cargo box
- Fig. 4 shows that the amount of goods loaded in the cargo box meets the preset amount Schematic diagram of the status of the cargo box
- Figure 5 shows the schematic diagram of the status of the cargo box with an abnormal camera.
- the closing of the top cover of the cargo box means that the cargo box can be normally closed after the loading of goods does not meet the preset amount or the cargo box is not loaded with goods;
- the preset amount is met, the top cover of the cargo box is normally opened, or the amount of goods loaded in the cargo box is too large, so that the top cover of the cargo box cannot be closed normally;
- the abnormality of the camera may be that the camera is blocked or the camera is deflected, resulting in the inability to effectively detect the cargo box. state within.
- determining the state of the container based on the confidence level of the container state includes: extracting the container corresponding to the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level
- the state is the state of the container; or, extracting the state of the container whose first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level are greater than the preset threshold is the container state; or, extracting the first The highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level, and the container state corresponding to the one greater than the preset threshold value is the container state.
- the highest confidence level among the confidence levels of the states of each cargo box output by the first network model may be selected, and the state of the cargo box may be determined to be the container state corresponding to the highest confidence level, so as to ensure the state of the cargo box. accuracy.
- a preset threshold may be set, and when the confidence level is greater than the preset threshold, it is determined that the container state is the container state corresponding to the confidence level, so as to ensure the accuracy of the obtained container state .
- the first confidence level is greater than the second preset value
- the state of the cargo box is determined to be that the top cover of the cargo box is closed
- the second confidence level is greater than the third preset value
- the state of the cargo box is determined to be that no goods are loaded in the cargo box
- the third confidence level is greater than the fourth preset value
- it is determined that the state of the cargo box is that the amount of goods loaded in the cargo box meets the preset amount
- the fourth confidence level is greater than the fifth preset value, it is determined that the state of the cargo box is the camera abnormality
- the fifth confidence level is greater than the sixth preset value, it is determined that the state of the cargo box is that the amount of goods loaded in the cargo box does not meet the preset amount.
- the state of the container may be determined according to the highest confidence level and a preset threshold, and when the confidence level satisfies these two conditions, the state of the container is determined as the state of the container corresponding to the confidence level , to further improve the accuracy of the status of the cargo box.
- determining the status of the container based on the confidence of the status of the container includes: determining the status of the container based on the confidence of the status of the container and a preset rule, wherein the preset rule is used to represent the priority of the confidence of the status of the container .
- the judgment may be made according to the judgment priorities of the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level, and then output the status of the container according to the judgment result.
- the judgment priority may be set by the user, and the judgment priority may also be randomly generated.
- the priority setting can be based on the degree of danger corresponding to the status of the container. For example, if the camera is blocked or faulty, it will not be possible to determine the status of the top cover and the amount of goods. If the top cover cannot be closed normally, it will bring road environment and safety hazards.
- determining the state of the container based on the confidence of the state of the container includes: judging whether the fourth confidence is greater than a fifth preset value; if the fourth confidence is greater than the fifth preset, determining that the state of the container is a camera Abnormal; if the fourth confidence level is less than or equal to the fifth preset value, it is determined whether the first confidence level is greater than the second preset value; if the first confidence level is greater than the second preset value, it is determined that the state of the container is the top of the container The cover is closed; if the first confidence level is less than or equal to the second preset value, it is determined whether the second confidence level is greater than the third preset value; if the second confidence level is greater than the third preset value, it is determined that the state of the cargo box is a cargo box If the second confidence level is less than or equal to the third preset value, it is determined whether the third confidence level is greater than the fourth preset value; if the third confidence level is greater than the fourth preset value, it is determined that
- the order of the priority of the confidence level judgment from high to low is: the fourth confidence level, the first confidence level, the second confidence level, the third confidence level, and the fifth confidence level.
- the first confidence level is greater than the second preset value
- the second confidence level is less than the third preset value
- the third confidence level is less than the fourth preset value
- the fourth confidence level is less than the fifth preset value.
- the fifth confidence level is less than the sixth preset value
- the output container state is that the top cover of the container represented by the first confidence level is closed.
- the preset amount in the above steps can be set by the user according to the capacity of the cargo box.
- the second preset value, the third preset value, the fourth preset value, the fifth preset value, and the sixth preset value may be the same or different, which are not limited herein.
- the first network model is used to process the image of the cargo box to obtain the confidence level of the status of the cargo box, and then the status of the cargo box is determined based on the confidence level of the status of the cargo box, thereby realizing the detection
- the cargo box can not only detect whether the top cover of the shipping box is effectively closed, but also detect whether the cargo box is loaded with goods, and detect the capacity of the loaded goods in the cargo box. Only using the camera to obtain the image of the cargo box can reduce the detection cost. .
- the first network model can be used to analyze the image of the cargo box to obtain the confidence level of the closed top cover of the cargo box, the confidence level of the unloaded goods in the cargo box, and the quantity of goods loaded in the cargo box.
- the confidence level of meeting the preset amount, the confidence level of the camera being abnormal, and the confidence level that the amount of goods loaded in the container does not meet the preset amount can be determined according to the confidence level of various states of the container.
- the state of the shipping box can not only detect Whether the top cover of the cargo box is effectively closed, it can also detect whether the cargo box is loaded with goods, and when the obtained image of the cargo box does not show the status of the cargo box, the abnormality of the camera can be detected, so as to effectively detect the status of the cargo box.
- the present disclosure Compared with the conventional method of using radar to realize detection, the cost is reduced, the performance is stable and the scope of application is wide, which solves the problem that the method of detecting the state of the cargo box in the related art cannot detect the inside of the cargo box. Whether or not to load the goods technically.
- using the first network model to process the image of the container to obtain the confidence of the state of the container further comprising: extracting the confidence of the state of the multi-frame container corresponding to the images of the multi-frame container; Enter the second network model to obtain the confidence level of the container state.
- the present disclosure determines the status of the cargo box based on the confidence results obtained from multi-frame image detection.
- the selection of the number of frames for multi-frame processing is a trade-off between processing efficiency and result quality, which can improve the accuracy of container status detection while maintaining the stability of the detection results.
- the state of the container is continuously detected for 30s, and the multi-frame images within this time period are extracted and entered into the first network model to obtain the corresponding multi-frame container state confidence, and the obtained multi-frame container state confidence is input into the second
- the network model is trained to obtain the confidence level of the final cargo box state, and the above-mentioned second network model may be a support vector machine.
- the method further includes: acquiring an image of an original container; processing the image of the original container to obtain multiple sets of training samples; and using multiple sets of training samples to train an initial model to obtain a first network model.
- the original cargo box image in the above steps can be acquired through a camera, can also be acquired through a network, or can be acquired from a file stored locally, which is not limited here.
- the training samples in the above steps are also the parameters of the initial model. After training, it can be considered that the model system has been established.
- the initial model may be an untrained model or a model that has been trained at least once before.
- the first network model has taken into account the factors of ordinary images and infrared images in the training process. Therefore, the first network model is used to perform recognition based on different types of images to improve the recognition accuracy.
- the first network model when the first network model is trained based on ordinary images and infrared images, respectively, when it is detected that the image of the cargo box is an ordinary image, the first network model can identify the image of the cargo box based on the ordinary image. ; When the detected image of the cargo box is an infrared image, the first network model can recognize the infrared image based on the training demerits of the infrared image. By training two different types of cargo box images, the accuracy of the image recognition of the cargo box can be improved. As well as extending the compatibility of the first network model.
- the first network model in the above steps may be ResNet (Residual Neural Network, residual network).
- processing the original cargo box images to obtain multiple sets of training samples including: performing perturbation processing on the original cargo box images to obtain multiple sets of original cargo box images, wherein the perturbation processing is used to expand the original cargo box images and enhancement; trimming multiple sets of original cargo box images to obtain multiple sets of target area images; preprocessing multiple sets of target area images to obtain multiple sets of training samples.
- the real scene environment information is complex and changeable. In contrast, the amount of training sample data collected is limited. In order to still adapt to the changing environmental scene in actual detection, the present disclosure expands and enhances the original image samples, and enriches the training samples to make them suitable for complex environments. Stronger anti-interference ability.
- rotation, translation, scaling, noise addition, blurring, illumination change, and channel change may be performed on the original cargo box image to obtain multiple sets of original cargo container images, and then multiple sets of original cargo container images can be processed through ROI.
- the box images are cropped to obtain multiple sets of target area images; after the multiple sets of target area images are scaled to a fixed size, the scaled multiple sets of target area images are normalized to obtain multiple sets of training samples.
- perturbation processing may be performed again to obtain more abundant training samples, so that the anti-interference ability of complex environments is stronger.
- the perturbation processing includes at least one of the following: rotation, translation, scaling, noise addition, blurring, illumination change, channel change.
- 0 to 15 left and right rotation operations may be randomly selected for the original cargo box image.
- a translation operation may be performed on the original cargo box image by moving up, down, left, and right by 0 to 50 pixels.
- an image scaling operation of 0.8 to 1.2 may be randomly performed on the original cargo box image.
- Gaussian or salt and pepper noise with a mean value of 0 to 4.0 may be randomly added to the original cargo box image.
- a Gaussian blur with a template of 0 to 9 may be randomly added to the original cargo box image.
- the original container image may be randomly multiplied by a lighting transformation of 0.8 to 1.2 per pixel.
- channels of the original cargo box image may be converted, for example, RGB channels are converted to BRG channels.
- acquiring the image of the cargo box includes: detecting whether the current light intensity is greater than a first preset value; if the current light intensity is greater than the first preset value, using the first camera to acquire the image of the cargo box; if the current light intensity is less than or equal to If the first preset value is used, the image of the cargo box is obtained by using the second camera.
- the first preset value in the above steps can be set by the user based on requirements.
- the first camera can be an RGB camera
- the second camera can be an IR camera
- the RGB camera can acquire images in a light state
- the IR camera is an infrared camera, and can acquire images in a dark state.
- the senor can detect whether the current light intensity is greater than the first preset value; if the current light intensity is greater than the first preset value, it means that the current cargo box is in a lighting state, and an RGB camera can be used Obtain the image of the cargo box; if the current light intensity is less than or equal to the first preset value, it means that the current cargo box is in a dark state, and the IR camera can be used to obtain the image of the cargo box.
- the method further includes: adding a normalization layer to the initial layer of the initial model, wherein the normalization layer is used to Group training samples are normalized.
- a batch normalization layer is added to the initial layer of the first network model to normalize the data.
- the training of the batch normalization layer will gradually eliminate the influence caused by the two image qualities, so that the two images are mapped to the same sample space, which can improve the recognition accuracy of the first network model of the state of the container and the recognition speed.
- the trained first network model can output the confidence level of the state of the container, including: a first confidence level for representing the closure of the top cover of the container, a second confidence level for representing the unloaded goods in the container, and a second confidence level for representing the container.
- the third confidence level for the amount of goods loaded in the container meets the preset amount, the fourth confidence level for indicating an abnormality of the camera, and the fifth confidence level for indicating that the amount of goods loaded in the container does not meet the preset amount.
- the method may include the following steps:
- Step S601 acquiring the image of the muck truck cargo box
- a camera may be selected according to the light intensity to obtain images of the cargo box of the muck truck. If the current light intensity is greater than the first preset value, it means that the current cargo box is in a light state, and the RGB camera can be used to obtain the image of the cargo box; if the current light intensity is less than or equal to the first preset value, it means that the current cargo box is in a dark state Next, the image of the cargo box can be obtained by using the IR camera.
- Step S602 crop the image of the cargo box to obtain the image of the target area
- the cargo box image can be cropped by ROI.
- Step S603 preprocessing the target area image
- the preprocessing can be scaling processing and normalization processing; the target area image can be scaled to a fixed size: 128*128; the pixels of the target area image can be subtracted from the mean value of 128, and then divided by the variance of 256.
- Step S604 sending the preprocessed image of the target area into the CNN network to obtain the confidence level of the state of the container.
- the confidence level of the state of the container includes one of the following: confidence level of the top cover of the container being closed, confidence level of no goods loaded in the container, confidence level of the amount of goods loaded in the container meeting a preset value, confidence level of camera abnormality, and confidence level of the cargo box. The amount of goods loaded in the box does not meet the preset confidence level.
- top cover of the cargo box is closed, it means that the cover of the muck truck is completely closed; no cargo is loaded in the cargo box, the amount of goods loaded in the cargo box meets the preset value, and the amount of cargo loaded in the cargo box does not meet the preset amount, indicating that the slag truck is completely closed.
- the top cover of the dirt truck is open; if the camera is abnormal, it means that the camera is blocked or the camera is deflected, resulting in effective detection.
- Step S605 based on the confidence of the state of the container and the artificially designed logic rule, determine the state of the container of the muck truck.
- the state of the container of the muck truck may be determined based on the confidence level of the state of the container and the signal of the cover plate of the container of the muck truck.
- the confidence level of the state of the container of the multi-frame corresponding to the multi-frame images collected within 30s can be input to the support vector machine and output the confidence level of the final state of the container. According to the above The confidence level of the cargo box status determines whether the cargo box status of the muck truck is not loaded with cargo in the cargo box or whether the amount of cargo loaded in the cargo box meets the preset value.
- the state of the container of the muck truck may be determined based on the confidence level of the state of the container and the transport state of the muck truck.
- the method may include the following steps:
- Step S701 obtaining an image of the original cargo box of the muck truck
- the original cargo box image of the muck truck in the above steps can be obtained through a camera, can also be obtained through a network, and can also be obtained from a file stored locally, which is not limited here.
- a camera can be selected according to the light intensity to obtain the original cargo box image of the muck truck. If the current light intensity is greater than the first preset value, it means that the current cargo box is in the light state, and the RGB camera can be used to obtain the original image of the cargo box; if the current light intensity is less than or equal to the first preset value, it means that the current cargo box is in darkness In this state, the IR camera can be used to obtain the original image of the cargo box.
- Step S702 performing perturbation processing on the original cargo box image to obtain multiple sets of original cargo box images
- rotation, translation, scaling, noise addition, blurring, illumination change, and channel change may be performed on the original cargo box image to obtain multiple sets of original cargo box images.
- 0 to 15 left and right rotation operations may be randomly selected for the original cargo box image.
- the original cargo box image can be moved up, down, left, and right by 0 to 50 pixels in a translation operation.
- an image scaling operation of 0.8 to 1.2 may be randomly performed on the original cargo box image.
- Gaussian or salt and pepper noise with a mean value of 0 to 4.0 can be randomly added to the original cargo box image.
- a Gaussian blur with templates ranging from 0 to 9 can be randomly added to the original cargo box image.
- a lighting transformation of 0.8 to 1.2 can be randomly multiplied per pixel on the original crate image.
- the channels of the original crate image can be transformed, eg, RGB channels to BRG channels.
- Step S703 performing clipping processing on multiple sets of original cargo box images to obtain multiple sets of target area images
- multiple sets of original cargo box images may be cropped through the ROI to obtain multiple sets of target area images.
- Step S704 preprocessing multiple groups of target area images to obtain multiple groups of training samples
- the preprocessing includes scaling and normalization.
- multiple sets of target area images can be scaled to a fixed size: 128*128, and then the pixels of the scaled multiple sets of target area images are subtracted from the mean value of 128, and then divided by the variance of 256 to obtain multiple sets of training samples. .
- Step S705 constructing a first network model, and sending multiple sets of training samples into the first network model for training.
- the constructed first network model may be ResNet-10.
- the confidence level output by the first network model after training has five categories: the confidence level of the top cover of the cargo box being closed, the confidence level of the cargo not loaded in the cargo box, and the amount of the cargo loaded in the cargo box meeting the preset amount.
- the confidence level, the camera anomaly confidence level, and the amount of goods loaded in the container do not meet the preset confidence level.
- the closure of the top cover of the cargo box can mean that the cargo box can be normally closed after loading goods; the top cover of the cargo box can be opened when no cargo is loaded in the cargo box, and the cargo box is empty; If the amount of goods meets the preset amount, it may be that the amount of goods loaded in the container is too large, so that the top cover of the container cannot be closed normally. Check the condition inside the cargo box.
- a device for detecting the state of a cargo box is also provided.
- the device can execute the method for detecting the state of a cargo box in the above-mentioned embodiment.
- the specific implementation manner and preferred application scenario are the same as those of the above-mentioned embodiment. Do repeat.
- FIG. 8 is a schematic diagram of a device for detecting the state of a cargo box according to an embodiment of the present disclosure. As shown in FIG. 8 , the device includes:
- An acquisition component 82 is configured to acquire images of the cargo box.
- the processing component 84 is configured to process the image of the container by using the first network model to obtain the confidence level of the state of the container.
- the determining component 86 is configured to determine the status of the cargo box based on the confidence level of the status of the cargo box, wherein the status of the cargo box includes one of the following: the top cover of the cargo box is closed, no cargo is loaded in the cargo box, and the amount of cargo loaded in the cargo box is sufficient The preset amount, the camera is abnormal, and the amount of goods loaded in the container does not meet the preset amount.
- the above-mentioned acquiring component 82, processing component 84 and determining component 86 may be run in a terminal as a part of the device, and the functions implemented by the above-mentioned components may be executed by a processor in the terminal, and the terminal may also be a smart phone. (such as Android mobile phones, iOS mobile phones, etc.), tablet computers, PDAs, and terminal devices such as Mobile Internet Devices (MID) and PAD.
- MID Mobile Internet Devices
- the above-mentioned obtaining component 82, processing component 84, and determining component 86 may be configured to execute steps S102 to S106 in the embodiments of the present disclosure.
- the examples and application scenarios implemented by the above components and corresponding steps are the same, but are not limited to the contents disclosed in the above embodiments.
- the processing component includes: a cropping component, configured to crop an image of the cargo box to obtain an image of the target area; a preprocessing component, configured to preprocess the image of the target area to obtain a processed image; an input component, configured as The processed image is input into the first network model to obtain the confidence level of the state of the container.
- trimming component may run in the terminal as a part of the apparatus, and the functions implemented by the above-mentioned components may be executed by a processor in the terminal.
- trimming component preprocessing component
- input component is the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the contents disclosed in the above-mentioned embodiments.
- the confidence level of the state of the container in the processing module includes a first confidence level for characterizing the closure of the top cover of the container, a second confidence level for characterizing the unloaded goods in the container, and a second confidence level for characterizing the loaded goods in the container.
- the third confidence level that the quantity of goods satisfies the preset quantity, the fourth confidence level that is used to represent the abnormality of the camera, and the fifth confidence level that is used to represent that the quantity of goods loaded in the cargo box does not meet the preset quantity.
- the processing component is further configured to extract the multi-frame container state confidence level corresponding to the multi-frame container images; the processing component is further configured to input the multi-frame container state confidence level into the second network model, and obtain the container state confidence level. .
- the determining component includes: a first extracting component, configured to extract the status of the container corresponding to the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level as cargo. or, a second extracting component, configured to extract the container state whose first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level are greater than the preset threshold as the container state; Or, the third extraction component is configured to extract the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level, and the status of the container corresponding to the value greater than the preset threshold is box status.
- first extracting component may run in a terminal as a part of the apparatus, and the functions implemented by the above-mentioned components may be executed by a processor in the terminal.
- the determining component is further configured to determine the state of the container based on the confidence of the state of the container and a preset rule, wherein the preset rule is used to represent the priority of the preset rule used to represent the confidence of the state of the container.
- the determining component further includes: a first judging component, configured to judge whether the fourth confidence level is greater than the fifth preset value, and if the fourth confidence level is greater than the fifth preset value, determine that the state of the cargo box is an abnormality of the camera;
- the second judging component is configured to judge whether the first confidence level is greater than the second preset value if the fourth confidence level is less than or equal to the fifth preset value, and determine whether the first confidence level is greater than the second preset value.
- the state is that the top cover of the cargo box is closed; the third judging component is configured to judge whether the second confidence level is greater than the third preset value if the first confidence level is less than or equal to the second preset value, and if the second confidence level is greater than the third If the second confidence level is less than or equal to the third preset value, it is determined whether the third confidence level is greater than the fourth preset value.
- the fifth judgment component is configured so that if the third confidence level is less than or equal to the fourth preset value value, then determine whether the fifth confidence level is greater than the sixth preset value, and if the fifth confidence level is greater than the sixth preset value, it is determined that the state of the container is that the amount of goods loaded in the container does not meet the preset amount.
- first judging component may run in the terminal as a part of the device, and may be processed by a processor in the terminal. Execute the function implemented by the above components.
- the preprocessing in the preprocessing unit includes at least one of the following: scaling processing and normalization processing.
- the acquiring component is further configured to acquire the original cargo box image; the processing component is further configured to process the original cargo box image to obtain multiple sets of training samples; the device further includes: a training component configured to use multiple sets of training samples to The initial model is trained to obtain the first network model.
- first judging component may run in the terminal as a part of the device, and may be processed by a processor in the terminal. Execute the function implemented by the above components.
- the processing component further includes: a perturbation processing component configured to perform perturbation processing on the original cargo box images to obtain multiple sets of original cargo box images; the trimming component is further configured to perform clipping processing on multiple sets of original cargo box images to obtain multiple groups of target area images; the preprocessing component is further configured to preprocess multiple groups of target area images to obtain multiple groups of training samples.
- a perturbation processing component configured to perform perturbation processing on the original cargo box images to obtain multiple sets of original cargo box images
- the trimming component is further configured to perform clipping processing on multiple sets of original cargo box images to obtain multiple groups of target area images
- the preprocessing component is further configured to preprocess multiple groups of target area images to obtain multiple groups of training samples.
- the above-mentioned disturbance processing component may run in the terminal as a part of the apparatus, and the functions implemented by the above-mentioned component may be executed by a processor in the terminal.
- the disturbance processing in the disturbance processing component includes at least one of the following: rotation, translation, scaling, noise addition, blurring, illumination change, and channel change.
- the acquisition component further includes: a detection component configured to detect whether the current light intensity is greater than the first preset value; the first acquisition component configured to use the first camera when the current light intensity is greater than the first preset value The image of the cargo box is acquired; the second acquisition component is configured to use the second camera to acquire the image of the cargo box when the current light intensity is less than or equal to the first preset value.
- the above-mentioned detection component, the first acquisition component and the second acquisition component may run in the terminal as a part of the apparatus, and the functions implemented by the above components may be executed by a processor in the terminal.
- the apparatus further includes an adding component configured to add a normalization layer to the initial layer of the initial model, wherein the normalization layer is used for normalizing multiple groups of training samples.
- the above-mentioned adding component may run in the terminal as a part of the apparatus, and the functions implemented by the above-mentioned component may be executed by a processor in the terminal.
- a computer-readable storage medium is also provided, where the computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the cargo box in the above-mentioned Embodiment 1 Status detection method.
- a processor is also provided, and the processor is used for running a program, wherein the method for detecting the state of a cargo box in the above-mentioned Embodiment 1 is executed when the program is running.
- the disclosed technical content can be implemented in other ways.
- the device embodiments described above are only illustrative, for example, the division of units may be a logical function division, and there may be other division methods in actual implementation, for example, multiple units or components may be combined or integrated into Another system, or some features can be ignored, or not implemented.
- the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of units or modules, and may be in electrical or other forms.
- the units described as separate components may or may not be physically separated, and components shown as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
- each functional unit in each embodiment of the present disclosure may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
- the above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
- the integrated unit if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium.
- a computer-readable storage medium including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present disclosure.
- the aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes .
- the first network model is used to process the image of the cargo box to obtain the confidence of the state of the cargo box, and then the state of the cargo box is determined based on the confidence of the state of the cargo box. It can detect whether the top cover of the shipping box is effectively closed, and can also detect whether the cargo box is loaded with goods, and detect the capacity of the goods loaded in the cargo box, and can detect the abnormality of the camera when the obtained image of the cargo box does not show the status of the cargo box , so as to effectively detect the status of the cargo box, compared with the solution of using radar to realize detection in the prior art, the cost is reduced, and the method of detecting the status of the cargo box in the related art can not detect whether the cargo box is loaded with goods. question.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Evolutionary Computation (AREA)
- Data Mining & Analysis (AREA)
- Artificial Intelligence (AREA)
- Computer Vision & Pattern Recognition (AREA)
- General Health & Medical Sciences (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Computing Systems (AREA)
- Life Sciences & Earth Sciences (AREA)
- Health & Medical Sciences (AREA)
- Computational Linguistics (AREA)
- Biophysics (AREA)
- Biomedical Technology (AREA)
- Molecular Biology (AREA)
- Mathematical Physics (AREA)
- Quality & Reliability (AREA)
- Multimedia (AREA)
- Evolutionary Biology (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Bioinformatics & Computational Biology (AREA)
- Databases & Information Systems (AREA)
- Medical Informatics (AREA)
- Image Analysis (AREA)
Abstract
A cargo container state detection method and apparatus. Said method comprises: acquiring a cargo container image (S102); processing the cargo container image using a first network model, so as to obtain a cargo container state confidence (S104); and on the basis of the cargo container state confidence, determining a cargo container state (S106). Said method solves the technical problem in the related art that a cargo container state detection method cannot detect whether a cargo container is loaded with cargo.
Description
本申请要求于2020年12月28日提交中国专利局、优先权号为202011589677.5、发明名称为“货箱状态的检测方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application with a priority number of 202011589677.5 and an invention titled "Method and Device for Detecting the Condition of a Cargo Box" filed with the China Patent Office on December 28, 2020, the entire contents of which are incorporated herein by reference Applying.
本公开涉及货箱状态检测领域,具体而言,涉及一种货箱状态的检测方法及装置。The present disclosure relates to the field of cargo box state detection, and in particular, to a method and device for detecting the state of a cargo box.
目前,渣土车在运输过程中会存在超载以及渣土散落的现象,若不能及时发现,不仅会影响道路的干净整洁还会造成诸多的安全隐患。At present, the muck trucks will be overloaded and the muck will be scattered during the transportation process. If they cannot be found in time, it will not only affect the cleanliness of the road, but also cause many hidden safety hazards.
为了解决上述问题,相关技术中通过设置第一雷达和第二雷达分别确定第一时间差和第二时间差,并由微控制器根据第一时间差和第二时间差确定出第一侧顶盖和第二侧顶盖的密闭性,可以识别出渣土车顶盖是否有效闭合,减少渣土车顶盖未有效闭合带来的环境问题。该方法中可以识别出渣土车顶盖是否有效闭合,但是无法识别渣土车货箱是否装载货物;且该方法中使用激光雷达,成本较高。In order to solve the above problems, in the related art, the first time difference and the second time difference are determined respectively by setting the first radar and the second radar, and the microcontroller determines the first side cover and the second time difference according to the first time difference and the second time difference. The airtightness of the side roof can identify whether the roof of the muck is effectively closed, and reduce the environmental problems caused by the ineffective closure of the roof of the muck. In this method, it can be identified whether the roof cover of the muck truck is effectively closed, but it cannot be identified whether the cargo box of the muck truck is loaded with goods; and the use of laser radar in this method is costly.
针对上述的问题,目前尚未提出有效的解决方案。For the above problems, no effective solution has been proposed yet.
发明内容SUMMARY OF THE INVENTION
本公开实施例提供了一种货箱状态的检测方法及装置,以至少解决相关技术中检测货箱状态的方法无法检测货箱内是否装载货物的技术问题。The embodiments of the present disclosure provide a method and device for detecting the state of a cargo box, so as to at least solve the technical problem that the method for detecting the state of a cargo box in the related art cannot detect whether goods are loaded in the cargo box.
根据本公开实施例的一个方面,提供了一种货箱状态的检测方法,包括:获取货箱图像;利用第一网络模型对货箱图像进行处理,得到货箱状态置信度;基于货箱状态置信度,确定货箱状态,其中,货箱状态包括如下之一:货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常、货箱内装载货物的货物量不满足预设量。According to an aspect of the embodiments of the present disclosure, a method for detecting the state of a cargo box is provided, including: acquiring an image of the cargo box; processing the image of the cargo box by using a first network model to obtain a confidence level of the state of the cargo box; Confidence, determine the status of the cargo box, where the status of the cargo box includes one of the following: the top cover of the cargo box is closed, no cargo is loaded in the cargo box, the amount of cargo loaded in the cargo box meets the preset amount, the camera is abnormal, the cargo box is abnormal The amount of cargo loaded does not meet the preset amount.
可选地,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度,包括:对货箱图像进行剪裁,得到目标区域图像;对目标区域图像进行预处理,得到处理后的图像;将处理后的图像输入到第一网络模型中,得到货箱状态置信度。Optionally, using the first network model to process the image of the cargo box to obtain the confidence level of the state of the cargo box includes: trimming the image of the cargo box to obtain the image of the target area; preprocessing the image of the target area to obtain the processed image ; Input the processed image into the first network model to obtain the confidence level of the state of the container.
可选地,货箱状态置信度包括:用于表征货箱顶盖封闭的第一置信度,用于表征 货箱内未装载货物的第二置信度,用于表征货箱内装载货物的货物量满足预设量的第三置信度,用于表征摄像头异常的第四置信度,和,用于表征述货箱内装载货物的货物量不满足预设量的第五置信度。Optionally, the confidence level of the state of the cargo box includes: a first confidence level for representing the closure of the top cover of the cargo box, a second confidence level for representing no cargo in the cargo box, and a cargo for representing the cargo loaded in the cargo box. The third confidence level is used to represent the abnormality of the camera, and the fifth confidence level is used to represent that the amount of goods loaded in the cargo box does not meet the preset amount.
可选地,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度,还包括:提取多帧货箱图像对应的多帧货箱状态置信度;将多帧货箱状态置信度输入第二网络模型,获取货箱状态置信度。Optionally, using the first network model to process the image of the container to obtain the confidence of the state of the container, further comprising: extracting the confidence of the state of the multi-frame container corresponding to the images of the multi-frame container; Enter the second network model to obtain the confidence level of the container state.
可选地,基于货箱状态置信度,确定货箱状态,包括:提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度中最高值对应的货箱状态为货箱状态;或,提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度大于预设阈值的货箱状态为货箱状态;或,提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度中最高值,并且大于预设阈值对应的货箱状态为货箱状态。Optionally, determining the state of the container based on the confidence level of the container state includes: extracting the container corresponding to the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level The state is the state of the container; or, extracting the state of the container whose first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level are greater than the preset threshold is the container state; or, extracting the first The highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level, and the container state corresponding to the one greater than the preset threshold value is the container state.
可选地,基于货箱状态置信度,确定货箱状态,包括:基于货箱状态置信度和预设规则,确定货箱状态,其中,预设规则用于表征货箱状态置信度的优先级。Optionally, determining the status of the container based on the confidence of the status of the container includes: determining the status of the container based on the confidence of the status of the container and a preset rule, wherein the preset rule is used to represent the priority of the confidence of the status of the container .
可选地,基于货箱状态置信度,确定货箱状态,包括:判断第四置信度是否大于第五预设值;若第四置信度大于第五预设值,则确定货箱状态为摄像头异常;若第四置信度小于等于第五预设值,则判断第一置信度是否大于第二预设值;若第一置信度大于第二预设值,则确定货箱状态为货箱顶盖封闭;若第一置信度小于等于第二预设值,则判断第二置信度是否大于第三预设值;若第二置信度大于第三预设值,则确定货箱状态为货箱内未装载货物;若第二置信度小于等于第三预设值,则判断第三置信度是否大于第四预设值;若第三置信度大于第四预设值,则确定货箱状态为货箱内装载货物的货物量满足预设量;若第三置信度小于等于第四预设值,则判断第五置信度是否大于第六预设值;若第五置信度大于第六预设值,则确定货箱状态为货箱内装载货物的货物量不满足预设量。Optionally, determining the state of the container based on the confidence of the state of the container includes: judging whether the fourth confidence is greater than a fifth preset value; if the fourth confidence is greater than the fifth preset, determining that the state of the container is a camera Abnormal; if the fourth confidence level is less than or equal to the fifth preset value, it is determined whether the first confidence level is greater than the second preset value; if the first confidence level is greater than the second preset value, it is determined that the state of the container is the top of the container The cover is closed; if the first confidence level is less than or equal to the second preset value, it is determined whether the second confidence level is greater than the third preset value; if the second confidence level is greater than the third preset value, it is determined that the state of the cargo box is a cargo box If the second confidence level is less than or equal to the third preset value, it is determined whether the third confidence level is greater than the fourth preset value; if the third confidence level is greater than the fourth preset value, it is determined that the state of the cargo box is The amount of goods loaded in the container meets the preset amount; if the third confidence level is less than or equal to the fourth preset value, it is determined whether the fifth confidence level is greater than the sixth preset value; if the fifth confidence level is greater than the sixth preset value value, then it is determined that the status of the container is that the quantity of goods loaded in the container does not meet the preset quantity.
可选地,预处理包括如下至少之一:缩放处理和归一化处理。Optionally, the preprocessing includes at least one of the following: scaling processing and normalization processing.
可选地,该方法还包括:获取原始货箱图像;对原始货箱图像进行处理,得到多组训练样本;利用多组训练样本对初始模型进行训练,得到第一网络模型。Optionally, the method further includes: acquiring an image of an original container; processing the image of the original container to obtain multiple sets of training samples; and using multiple sets of training samples to train an initial model to obtain a first network model.
可选地,对原始货箱图像进行处理,得到多组训练样本,包括:对原始货箱图像进行扰动处理,得到多组原始货箱图像;对多组原始货箱图像进行剪裁处理,得到多组目标区域图像;对多组目标区域图像进行预处理,得到多组训练样本。Optionally, processing the original cargo box images to obtain multiple sets of training samples, including: performing perturbation processing on the original cargo box images to obtain multiple sets of original cargo box images; trimming multiple sets of original cargo box images to obtain multiple sets of original cargo box images. group target area images; preprocess multiple groups of target area images to obtain multiple groups of training samples.
可选地,扰动处理包括如下至少之一:旋转、平移、缩放、加噪、模糊、光照变化和通道变化。Optionally, the perturbation processing includes at least one of the following: rotation, translation, scaling, noise addition, blurring, illumination change and channel change.
可选地,获取货箱图像,包括:检测当前光线强度是否大于第一预设值;如果当前光线强度大于第一预设值,则利用第一摄像头获取货箱图像;如果当前光线强度小于等于第一预设值,则利用第二摄像头获取货箱图像。Optionally, acquiring the image of the cargo box includes: detecting whether the current light intensity is greater than a first preset value; if the current light intensity is greater than the first preset value, using the first camera to acquire the image of the cargo box; if the current light intensity is less than or equal to If the first preset value is used, the image of the cargo box is obtained by using the second camera.
可选地,在利用多组训练样本对初始模型进行训练,得到第一网络模型之前,该方法还包括:在初始模型的初始层加入归一化层,其中,归一化层用于对多组训练样本进行归一化处理。Optionally, before using multiple sets of training samples to train the initial model to obtain the first network model, the method further includes: adding a normalization layer to the initial layer of the initial model, wherein the normalization layer is used to Group training samples are normalized.
根据本公开实施例的另一方面,还提供了一种货箱状态的检测装置,包括:获取组件,配置为获取货箱图像;处理组件,配置为利用第一网络模型对货箱图像进行处理,得到货箱状态置信度;确定组件,配置为基于货箱状态置信度,确定货箱状态,其中,货箱状态包括如下之一:货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常、货箱内装载货物的货物量不满足预设量。According to another aspect of the embodiments of the present disclosure, there is also provided an apparatus for detecting the state of a cargo box, including: an acquiring component, configured to acquire an image of the cargo box; and a processing component, configured to process the image of the cargo box by using a first network model , obtain the confidence of the state of the cargo box; the determining component is configured to determine the state of the cargo box based on the confidence of the state of the cargo box, wherein the state of the cargo box includes one of the following: the top cover of the cargo box is closed, the cargo is not loaded in the cargo box, the cargo box The amount of goods loaded in the container meets the preset amount, the camera is abnormal, and the amount of goods loaded in the container does not meet the preset amount.
根据本公开实施例的另一方面,还提供了一种计算机可读存储介质,计算机可读存储介质包括存储的程序,其中,在程序运行时控制计算机可读存储介质所在设备执行上述的货箱状态的检测方法。According to another aspect of the embodiments of the present disclosure, a computer-readable storage medium is also provided, where the computer-readable storage medium includes a stored program, wherein when the program is executed, a device where the computer-readable storage medium is located is controlled to execute the above-mentioned cargo box Status detection method.
根据本公开实施例的另一方面,还提供了一种处理器,处理器用于运行程序,其中,程序运行时执行上述的货箱状态的检测方法。According to another aspect of the embodiments of the present disclosure, a processor is also provided, and the processor is configured to run a program, wherein the above-mentioned method for detecting the state of a cargo box is executed when the program runs.
此处所说明的附图用来提供对本公开的进一步理解,构成本申请的一部分,本公开的示意性实施例及其说明用于解释本公开,并不构成对本公开的不当限定。在附图中:The accompanying drawings described herein are used to provide a further understanding of the present disclosure and constitute a part of the present application. The exemplary embodiments of the present disclosure and their descriptions are used to explain the present disclosure and do not constitute an improper limitation of the present disclosure. In the attached image:
图1是根据本公开实施例的一种货箱状态的检测方法的流程图;FIG. 1 is a flowchart of a method for detecting the state of a cargo box according to an embodiment of the present disclosure;
图2是根据本公开实施例的一种货箱顶盖封闭的货箱状态示意图;2 is a schematic diagram of a state of a cargo box with a top cover of the cargo box closed according to an embodiment of the present disclosure;
图3是根据本公开实施例的一种货箱内未装载货物的货箱状态示意图;FIG. 3 is a schematic diagram of the state of a cargo box with no goods loaded in the cargo box according to an embodiment of the present disclosure;
图4是根据本公开实施例的一种货箱内装载货物的货物量满足预设量的货箱状态示意图;FIG. 4 is a schematic diagram of the state of a cargo box in which the amount of goods loaded in a cargo box meets a preset amount according to an embodiment of the present disclosure;
图5是根据本公开实施例的一种摄像头异常的货箱状态示意图;FIG. 5 is a schematic diagram of the state of a cargo box with an abnormal camera according to an embodiment of the present disclosure;
图6是根据本公开实施例的一种可选的货箱状态的检测方法的示意图;6 is a schematic diagram of an optional method for detecting the state of a cargo box according to an embodiment of the present disclosure;
图7是根据本公开实施例的另一种可选的货箱状态的检测方法的示意图;FIG. 7 is a schematic diagram of another optional method for detecting the state of a cargo box according to an embodiment of the present disclosure;
图8是根据本公开实施例的一种货箱状态的检测装置的示意图。FIG. 8 is a schematic diagram of an apparatus for detecting the state of a cargo box according to an embodiment of the present disclosure.
为了使本技术领域的人员更好地理解本公开方案,下面将结合本公开实施例中的附图,对本公开实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本公开一部分的实施例,而不是全部的实施例。基于本公开中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本公开保护的范围。In order to make those skilled in the art better understand the solutions of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only Embodiments are part of the present disclosure, but not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present disclosure.
需要说明的是,本公开的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本公开的实施例能够以除了在这里图示或描述的那些以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。It should be noted that the terms "first", "second" and the like in the description and claims of the present disclosure and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific sequence or sequence. It is to be understood that the data so used may be interchanged under appropriate circumstances such that the embodiments of the disclosure described herein can be practiced in sequences other than those illustrated or described herein. Furthermore, the terms "comprising" and "having" and any variations thereof, are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those expressly listed Rather, those steps or units may include other steps or units not expressly listed or inherent to these processes, methods, products or devices.
实施例1Example 1
根据本公开实施例,提供了一种货箱状态的检测方法实施例,需要说明的是,在附图的流程图示出的步骤可以在诸如一组计算机可执行指令的计算机系统中执行,并且,虽然在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤。According to an embodiment of the present disclosure, an embodiment of a method for detecting the state of a cargo box is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings may be executed in a computer system such as a set of computer-executable instructions, and , although a logical order is shown in the flowcharts, in some cases steps shown or described may be performed in an order different from that herein.
图1是根据本公开实施例的一种货箱状态的检测方法,如图1所示,该方法包括如下步骤:FIG. 1 is a method for detecting the state of a cargo box according to an embodiment of the present disclosure. As shown in FIG. 1 , the method includes the following steps:
步骤S102,获取货箱图像;Step S102, acquiring the image of the cargo box;
步骤S104,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度;Step S104, using the first network model to process the image of the container to obtain the confidence level of the state of the container;
步骤S106,基于货箱状态置信度,确定货箱状态,其中,货箱状态包括如下之一:货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常、货箱内装载货物的货物量不满足预设量。Step S106: Determine the status of the cargo box based on the confidence level of the status of the cargo box, wherein the status of the cargo box includes one of the following: the top cover of the cargo box is closed, the cargo box is not loaded with goods, and the amount of goods loaded in the cargo box meets a preset amount , The camera is abnormal, and the amount of goods loaded in the cargo box does not meet the preset amount.
通过本公开上述实施例,在获取到货箱图像之后,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度,然后基于货箱状态置信度确定货箱状态,实现了在检测货箱状态时,不仅能检测出货箱的顶盖是否有效闭合,还能检测货箱内是否装载货物,以及检测货箱内装载货物的容量,并且在获取的货箱图像未显示货箱状态时可 以检测出摄像头异常,从而有效的检测货箱状态。本公开中仅采用摄像头实现检测,相较于现有技术中使用雷达实现检测的方案,成本有所降低,并且解决了相关技术中检测货箱状态的方法无法检测货箱内是否装载货物的技术问题。Through the above embodiments of the present disclosure, after the image of the cargo box is obtained, the first network model is used to process the image of the cargo box to obtain the confidence level of the status of the cargo box, and then the status of the cargo box is determined based on the confidence level of the status of the cargo box, thereby realizing the detection When the cargo box is in the state, it can not only detect whether the top cover of the shipping box is effectively closed, but also detect whether the cargo box is loaded with goods, and detect the capacity of the goods loaded in the cargo box, and the obtained cargo box image does not show the status of the cargo box. When the camera is abnormal, it can detect the status of the container effectively. In the present disclosure, only a camera is used to realize detection. Compared with the solution of using radar to realize detection in the prior art, the cost is reduced, and the method of detecting the state of the cargo box in the related art can not detect whether the cargo is loaded in the cargo box. question.
下面结合上述各实施步骤进行详细说明。The following describes in detail with reference to the above implementation steps.
步骤S102,获取货箱图像。Step S102, acquiring the image of the cargo box.
上述步骤中的货箱图像可以是渣土车的货箱图像、货车的货箱图像、仓库中摆放的货箱图像,此处不做任何限定。需要说明的是,货箱图像可以是普通摄像头获取到的货箱图像,还可以是红外摄像头获取到的红外货箱图像。在夜晚等光照不足的环境中,普通摄像头获取的图像昏暗模糊质量低,对后续货箱状态检测的精度会产生影响,故可采用红外摄像头在光照不足的环境中采集图像,通过前期采集高质量的图像保证后续货箱状态检测高精度地实现。The image of the cargo box in the above steps may be an image of a cargo box of a muck truck, an image of a cargo box of a truck, or an image of a cargo box placed in a warehouse, which is not limited herein. It should be noted that the image of the cargo box may be an image of the cargo box obtained by a common camera, or may be an image of an infrared cargo box obtained by an infrared camera. In an environment with insufficient light such as at night, the images obtained by ordinary cameras are dim and blurred, and the quality is low, which will affect the accuracy of subsequent detection of the state of the container. Therefore, infrared cameras can be used to collect images in an environment with insufficient light, and high-quality images can be collected in the early stage. The image ensures that the subsequent detection of the condition of the cargo box is realized with high precision.
上述步骤中,获取的货箱图像可以是当前货箱图像,也可以是历史存储的货箱图像。In the above steps, the acquired image of the cargo box may be the current image of the cargo box, or may be the image of the historically stored cargo box.
上述步骤中的货箱图像可以通过安装在货箱上的摄像头获取,也可以通过安装在车身的摄像头获取。需要说明的是,摄像头可以获取固定位置的货箱图像,该货箱图像可以显示出货箱的顶盖状态和货箱内装载货物的状态。The image of the cargo box in the above steps can be acquired by a camera mounted on the cargo box, or acquired by a camera mounted on the vehicle body. It should be noted that the camera can acquire an image of the container at a fixed position, and the image of the container can display the state of the top cover of the shipping container and the state of the goods loaded in the container.
在一种可选的实施例中,可以通过安装在渣土车上的摄像头获取渣土车的当前货箱图像。In an optional embodiment, an image of the current cargo box of the muck truck may be acquired through a camera installed on the muck truck.
步骤S104,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度。Step S104 , using the first network model to process the image of the container to obtain the confidence level of the state of the container.
上述步骤中的第一网络模型可以为CNN(Convolution neural network,卷积神经网络),这种第一网络模型可以模拟视觉皮层分解并分析图像数据。The first network model in the above steps can be a CNN (Convolution neural network, convolutional neural network), and the first network model can simulate the visual cortex to decompose and analyze image data.
需要说明的是,本申请的第一网络模型可以直接得到所有货箱状态的置信度,即本申请根据货箱图像只需要一个第一网络模型就可以得到多个货箱状态的置信度,提高了确定货箱状态的速度。It should be noted that the first network model of the present application can directly obtain the confidence levels of all the container states, that is, the present application only needs one first network model to obtain the confidence levels of the states of multiple containers according to the container image, thereby increasing the confidence level. to determine the speed at which the status of the container is determined.
上述步骤中货箱状态可以为货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常和货箱内装载货物的货物量不满足预设量。其中,货箱内未装载货物可以是指货箱空载,货箱内装载货物的货物量满足预设量可以是指货箱内满载、货箱内超载等,具体可以根据预设量的具体取值进行确定。本申请中第一网络模型置信度输出不仅包含货箱顶盖开合状态,还包括货箱内货物量状态以及摄像头状态的检测。In the above steps, the status of the cargo box may be that the top cover of the cargo box is closed, no goods are loaded in the cargo box, the amount of goods loaded in the cargo box meets the preset amount, the camera is abnormal, and the amount of goods loaded in the cargo box does not meet the preset amount. . Wherein, the unloaded goods in the container may refer to the empty container, and the amount of goods loaded in the container that meets the preset amount may mean that the container is fully loaded, the container is overloaded, etc. value to be determined. In the present application, the output of the confidence level of the first network model includes not only the opening and closing status of the top cover of the cargo box, but also the detection of the status of the amount of goods in the cargo box and the status of the camera.
置信度也称可靠度、置信水平,可以是估计值与总体参数在一定允许的误差范围以内的概率。上述步骤中的货箱状态置信度可以是指对货箱图像通过第一网络模型分析后所得到的每种货箱状态的概率。Confidence, also known as reliability and confidence level, can be the probability that the estimated value and the overall parameter are within a certain allowable error range. The confidence of the state of the container in the above steps may refer to the probability of each state of the container obtained by analyzing the image of the container through the first network model.
可选地,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度,包括:对货箱图像进行剪裁,得到目标区域图像;对目标区域图像进行预处理,得到处理后的图像;将处理后的图像输入到第一网络模型中,得到货箱状态置信度。Optionally, using the first network model to process the image of the cargo box to obtain the confidence level of the state of the cargo box includes: trimming the image of the cargo box to obtain the image of the target area; preprocessing the image of the target area to obtain the processed image ; Input the processed image into the first network model to obtain the confidence level of the state of the container.
上述步骤中的目标区域可以是指货箱图像中的ROI(Region of Interesting,感兴趣区域),考虑到摄像头拍摄场景是不变的,对货箱状态的识别可以针对预先设定的感兴趣的区域进行。例如,可以是指货箱图像中货箱顶盖所在的区域,具体可以根据实际检测需要进行确定。The target area in the above steps may refer to the ROI (Region of Interest) in the image of the cargo box. Considering that the camera shooting scene is unchanged, the identification of the status of the cargo box can be based on the preset interest. area carried out. For example, it may refer to the area where the top cover of the cargo box is located in the cargo box image, which may be determined according to actual detection needs.
具体地,可以通过ROI来对图像进行剪裁,得到目标区域图像;使用ROI指定读入图像中的目标区域,以便后续仅对货箱所在的目标区域图像进行分类识别,可以减少检测处理时间,增加检测精度,给图像处理能够带来便利。其中,可以利用Range(范围函数)指定感兴趣的行和列的范围,Range是从起始索引到终止索引的一段连续序列;还可以利用矩形Rect(矩形函数)框定,指定矩形Rect左上角坐标和矩形的长宽。Specifically, the ROI can be used to trim the image to obtain the target area image; the ROI can be used to specify the target area in the read-in image, so that only the target area image where the container is located can be classified and identified, which can reduce the detection processing time and increase the The detection accuracy can bring convenience to image processing. Among them, you can use Range (range function) to specify the range of rows and columns of interest. Range is a continuous sequence from the start index to the end index; you can also use the rectangle Rect (rectangle function) to frame, specify the coordinates of the upper left corner of the rectangle Rect and the length and width of the rectangle.
可选地,上述的预处理包括如下至少之一:缩放处理和归一化处理。Optionally, the above-mentioned preprocessing includes at least one of the following: scaling processing and normalization processing.
上述步骤中的缩放处理是指对数字图像的大小进行调整的过程。图像缩放需要在处理效率以及结果的平滑度和清晰度上做一个权衡,当一个图像的大小增加之后,组成图像的像素可见度将会变得更高;相反的,缩小一个图像将会增强它的平滑度和清晰度。图像固定的尺寸的选定基于第一网络模型识别速度和识别精度的实际需求,针对不同采集的图像在识别过程中都采用同样的标准,从而保证网络输出的信息更准确。示例性的,可以将目标区域图像缩放至固定尺寸:128*128。The scaling process in the above steps refers to the process of adjusting the size of the digital image. Image scaling requires a trade-off between processing efficiency and the smoothness and clarity of the result. As the size of an image increases, the pixels that make up the image become more visible; conversely, shrinking an image will enhance its smoothness and clarity. The selection of the fixed size of the image is based on the actual requirements of the recognition speed and recognition accuracy of the first network model, and the same standard is used in the recognition process for different collected images, so as to ensure that the information output by the network is more accurate. Exemplarily, the target area image can be scaled to a fixed size: 128*128.
上述步骤中的归一化处理是指把数据限定在一定的范围内。归一化处理并不改变图像信息,但其可消除奇异图像引起网络初始无效影响,可以防止图像进入第一网络模型后产生梯度爆炸等。归一化处理的方法可以为最大-最小标准化、Z-score标准化、函数转化等;其中,最大-最小标准化是指对原始数据进行线性变化;Z-score标准化是基于原始数据的均值和标准差进行的数据标准化。The normalization processing in the above steps refers to limiting the data to a certain range. The normalization process does not change the image information, but it can eliminate the initial invalid effect of the network caused by the singular image, and can prevent the gradient explosion after the image enters the first network model. The normalization method can be maximum-minimum normalization, Z-score normalization, function transformation, etc. Among them, maximum-minimum normalization refers to the linear change of the original data; Z-score normalization is based on the mean and standard deviation of the original data. Data normalization performed.
具体地,可以通过ROI对货箱图像进行剪裁,得到目标区域,然后将目标区域缩放至固定尺寸:128*128,之后对缩放后的目标区域进行归一化处理,具体为将目标区域的像素值减去均值128,再除以方差256,最后将处理后的图像输入到卷积神经网络中,得到货箱状态置信度。Specifically, the image of the cargo box can be cropped through the ROI to obtain the target area, and then the target area is scaled to a fixed size: 128*128, and then the scaled target area is normalized, specifically, the pixels of the target area are The value is subtracted from the mean value of 128, and then divided by the variance of 256. Finally, the processed image is input into the convolutional neural network to obtain the confidence level of the state of the container.
可选地,上述的货箱状态置信度包括:用于表征货箱顶盖封闭的第一置信度,用于表征货箱内未装载货物的第二置信度,用于表征货箱内装载货物的货物量满足预设量的第三置信度,用于表征摄像头异常的第四置信度,和,用于表征述货箱内装载货物的货物量不满足预设量的第五置信度。Optionally, the above-mentioned confidence level of the state of the container includes: a first confidence level for characterizing the closure of the top cover of the container, a second confidence level for characterizing the unloaded goods in the container, and a second confidence level for characterizing the loaded goods in the container. The third confidence level is used to characterize the abnormality of the camera, and the fifth confidence level is used to indicate that the quantity of goods loaded in the cargo box does not meet the preset amount.
在一种可选的实施例中,可以利用卷积神经网络对当前货箱图像进行处理,第一网络模型输出结果为货箱顶盖封闭的置信度为80%、货箱内未装载货物的置信度为5%、货箱内装载货物的货物量满足预设量的置信度为5%、摄像头异常的置信度为5%、货箱内装载货物的货物量未满足预设量的置信度为5%。In an optional embodiment, a convolutional neural network can be used to process the current cargo box image, and the output result of the first network model is that the confidence level of the top cover of the cargo box being closed is 80%, and the cargo box is not loaded with goods. The confidence level is 5%, the confidence level of the amount of goods loaded in the container meets the preset amount is 5%, the confidence level of the camera is abnormal is 5%, the confidence level of the cargo volume loaded in the container does not meet the preset amount is 5%.
步骤S106,基于货箱状态置信度,确定货箱状态。In step S106, the state of the container is determined based on the confidence level of the state of the container.
其中,货箱状态包括如下之一:货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常、货箱内装载货物的货物量不满足预设量。The status of the cargo box includes one of the following: the top cover of the cargo box is closed, no cargo is loaded in the cargo box, the amount of goods loaded in the cargo box meets the preset amount, the camera is abnormal, and the amount of goods loaded in the cargo box does not meet the predetermined amount. Set the amount.
图2所示为货箱顶盖封闭的货箱状态示意图;图3所示为货箱内未装载货物的货箱状态示意图;图4所示为货箱内装载货物的货物量满足预设量的货箱状态示意图;图5所示为摄像头异常的货箱状态示意图。Fig. 2 shows a schematic diagram of the state of the cargo box with the top cover of the cargo box closed; Fig. 3 shows a schematic diagram of the state of the cargo box with no goods loaded in the cargo box; Fig. 4 shows that the amount of goods loaded in the cargo box meets the preset amount Schematic diagram of the status of the cargo box; Figure 5 shows the schematic diagram of the status of the cargo box with an abnormal camera.
货箱顶盖封闭指货箱在装载货物不满足预设量或货箱内未装载货物之后可以正常的封闭;货箱顶盖开启可以为货箱内空载或者货箱内装载的货物量不满足预设量时货箱顶盖正常的开启,或者货箱内装载的货物量太多导致货箱顶盖无法正常封闭;摄像头异常可以为摄像头被遮挡或者摄像头发生偏转,导致无法有效检测货箱内的状态。The closing of the top cover of the cargo box means that the cargo box can be normally closed after the loading of goods does not meet the preset amount or the cargo box is not loaded with goods; When the preset amount is met, the top cover of the cargo box is normally opened, or the amount of goods loaded in the cargo box is too large, so that the top cover of the cargo box cannot be closed normally; the abnormality of the camera may be that the camera is blocked or the camera is deflected, resulting in the inability to effectively detect the cargo box. state within.
可选地,基于货箱状态置信度,确定货箱状态,包括:提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度中最高值对应的货箱状态为货箱状态;或,提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度大于预设阈值的货箱状态为货箱状态;或,提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度中最高值,并且大于预设阈值对应的货箱状态为货箱状态。Optionally, determining the state of the container based on the confidence level of the container state includes: extracting the container corresponding to the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level The state is the state of the container; or, extracting the state of the container whose first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level are greater than the preset threshold is the container state; or, extracting the first The highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level, and the container state corresponding to the one greater than the preset threshold value is the container state.
在一种可选的实施例中,可以选取第一网络模型输出的各货箱状态的置信度中最高的置信度,确定货箱状态为最高置信度对应的货箱状态,以确保货箱状态的准确性。In an optional embodiment, the highest confidence level among the confidence levels of the states of each cargo box output by the first network model may be selected, and the state of the cargo box may be determined to be the container state corresponding to the highest confidence level, so as to ensure the state of the cargo box. accuracy.
在另一种可选的实施例中,可以设置预设阈值,当置信度大于预设阈值时,确定货箱状态为该置信度对应的货箱状态,以确保得到的货箱状态的准确性。第一置信度大于第二预设值时,确定货箱状态为货箱顶盖封闭;当第二置信度大于第三预设值时,确定货箱状态为货箱内未装载货物;当第三置信度大于第四预设值时,确定货箱状态为货箱内装载货物的货物量满足预设量;当第四置信度大于第五预设值时,确定货箱状态为摄像头异常;当第五置信度大于第六预设值时,确定货箱状态为货箱内装载货物的货物量不满足预设量。In another optional embodiment, a preset threshold may be set, and when the confidence level is greater than the preset threshold, it is determined that the container state is the container state corresponding to the confidence level, so as to ensure the accuracy of the obtained container state . When the first confidence level is greater than the second preset value, the state of the cargo box is determined to be that the top cover of the cargo box is closed; when the second confidence level is greater than the third preset value, the state of the cargo box is determined to be that no goods are loaded in the cargo box; When the third confidence level is greater than the fourth preset value, it is determined that the state of the cargo box is that the amount of goods loaded in the cargo box meets the preset amount; when the fourth confidence level is greater than the fifth preset value, it is determined that the state of the cargo box is the camera abnormality; When the fifth confidence level is greater than the sixth preset value, it is determined that the state of the cargo box is that the amount of goods loaded in the cargo box does not meet the preset amount.
在又一种可选的实施例中,可以根据最高的置信度和预设阈值确定货箱状态,当置信度满足这两个条件时,将货箱状态确定为该置信度对应的货箱状态,以进一步提高货箱状态的准确度。In yet another optional embodiment, the state of the container may be determined according to the highest confidence level and a preset threshold, and when the confidence level satisfies these two conditions, the state of the container is determined as the state of the container corresponding to the confidence level , to further improve the accuracy of the status of the cargo box.
可选地,基于货箱状态置信度,确定货箱状态,包括:基于货箱状态置信度和预设规则,确定货箱状态,其中,预设规则用于表征货箱状态置信度的优先级。Optionally, determining the status of the container based on the confidence of the status of the container includes: determining the status of the container based on the confidence of the status of the container and a preset rule, wherein the preset rule is used to represent the priority of the confidence of the status of the container .
具体地,可以根据第一置信度、第二置信度、第三置信度、第四置信度、第五置信度的判断优先级进行判断,然后根据判断的结果输出货箱状态。其中,判断优先级可以由用户进行设定,判断优先级还可以随机生成。优先级的设定可根据货箱状态对应的危险程度,例如摄像头处于遮挡或者故障的状态将导致无法判别货箱顶盖和货物量的状态,而货箱内装载的货物量太多导致货箱顶盖无法正常封闭将带来道路环境以及安全隐患。Specifically, the judgment may be made according to the judgment priorities of the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level, and then output the status of the container according to the judgment result. The judgment priority may be set by the user, and the judgment priority may also be randomly generated. The priority setting can be based on the degree of danger corresponding to the status of the container. For example, if the camera is blocked or faulty, it will not be possible to determine the status of the top cover and the amount of goods. If the top cover cannot be closed normally, it will bring road environment and safety hazards.
可选地,基于货箱状态置信度,确定货箱状态,包括:判断第四置信度是否大于第五预设值;若第四置信度大于第五预设值,则确定货箱状态为摄像头异常;若第四置信度小于等于第五预设值,则判断第一置信度是否大于第二预设值;若第一置信度大于第二预设值,则确定货箱状态为货箱顶盖封闭;若第一置信度小于等于第二预设值,则判断第二置信度是否大于第三预设值;若第二置信度大于第三预设值,则确定货箱状态为货箱内未装载货物;若第二置信度小于等于第三预设值,则判断第三置信度是否大于第四预设值;若第三置信度大于第四预设值,则确定货箱状态为货箱内装载货物的货物量满足预设量;若第三置信度小于等于第四预设值,则判断第五置信度是否大于第六预设值;若第五置信度大于第六预设值,则确定货箱状态为货箱内装载货物的货物量不满足预设量。Optionally, determining the state of the container based on the confidence of the state of the container includes: judging whether the fourth confidence is greater than a fifth preset value; if the fourth confidence is greater than the fifth preset, determining that the state of the container is a camera Abnormal; if the fourth confidence level is less than or equal to the fifth preset value, it is determined whether the first confidence level is greater than the second preset value; if the first confidence level is greater than the second preset value, it is determined that the state of the container is the top of the container The cover is closed; if the first confidence level is less than or equal to the second preset value, it is determined whether the second confidence level is greater than the third preset value; if the second confidence level is greater than the third preset value, it is determined that the state of the cargo box is a cargo box If the second confidence level is less than or equal to the third preset value, it is determined whether the third confidence level is greater than the fourth preset value; if the third confidence level is greater than the fourth preset value, it is determined that the state of the cargo box is The amount of goods loaded in the container meets the preset amount; if the third confidence level is less than or equal to the fourth preset value, it is determined whether the fifth confidence level is greater than the sixth preset value; if the fifth confidence level is greater than the sixth preset value value, then it is determined that the status of the container is that the quantity of goods loaded in the container does not meet the preset quantity.
上述步骤中,置信度判断的优先级从高到低的顺序为:第四置信度、第一置信度、第二置信度、第三置信度、第五置信度。In the above steps, the order of the priority of the confidence level judgment from high to low is: the fourth confidence level, the first confidence level, the second confidence level, the third confidence level, and the fifth confidence level.
在一种可选的实施例中,可以首先判断第四置信度是否大于第五预设值,若第四置信度大于第五预设值,则说明渣土车的摄像头有异常,此时,其他的置信度的数据都不准确,因此,可以直接确定货箱状态为摄像头有异常,提高确定货箱状态的准确度。In an optional embodiment, it may be first determined whether the fourth confidence level is greater than the fifth preset value. If the fourth confidence level is greater than the fifth preset value, it means that the camera of the muck truck is abnormal. The data of other confidence levels are inaccurate. Therefore, it can be directly determined that the status of the cargo box is abnormal with the camera, which improves the accuracy of determining the status of the cargo box.
示例性的,可以在判断出第一置信度大于第二预设值,第二置信度小于第三预设值,第三置信度小于第四预设值,第四置信度小于第五预设值之后,第五置信度小于第六预设值,输出货箱状态为第一置信度所表征的货箱顶盖封闭。Exemplarily, it may be determined that the first confidence level is greater than the second preset value, the second confidence level is less than the third preset value, the third confidence level is less than the fourth preset value, and the fourth confidence level is less than the fifth preset value. After the value, the fifth confidence level is less than the sixth preset value, and the output container state is that the top cover of the container represented by the first confidence level is closed.
上述步骤中的预设量可以由用户根据货箱的容量进行设定。第二预设值、第三预设值、第四预设值、第五预设值、第六预设值可以相同也可以不同,此处不做任何限 定。The preset amount in the above steps can be set by the user according to the capacity of the cargo box. The second preset value, the third preset value, the fourth preset value, the fifth preset value, and the sixth preset value may be the same or different, which are not limited herein.
通过本公开上述实施例,在获取到货箱图像之后,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度,然后基于货箱状态置信度确定货箱状态,实现了在检测货箱状态时,不仅能检测出货箱的顶盖是否有效闭合,还能检测货箱内是否装载货物,以及检测货箱内装载货物的容量,仅使用摄像头获取货箱图像即可以降低检测成本。比如:在获取到货箱图像之后,可以利用第一网络模型对货箱图像进行分析,得到货箱顶盖封闭的置信度、货箱内未装载货物置信度、货箱内装载货物的货物量满足预设量的置信度、摄像头异常的置信度、货箱内装载货物的货物量不满足预设量的置信度,可以根据货箱各种状态的置信度确定出货箱状态,不仅可以检测货箱的顶盖是否有效闭合,还可以检测货箱内是否装载货物,并且在获取的货箱图像未显示货箱状态时可以检测出摄像头异常,从而有效的检测货箱状态,同时,本公开中仅采用摄像头实现检测,相较于现有技术中使用雷达实现检测的方案,成本有所降低,性能稳定以及适用范围广,进而解决了相关技术中检测货箱状态的方法无法检测货箱内是否装载货物的技术问题。可选地,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度,还包括:提取多帧货箱图像对应的多帧货箱状态置信度;将多帧货箱状态置信度输入第二网络模型,获取货箱状态置信度。Through the above embodiments of the present disclosure, after the image of the cargo box is obtained, the first network model is used to process the image of the cargo box to obtain the confidence level of the status of the cargo box, and then the status of the cargo box is determined based on the confidence level of the status of the cargo box, thereby realizing the detection When the cargo box is in the state, it can not only detect whether the top cover of the shipping box is effectively closed, but also detect whether the cargo box is loaded with goods, and detect the capacity of the loaded goods in the cargo box. Only using the camera to obtain the image of the cargo box can reduce the detection cost. . For example: after obtaining the image of the cargo box, the first network model can be used to analyze the image of the cargo box to obtain the confidence level of the closed top cover of the cargo box, the confidence level of the unloaded goods in the cargo box, and the quantity of goods loaded in the cargo box. The confidence level of meeting the preset amount, the confidence level of the camera being abnormal, and the confidence level that the amount of goods loaded in the container does not meet the preset amount can be determined according to the confidence level of various states of the container. The state of the shipping box can not only detect Whether the top cover of the cargo box is effectively closed, it can also detect whether the cargo box is loaded with goods, and when the obtained image of the cargo box does not show the status of the cargo box, the abnormality of the camera can be detected, so as to effectively detect the status of the cargo box. At the same time, the present disclosure Compared with the conventional method of using radar to realize detection, the cost is reduced, the performance is stable and the scope of application is wide, which solves the problem that the method of detecting the state of the cargo box in the related art cannot detect the inside of the cargo box. Whether or not to load the goods technically. Optionally, using the first network model to process the image of the container to obtain the confidence of the state of the container, further comprising: extracting the confidence of the state of the multi-frame container corresponding to the images of the multi-frame container; Enter the second network model to obtain the confidence level of the container state.
进一步地,为了避免基于单帧图像检测获得的置信度结果会出现检测结果不稳定以及误检和漏检的情况,本公开基于多帧图像检测获得的置信度结果判断货箱状态。多帧处理的帧数选择在处理效率以及结果质量上做权衡,维持检测结果稳定的同时可提升货箱状态检测的准确度。具体地,持续检测货箱状态30s,提取该时间段内的多帧图像分别进入第一网络模型获取对应的多帧货箱状态置信度,将所获得的多帧货箱状态置信度输入第二网络模型,训练获得最终货箱状态置信度,上述第二网络模型可以为支持向量机。Further, in order to avoid unstable detection results, false detections and missed detections in the confidence results obtained based on single-frame image detection, the present disclosure determines the status of the cargo box based on the confidence results obtained from multi-frame image detection. The selection of the number of frames for multi-frame processing is a trade-off between processing efficiency and result quality, which can improve the accuracy of container status detection while maintaining the stability of the detection results. Specifically, the state of the container is continuously detected for 30s, and the multi-frame images within this time period are extracted and entered into the first network model to obtain the corresponding multi-frame container state confidence, and the obtained multi-frame container state confidence is input into the second The network model is trained to obtain the confidence level of the final cargo box state, and the above-mentioned second network model may be a support vector machine.
可选地,该方法还包括:获取原始货箱图像;对原始货箱图像进行处理,得到多组训练样本;利用多组训练样本对初始模型进行训练,得到第一网络模型。Optionally, the method further includes: acquiring an image of an original container; processing the image of the original container to obtain multiple sets of training samples; and using multiple sets of training samples to train an initial model to obtain a first network model.
上述步骤中的原始货箱图像可以通过摄像头获取的,也可以通过网络获取,还可以从本地存储的文件中获取,此处不做任何限定。The original cargo box image in the above steps can be acquired through a camera, can also be acquired through a network, or can be acquired from a file stored locally, which is not limited here.
上述步骤中的训练样本也就是初始模型的参数,经过训练之后,可以认为模型系统确立了下来。其中,初始模型可以为未经过训练的模型,还可以为之前已经训练过至少一次的模型。The training samples in the above steps are also the parameters of the initial model. After training, it can be considered that the model system has been established. The initial model may be an untrained model or a model that has been trained at least once before.
需要说明的是,第一网络模型在训练过程中已经考虑到普通图像和红外图像因素,因此,通过第一网络模型基于不同类型的图像来进行识别,以提高识别的准确度。It should be noted that the first network model has taken into account the factors of ordinary images and infrared images in the training process. Therefore, the first network model is used to perform recognition based on different types of images to improve the recognition accuracy.
示例性的,当第一网络模型在训练的过程中,分别基于普通图像和红外图像进行训练,当检测到货箱图像为普通图像时,第一网络模型可以基于普通图像对货箱图像进行识别;当检测到的货箱图像为红外图像时,第一网络模型可以基于红外图像的训练记过对红外图像进行识别,通过训练两种不同类型的货箱图像,可以提高货箱图像识别的准确度以及扩展第一网络模型的兼容性。Exemplarily, when the first network model is trained based on ordinary images and infrared images, respectively, when it is detected that the image of the cargo box is an ordinary image, the first network model can identify the image of the cargo box based on the ordinary image. ; When the detected image of the cargo box is an infrared image, the first network model can recognize the infrared image based on the training demerits of the infrared image. By training two different types of cargo box images, the accuracy of the image recognition of the cargo box can be improved. As well as extending the compatibility of the first network model.
上述步骤中的第一网络模型可以为ResNet(Residual Neural Network,残差网络)。The first network model in the above steps may be ResNet (Residual Neural Network, residual network).
可选地,对原始货箱图像进行处理,得到多组训练样本,包括:对原始货箱图像进行扰动处理,得到多组原始货箱图像,其中,扰动处理用于对原始货箱图像进行扩充和增强;对多组原始货箱图像进行剪裁处理,得到多组目标区域图像;对多组目标区域图像进行预处理,得到多组训练样本。Optionally, processing the original cargo box images to obtain multiple sets of training samples, including: performing perturbation processing on the original cargo box images to obtain multiple sets of original cargo box images, wherein the perturbation processing is used to expand the original cargo box images and enhancement; trimming multiple sets of original cargo box images to obtain multiple sets of target area images; preprocessing multiple sets of target area images to obtain multiple sets of training samples.
现实场景环境信息复杂多变,相比之下采集的训练样本数据量有限,为了实际检测中依旧适应变化的环境场景,本公开对原始图像样本进行扩充和增强,丰富训练样本使其对复杂环境抗干扰能力更强。The real scene environment information is complex and changeable. In contrast, the amount of training sample data collected is limited. In order to still adapt to the changing environmental scene in actual detection, the present disclosure expands and enhances the original image samples, and enriches the training samples to make them suitable for complex environments. Stronger anti-interference ability.
在一种可选的实施例中,可以对原始货箱图像进行旋转、平移、缩放、加噪、模糊、光照变化、通道变化,得到多组原始货箱图像,然后通过ROI对多组原始货箱图像进行剪裁处理,得到多组目标区域图像;将多组目标区域图像缩放至固定尺寸后,再对缩放后的多组目标区域图像进行归一化处理,得到多组训练样本。In an optional embodiment, rotation, translation, scaling, noise addition, blurring, illumination change, and channel change may be performed on the original cargo box image to obtain multiple sets of original cargo container images, and then multiple sets of original cargo container images can be processed through ROI. The box images are cropped to obtain multiple sets of target area images; after the multiple sets of target area images are scaled to a fixed size, the scaled multiple sets of target area images are normalized to obtain multiple sets of training samples.
在另一种可选的实施例中,在对多组目标区域图像进行预处理后,还可以再次进行扰动处理,以得到更丰富的训练样本,使其对复杂环境抗干扰能力更强。In another optional embodiment, after preprocessing multiple groups of target area images, perturbation processing may be performed again to obtain more abundant training samples, so that the anti-interference ability of complex environments is stronger.
可选地,扰动处理包括如下至少之一:旋转、平移、缩放、加噪、模糊、光照变化、通道变化。Optionally, the perturbation processing includes at least one of the following: rotation, translation, scaling, noise addition, blurring, illumination change, channel change.
在一种可选的实施例中,可以对原始货箱图像随机选择0至15左右旋转操作。In an optional embodiment, 0 to 15 left and right rotation operations may be randomly selected for the original cargo box image.
在另一种可选的实施例中,可以对原始货箱图像上下左右移动0至50个像素平移操作。In another optional embodiment, a translation operation may be performed on the original cargo box image by moving up, down, left, and right by 0 to 50 pixels.
在另一种可选的实施例中,可以对原始货箱图像随机进行0.8至1.2被图像缩放操作。In another optional embodiment, an image scaling operation of 0.8 to 1.2 may be randomly performed on the original cargo box image.
在另一种可选的实施例中,可以对原始货箱图像随机加入均值为0至4.0的高斯或椒盐噪声。In another optional embodiment, Gaussian or salt and pepper noise with a mean value of 0 to 4.0 may be randomly added to the original cargo box image.
在另一种可选的实施例中,可以对原始货箱图像随机加入模板为0至9的高斯模糊。In another optional embodiment, a Gaussian blur with a template of 0 to 9 may be randomly added to the original cargo box image.
在另一种可选的实施例中,可以对原始货箱图像随机对每个像素乘以0.8至1.2的光照变换。In another alternative embodiment, the original container image may be randomly multiplied by a lighting transformation of 0.8 to 1.2 per pixel.
在另一种可选的实施例中,可以对原始货箱图像的通道进行转换,例如,将RGB通道转化为BRG通道。In another optional embodiment, channels of the original cargo box image may be converted, for example, RGB channels are converted to BRG channels.
可选地,获取货箱图像,包括:检测当前光线强度是否大于第一预设值;如果当前光线强度大于第一预设值,则利用第一摄像头获取货箱图像;如果当前光线强度小于等于第一预设值,则利用第二摄像头获取货箱图像。Optionally, acquiring the image of the cargo box includes: detecting whether the current light intensity is greater than a first preset value; if the current light intensity is greater than the first preset value, using the first camera to acquire the image of the cargo box; if the current light intensity is less than or equal to If the first preset value is used, the image of the cargo box is obtained by using the second camera.
上述步骤中的第一预设值可以由用户基于需求进行设定。The first preset value in the above steps can be set by the user based on requirements.
上述步骤中第一摄像头可以为RGB摄像头,第二摄像头可以为IR摄像头;其中RGB摄像头可以在光照状态下获取图像;IR摄像头为红外摄像头,可以在黑暗状态下获取图像。In the above steps, the first camera can be an RGB camera, and the second camera can be an IR camera; the RGB camera can acquire images in a light state; the IR camera is an infrared camera, and can acquire images in a dark state.
在一种可选的实施例中,可以通过传感器检测当前光线强度是否大于第一预设值;如果当前光线强度大于第一预设值,则说明当前货箱处于光照状态下,可以利用RGB摄像头获取货箱图像;如果当前光线强度小于等于第一预设值,则说明当前货箱处于黑暗状态下,可以利用IR摄像头获取货箱图像。In an optional embodiment, the sensor can detect whether the current light intensity is greater than the first preset value; if the current light intensity is greater than the first preset value, it means that the current cargo box is in a lighting state, and an RGB camera can be used Obtain the image of the cargo box; if the current light intensity is less than or equal to the first preset value, it means that the current cargo box is in a dark state, and the IR camera can be used to obtain the image of the cargo box.
可选地,在利用多组训练样本对初始模型进行训练,得到第一网络模型之前,该方法还包括:在初始模型的初始层加入归一化层,其中,归一化层用于对多组训练样本进行归一化处理。Optionally, before using multiple sets of training samples to train the initial model to obtain the first network model, the method further includes: adding a normalization layer to the initial layer of the initial model, wherein the normalization layer is used to Group training samples are normalized.
由于第一网络模型训练时同时采用红外图像和普通图像,为了避免红外图像和普通图像两种图像成像的差异,在第一网络模型的最初始层加入批归一化层,对数据进行归一化处理,同时对批归一化层训练将逐渐消除因两种画质带来的影响,使得两种成像映射到同一样本空间,这可提高第一网络模型的货箱状态识别准确度以及识别速度。Since both infrared images and ordinary images are used in the training of the first network model, in order to avoid the difference in imaging between infrared images and ordinary images, a batch normalization layer is added to the initial layer of the first network model to normalize the data. At the same time, the training of the batch normalization layer will gradually eliminate the influence caused by the two image qualities, so that the two images are mapped to the same sample space, which can improve the recognition accuracy of the first network model of the state of the container and the recognition speed.
训练完的第一网络模型可输出货箱状态置信度包括:用于表征货箱顶盖封闭的第一置信度,用于表征货箱内未装载货物的第二置信度,用于表征货箱内装载货物的货物量满足预设量的第三置信度,以及用于表征摄像头异常的第四置信度,用于表征货箱内装载货物的货物量不满足预设量的第五置信度。The trained first network model can output the confidence level of the state of the container, including: a first confidence level for representing the closure of the top cover of the container, a second confidence level for representing the unloaded goods in the container, and a second confidence level for representing the container The third confidence level for the amount of goods loaded in the container meets the preset amount, the fourth confidence level for indicating an abnormality of the camera, and the fifth confidence level for indicating that the amount of goods loaded in the container does not meet the preset amount.
下面结合图6对本公开一种优选的实施例进行详细说明。如图6所示,该方法可以包括如下步骤:A preferred embodiment of the present disclosure will be described in detail below with reference to FIG. 6 . As shown in Figure 6, the method may include the following steps:
步骤S601,获取渣土车货箱图像;Step S601, acquiring the image of the muck truck cargo box;
可选的,可以根据光照强度选择摄像头获取渣土车货箱图像。若当前光照强度大于第一预设值,则说明当前货箱处于光照状态下,可以利用RGB摄像头获取货箱图像;若当前光线强度小于等于第一预设值,则说明当前货箱处于黑暗状态下,可以利用IR摄像头获取货箱图像。Optionally, a camera may be selected according to the light intensity to obtain images of the cargo box of the muck truck. If the current light intensity is greater than the first preset value, it means that the current cargo box is in a light state, and the RGB camera can be used to obtain the image of the cargo box; if the current light intensity is less than or equal to the first preset value, it means that the current cargo box is in a dark state Next, the image of the cargo box can be obtained by using the IR camera.
步骤S602,对货箱图像进行裁剪,以获取到目标区域图像;Step S602, crop the image of the cargo box to obtain the image of the target area;
可选的,可以通过ROI对货箱图像进行裁剪。Optionally, the cargo box image can be cropped by ROI.
步骤S603,对目标区域图像进行预处理;Step S603, preprocessing the target area image;
可选的,预处理可以为缩放处理和归一化处理;可以将目标区域图像缩放至固定尺寸:128*128;可以将目标区域图像的像素减去均值128,再除以方差256。Optionally, the preprocessing can be scaling processing and normalization processing; the target area image can be scaled to a fixed size: 128*128; the pixels of the target area image can be subtracted from the mean value of 128, and then divided by the variance of 256.
步骤S604,将预处理后的目标区域图像送入CNN网络中,得到货箱状态置信度。Step S604, sending the preprocessed image of the target area into the CNN network to obtain the confidence level of the state of the container.
可选的,货箱状态置信度包括如下之一:货箱顶盖封闭置信度、货箱内未装载货物置信度、货箱内装载货物量满足预设值置信度、摄像头异常置信度和货箱内装载货物量不满足预设值置信度。Optionally, the confidence level of the state of the container includes one of the following: confidence level of the top cover of the container being closed, confidence level of no goods loaded in the container, confidence level of the amount of goods loaded in the container meeting a preset value, confidence level of camera abnormality, and confidence level of the cargo box. The amount of goods loaded in the box does not meet the preset confidence level.
需要说明的是,货箱顶盖封闭表示渣土车的盖子完全闭合;货箱内未装载货物、货箱内装载货物量满足预设值和货箱内装载货物量不满足预设量表示渣土车的顶盖处于开启状态;摄像头异常表示摄像头被遮挡或者摄像头发生偏转导致进行有效检测。It should be noted that if the top cover of the cargo box is closed, it means that the cover of the muck truck is completely closed; no cargo is loaded in the cargo box, the amount of goods loaded in the cargo box meets the preset value, and the amount of cargo loaded in the cargo box does not meet the preset amount, indicating that the slag truck is completely closed. The top cover of the dirt truck is open; if the camera is abnormal, it means that the camera is blocked or the camera is deflected, resulting in effective detection.
步骤S605,基于货箱状态置信度和人工设计逻辑规则,判定渣土车货箱状态。Step S605, based on the confidence of the state of the container and the artificially designed logic rule, determine the state of the container of the muck truck.
可选的,可以基于货箱状态置信度和渣土车货箱盖板信号,判定渣土车货箱状态。Optionally, the state of the container of the muck truck may be determined based on the confidence level of the state of the container and the signal of the cover plate of the container of the muck truck.
示例性的,可以在渣土车货箱盖板信号发出30s之内,根据30s内采集的多帧图像对应的多帧货箱状态置信度输入支持向量机输出最终货箱状态置信度,根据上述货箱状态置信度判定渣土车货箱状态为货箱内未装载货物还是货箱内装载货物量满足预设值。Exemplarily, within 30s of sending the signal from the cargo box cover of the muck truck, the confidence level of the state of the container of the multi-frame corresponding to the multi-frame images collected within 30s can be input to the support vector machine and output the confidence level of the final state of the container. According to the above The confidence level of the cargo box status determines whether the cargo box status of the muck truck is not loaded with cargo in the cargo box or whether the amount of cargo loaded in the cargo box meets the preset value.
可选的,可以基于货箱状态置信度和渣土车的运输状态,判定渣土车货箱状态。Optionally, the state of the container of the muck truck may be determined based on the confidence level of the state of the container and the transport state of the muck truck.
下面结合图7对本公开一种第一网络模型训练的优先的实施例进行详细说明。如图7,该方法可以包括如下步骤:A preferred embodiment of the first network model training of the present disclosure will be described in detail below with reference to FIG. 7 . As shown in Figure 7, the method may include the following steps:
步骤S701,获取渣土车原始货箱图像;Step S701, obtaining an image of the original cargo box of the muck truck;
上述步骤中渣土车的原始货箱图像可以通过摄像头获取的,也可以通过网络获取,还可以从本地存储的文件中获取,此处不做任何限定。The original cargo box image of the muck truck in the above steps can be obtained through a camera, can also be obtained through a network, and can also be obtained from a file stored locally, which is not limited here.
可选的,若渣土车的原始货箱图像是通过摄像头获取的,则可以根据光照强度选 择摄像头获取渣土车原始货箱图像。若当前光照强度大于第一预设值,则说明当前货箱处于光照状态下,可以利用RGB摄像头获取原始货箱图像;若当前光线强度小于等于第一预设值,则说明当前货箱处于黑暗状态下,可以利用IR摄像头获取原始货箱图像。Optionally, if the original cargo box image of the muck truck is obtained through a camera, a camera can be selected according to the light intensity to obtain the original cargo box image of the muck truck. If the current light intensity is greater than the first preset value, it means that the current cargo box is in the light state, and the RGB camera can be used to obtain the original image of the cargo box; if the current light intensity is less than or equal to the first preset value, it means that the current cargo box is in darkness In this state, the IR camera can be used to obtain the original image of the cargo box.
步骤S702,对原始货箱图像进行扰动处理,得到多组原始货箱图像;Step S702, performing perturbation processing on the original cargo box image to obtain multiple sets of original cargo box images;
可选的,可以对原始货箱图像进行旋转、平移、缩放、加噪、模糊、光照变化、通道变化,得到多组原始货箱图像。Optionally, rotation, translation, scaling, noise addition, blurring, illumination change, and channel change may be performed on the original cargo box image to obtain multiple sets of original cargo box images.
可选的,可以对原始货箱图像随机选择0至15左右旋转操作。Optionally, 0 to 15 left and right rotation operations may be randomly selected for the original cargo box image.
可选的,可以对原始货箱图像上下左右移动0至50个像素平移操作。Optionally, the original cargo box image can be moved up, down, left, and right by 0 to 50 pixels in a translation operation.
可选的,可以对原始货箱图像随机进行0.8至1.2被图像缩放操作。Optionally, an image scaling operation of 0.8 to 1.2 may be randomly performed on the original cargo box image.
可选的,可以对原始货箱图像随机加入均值为0至4.0的高斯或椒盐噪声。Optionally, Gaussian or salt and pepper noise with a mean value of 0 to 4.0 can be randomly added to the original cargo box image.
可选的,可以对原始货箱图像随机加入模板为0至9的高斯模糊。Optionally, a Gaussian blur with templates ranging from 0 to 9 can be randomly added to the original cargo box image.
可选的,可以对原始货箱图像随机对每个像素乘以0.8至1.2的光照变换。Optionally, a lighting transformation of 0.8 to 1.2 can be randomly multiplied per pixel on the original crate image.
可选的,可以对原始货箱图像的通道进行转换,例如,将RGB通道转化为BRG通道。Optionally, the channels of the original crate image can be transformed, eg, RGB channels to BRG channels.
步骤S703,对多组原始货箱图像进行剪裁处理,得到多组目标区域图像;Step S703, performing clipping processing on multiple sets of original cargo box images to obtain multiple sets of target area images;
可选的,可以通过ROI对多组原始货箱图像进行剪裁,得到多组目标区域图像。Optionally, multiple sets of original cargo box images may be cropped through the ROI to obtain multiple sets of target area images.
步骤S704,对多组目标区域图像进行预处理,得到多组训练样本;Step S704, preprocessing multiple groups of target area images to obtain multiple groups of training samples;
其中,预处理包括缩放处理和归一化处理。Among them, the preprocessing includes scaling and normalization.
可选的,可以将多组目标区域图像缩放至固定尺寸:128*128,然后再将缩放处理后的多组目标区域图像的像素减去均值128,再除以方差256,得到多组训练样本。Optionally, multiple sets of target area images can be scaled to a fixed size: 128*128, and then the pixels of the scaled multiple sets of target area images are subtracted from the mean value of 128, and then divided by the variance of 256 to obtain multiple sets of training samples. .
步骤S705,构建第一网络模型,将多组训练样本送入第一网络模型中进行训练。Step S705, constructing a first network model, and sending multiple sets of training samples into the first network model for training.
可选的,构建的第一网络模型可以为ResNet-10。Optionally, the constructed first network model may be ResNet-10.
可选的,经过训练后的第一网络模型输出的置信度有五个类别:货箱顶盖封闭置信度、货箱内未装载货物置信度、货箱内装载货物的货物量满足预设量置信度、摄像头异常置信度和货箱内装载货物的货物量不满足预设量置信度。Optionally, the confidence level output by the first network model after training has five categories: the confidence level of the top cover of the cargo box being closed, the confidence level of the cargo not loaded in the cargo box, and the amount of the cargo loaded in the cargo box meeting the preset amount. The confidence level, the camera anomaly confidence level, and the amount of goods loaded in the container do not meet the preset confidence level.
需要说明的是,货箱顶盖封闭可以为货箱在装载货物之后可以正常的封闭;货箱 内未装载货物可以为货箱顶盖开启,且货箱内空载;货箱内装载货物的货物量满足预设量可以为货箱内装载的货物量太多造成货箱顶盖无法正常封闭从而导致货箱顶盖无法正常封闭;摄像头异常可以为摄像头被遮挡或者摄像头发生偏转,导致无法有效检测货箱内的状态。It should be noted that the closure of the top cover of the cargo box can mean that the cargo box can be normally closed after loading goods; the top cover of the cargo box can be opened when no cargo is loaded in the cargo box, and the cargo box is empty; If the amount of goods meets the preset amount, it may be that the amount of goods loaded in the container is too large, so that the top cover of the container cannot be closed normally. Check the condition inside the cargo box.
实施例2Example 2
根据本公开实施例,还提供了一种货箱状态的检测装置,该装置可以执行上述实施例中的货箱状态的检测方法,具体实现方式和优选应用场景与上述实施例相同,在此不做赘述。According to an embodiment of the present disclosure, a device for detecting the state of a cargo box is also provided. The device can execute the method for detecting the state of a cargo box in the above-mentioned embodiment. The specific implementation manner and preferred application scenario are the same as those of the above-mentioned embodiment. Do repeat.
图8是根据本公开实施例的一种货箱状态的检测装置的示意图,如图8所示,该装置包括:FIG. 8 is a schematic diagram of a device for detecting the state of a cargo box according to an embodiment of the present disclosure. As shown in FIG. 8 , the device includes:
获取组件82,配置为获取货箱图像。An acquisition component 82 is configured to acquire images of the cargo box.
处理组件84,配置为利用第一网络模型对货箱图像进行处理,得到货箱状态置信度。The processing component 84 is configured to process the image of the container by using the first network model to obtain the confidence level of the state of the container.
确定组件86,配置为基于货箱状态置信度,确定货箱状态,其中,货箱状态包括如下之一:货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常、货箱内装载货物的货物量不满足预设量。The determining component 86 is configured to determine the status of the cargo box based on the confidence level of the status of the cargo box, wherein the status of the cargo box includes one of the following: the top cover of the cargo box is closed, no cargo is loaded in the cargo box, and the amount of cargo loaded in the cargo box is sufficient The preset amount, the camera is abnormal, and the amount of goods loaded in the container does not meet the preset amount.
此处需要说明的是,上述获取组件82、处理组件84和确定组件86可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能,终端也可以是智能手机(如Android手机、iOS手机等)、平板电脑、掌上电脑以及移动互联网设备(Mobile Internet Devices,MID)、PAD等终端设备。It should be noted here that the above-mentioned acquiring component 82, processing component 84 and determining component 86 may be run in a terminal as a part of the device, and the functions implemented by the above-mentioned components may be executed by a processor in the terminal, and the terminal may also be a smart phone. (such as Android mobile phones, iOS mobile phones, etc.), tablet computers, PDAs, and terminal devices such as Mobile Internet Devices (MID) and PAD.
需要说明的是,上述获取组件82、处理组件84和确定组件86可以设置为执行本公开实施例中的步骤S102至步骤S106。上述组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that, the above-mentioned obtaining component 82, processing component 84, and determining component 86 may be configured to execute steps S102 to S106 in the embodiments of the present disclosure. The examples and application scenarios implemented by the above components and corresponding steps are the same, but are not limited to the contents disclosed in the above embodiments.
可选地,处理组件包括:剪裁组件,配置为对货箱图像进行剪裁,得到目标区域图像;预处理组件,配置为对目标区域图像进行预处理,得到处理后的图像;输入组件,配置为将处理后的图像输入到第一网络模型中,得到货箱状态置信度。Optionally, the processing component includes: a cropping component, configured to crop an image of the cargo box to obtain an image of the target area; a preprocessing component, configured to preprocess the image of the target area to obtain a processed image; an input component, configured as The processed image is input into the first network model to obtain the confidence level of the state of the container.
此处需要说明的是,上述剪裁组件、预处理组件和输入组件可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能。It should be noted here that the above-mentioned trimming component, pre-processing component and input component may run in the terminal as a part of the apparatus, and the functions implemented by the above-mentioned components may be executed by a processor in the terminal.
需要说明的是,上述剪裁组件、预处理组件和输入组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the above-mentioned trimming component, preprocessing component and input component are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the contents disclosed in the above-mentioned embodiments.
可选地,处理模块中的货箱状态置信度包括表征货箱顶盖封闭的第一置信度,用于表征货箱内未装载货物的第二置信度,用于表征货箱内装载货物的货物量满足预设量的第三置信度,用于表征摄像头异常的第四置信度,和,用于表征述货箱内装载货物的货物量不满足预设量的第五置信度。Optionally, the confidence level of the state of the container in the processing module includes a first confidence level for characterizing the closure of the top cover of the container, a second confidence level for characterizing the unloaded goods in the container, and a second confidence level for characterizing the loaded goods in the container. The third confidence level that the quantity of goods satisfies the preset quantity, the fourth confidence level that is used to represent the abnormality of the camera, and the fifth confidence level that is used to represent that the quantity of goods loaded in the cargo box does not meet the preset quantity.
可选地,处理组件还配置为提取多帧货箱图像对应的多帧货箱状态置信度;处理组件还配置为将多帧货箱状态置信度输入第二网络模型,获取货箱状态置信度。Optionally, the processing component is further configured to extract the multi-frame container state confidence level corresponding to the multi-frame container images; the processing component is further configured to input the multi-frame container state confidence level into the second network model, and obtain the container state confidence level. .
需要说明的是,上述处理组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the examples and application scenarios implemented by the foregoing processing components and corresponding steps are the same, but are not limited to the contents disclosed in the foregoing embodiments.
可选地,确定组件包括:第一提取组件,配置为提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度中最高值对应的货箱状态为货箱状态;或,第二提取组件,配置为提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度大于预设阈值的货箱状态为货箱状态;或,第三提取组件,配置为提取第一置信度、第二置信度、第三置信度、第四置信度和第五置信度中最高值,并且大于预设阈值对应的货箱状态为货箱状态。Optionally, the determining component includes: a first extracting component, configured to extract the status of the container corresponding to the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level as cargo. or, a second extracting component, configured to extract the container state whose first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level are greater than the preset threshold as the container state; Or, the third extraction component is configured to extract the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level, and the status of the container corresponding to the value greater than the preset threshold is box status.
此处需要说明的是,上述第一提取组件、第二提取组件或第三提取组件可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能。It should be noted here that the above-mentioned first extracting component, second extracting component or third extracting component may run in a terminal as a part of the apparatus, and the functions implemented by the above-mentioned components may be executed by a processor in the terminal.
需要说明的是,上述第一提取组件、第二提取组件或第三提取组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the examples and application scenarios implemented by the first extracting component, the second extracting component or the third extracting component and the corresponding steps are the same, but are not limited to the contents disclosed in the above embodiments.
可选地,确定组件还配置为基于货箱状态置信度和预设规则,确定货箱状态,其中,预设规则用于表征预设规则用于表征货箱状态置信度的优先级。Optionally, the determining component is further configured to determine the state of the container based on the confidence of the state of the container and a preset rule, wherein the preset rule is used to represent the priority of the preset rule used to represent the confidence of the state of the container.
需要说明的是,上述确定组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the examples and application scenarios implemented by the above determining components and corresponding steps are the same, but are not limited to the contents disclosed in the above embodiments.
可选地,确定组件还包括:第一判断组件,配置为判断第四置信度是否大于第五预设值,若第四置信度大于第五预设值,则确定货箱状态为摄像头异常;第二判断组件,配置为若第四置信度小于等于第五预设值,则判断第一置信度是否大于第二预设值,若第一置信度大于第二预设值,则确定货箱状态为货箱顶盖封闭;第三判断组件,配置为若第一置信度小于等于第二预设值,则判断第二置信度是否大于第三预设值,若第二置信度大于第三预设值,则确定货箱状态为货箱内未装载货物;第四判断组件,配置为若第二置信度小于等于第三预设值,则判断第三置信度是否大于第四预设值,若第三置信度大于第四预设值,则确定货箱状态为货箱内装载货物的货物量满足预设量;第五判断组件,配置为若第三置信度小于等于第四预设值,则判断第五置信度是否大于第六预设值,若第五置信度大于第六预设值,则确定货箱状态为货箱内装载货 物的货物量不满足预设量。Optionally, the determining component further includes: a first judging component, configured to judge whether the fourth confidence level is greater than the fifth preset value, and if the fourth confidence level is greater than the fifth preset value, determine that the state of the cargo box is an abnormality of the camera; The second judging component is configured to judge whether the first confidence level is greater than the second preset value if the fourth confidence level is less than or equal to the fifth preset value, and determine whether the first confidence level is greater than the second preset value. The state is that the top cover of the cargo box is closed; the third judging component is configured to judge whether the second confidence level is greater than the third preset value if the first confidence level is less than or equal to the second preset value, and if the second confidence level is greater than the third If the second confidence level is less than or equal to the third preset value, it is determined whether the third confidence level is greater than the fourth preset value. , if the third confidence level is greater than the fourth preset value, it is determined that the state of the cargo box is that the amount of goods loaded in the cargo box meets the preset amount; the fifth judgment component is configured so that if the third confidence level is less than or equal to the fourth preset value value, then determine whether the fifth confidence level is greater than the sixth preset value, and if the fifth confidence level is greater than the sixth preset value, it is determined that the state of the container is that the amount of goods loaded in the container does not meet the preset amount.
此处需要说明的是,上述第一判断组件、第二判断组件、第三判断组件、第四判断组件和第五判断组件可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能。It should be noted here that the above-mentioned first judging component, second judging component, third judging component, fourth judging component and fifth judging component may run in the terminal as a part of the device, and may be processed by a processor in the terminal. Execute the function implemented by the above components.
需要说明的是,上述第一判断组件、第二判断组件、第三判断组件、第四判断组件和第五判断组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the examples and application scenarios implemented by the first judgment component, the second judgment component, the third judgment component, the fourth judgment component, and the fifth judgment component are the same as those implemented by the corresponding steps, but are not limited to those in the above embodiments. public content.
可选地,预处理单元中的预处理包括如下至少之一:缩放处理和归一化处理。Optionally, the preprocessing in the preprocessing unit includes at least one of the following: scaling processing and normalization processing.
可选地,获取组件还配置为获取原始货箱图像;处理组件还配置为对原始货箱图像进行处理,得到多组训练样本;该装置还包括:训练组件,配置为利用多组训练样本对初始模型进行训练,得到第一网络模型。Optionally, the acquiring component is further configured to acquire the original cargo box image; the processing component is further configured to process the original cargo box image to obtain multiple sets of training samples; the device further includes: a training component configured to use multiple sets of training samples to The initial model is trained to obtain the first network model.
此处需要说明的是,上述第一判断组件、第二判断组件、第三判断组件、第四判断组件和第五判断组件可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能。It should be noted here that the above-mentioned first judging component, second judging component, third judging component, fourth judging component and fifth judging component may run in the terminal as a part of the device, and may be processed by a processor in the terminal. Execute the function implemented by the above components.
需要说明的是,上述第一判断组件、第二判断组件、第三判断组件、第四判断组件和第五判断组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the examples and application scenarios implemented by the first judgment component, the second judgment component, the third judgment component, the fourth judgment component, and the fifth judgment component are the same as those implemented by the corresponding steps, but are not limited to those in the above embodiments. public content.
可选地,处理组件还包括:扰动处理组件,配置为对原始货箱图像进行扰动处理,得到多组原始货箱图像;剪裁组件还配置为对多组原始货箱图像进行剪裁处理,得到多组目标区域图像;预处理组件还配置为对多组目标区域图像进行预处理,得到多组训练样本。Optionally, the processing component further includes: a perturbation processing component configured to perform perturbation processing on the original cargo box images to obtain multiple sets of original cargo box images; the trimming component is further configured to perform clipping processing on multiple sets of original cargo box images to obtain multiple groups of target area images; the preprocessing component is further configured to preprocess multiple groups of target area images to obtain multiple groups of training samples.
此处需要说明的是,上述扰动处理组件可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能。It should be noted here that the above-mentioned disturbance processing component may run in the terminal as a part of the apparatus, and the functions implemented by the above-mentioned component may be executed by a processor in the terminal.
需要说明的是,上述扰动处理组件、剪裁组件和预处理组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the above disturbance processing component, trimming component and preprocessing component have the same examples and application scenarios as the corresponding steps, but are not limited to the contents disclosed in the above embodiments.
可选地,扰动处理组件中的扰动处理包括如下至少之一:旋转、平移、缩放、加噪、模糊、光照变化、通道变化。Optionally, the disturbance processing in the disturbance processing component includes at least one of the following: rotation, translation, scaling, noise addition, blurring, illumination change, and channel change.
可选地,获取组件还包括:检测组件,配置为检测当前光线强度是否大于第一预设值;第一获取组件,配置为在当前光线强度大于第一预设值时,则利用第一摄像头获取货箱图像;第二获取组件,配置为在当前光线强度小于等于第一预设值时,则利 用第二摄像头获取货箱图像。Optionally, the acquisition component further includes: a detection component configured to detect whether the current light intensity is greater than the first preset value; the first acquisition component configured to use the first camera when the current light intensity is greater than the first preset value The image of the cargo box is acquired; the second acquisition component is configured to use the second camera to acquire the image of the cargo box when the current light intensity is less than or equal to the first preset value.
此处需要说明的是,上述检测组件、第一获取组件和第二获取组件可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能。It should be noted here that the above-mentioned detection component, the first acquisition component and the second acquisition component may run in the terminal as a part of the apparatus, and the functions implemented by the above components may be executed by a processor in the terminal.
需要说明的是,上述检测组件、第一获取组件和第二获取组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the examples and application scenarios implemented by the detection component, the first acquisition component, and the second acquisition component are the same as those implemented by the corresponding steps, but are not limited to the contents disclosed in the foregoing embodiments.
可选地,该装置还包括,加入组件,配置为在初始模型的初始层加入归一化层,其中,归一化层用于对多组训练样本进行归一化处理。Optionally, the apparatus further includes an adding component configured to add a normalization layer to the initial layer of the initial model, wherein the normalization layer is used for normalizing multiple groups of training samples.
此处需要说明的是,上述加入组件可以作为装置的一部分运行在终端中,可以通过终端中的处理器来执行上述组件实现的功能。It should be noted here that the above-mentioned adding component may run in the terminal as a part of the apparatus, and the functions implemented by the above-mentioned component may be executed by a processor in the terminal.
需要说明的是,上述加入组件与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。It should be noted that the examples and application scenarios implemented by the above-mentioned adding components and corresponding steps are the same, but are not limited to the contents disclosed in the above-mentioned embodiments.
实施例3Example 3
根据本公开实施例,还提供了一种计算机可读存储介质,计算机可读存储介质包括存储的程序,其中,在程序运行时控制计算机可读存储介质所在设备执行上述实施例1中的货箱状态的检测方法。According to an embodiment of the present disclosure, a computer-readable storage medium is also provided, where the computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the cargo box in the above-mentioned Embodiment 1 Status detection method.
实施例4Example 4
根据本公开实施例,还提供了一种处理器,处理器用于运行程序,其中,程序运行时执行上述实施例1中的货箱状态的检测方法。According to an embodiment of the present disclosure, a processor is also provided, and the processor is used for running a program, wherein the method for detecting the state of a cargo box in the above-mentioned Embodiment 1 is executed when the program is running.
上述本公开实施例序号仅仅为了描述,不代表实施例的优劣。The above-mentioned serial numbers of the embodiments of the present disclosure are only for description, and do not represent the advantages or disadvantages of the embodiments.
在本公开的上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。In the above-mentioned embodiments of the present disclosure, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
在本申请所提供的几个实施例中,应该理解到,所揭露的技术内容,可通过其它的方式实现。其中,以上所描述的装置实施例仅仅是示意性的,例如单元的划分,可以为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,单元或模块的间接耦合或通信连接,可以是电性或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are only illustrative, for example, the division of units may be a logical function division, and there may be other division methods in actual implementation, for example, multiple units or components may be combined or integrated into Another system, or some features can be ignored, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of units or modules, and may be in electrical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到 多个单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components shown as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
另外,在本公开各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present disclosure may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本公开的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可为个人计算机、服务器或者网络设备等)执行本公开各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。The integrated unit, if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium. Based on such understanding, the technical solutions of the present disclosure essentially or the parts that contribute to the prior art, or all or part of the technical solutions can be embodied in the form of software products, and the computer software products are stored in a storage medium , including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present disclosure. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes .
以上所述仅是本公开的优选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本公开原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本公开的保护范围。The above are only the preferred embodiments of the present disclosure. It should be pointed out that for those skilled in the art, without departing from the principles of the present disclosure, several improvements and modifications can be made. It should be regarded as the protection scope of the present disclosure.
通过在获取到货箱图像之后,利用第一网络模型对货箱图像进行处理,得到货箱状态置信度,然后基于货箱状态置信度确定货箱状态,实现了在检测货箱状态时,不仅能检测出货箱的顶盖是否有效闭合,还能检测货箱内是否装载货物,以及检测货箱内装载货物的容量,并且在获取的货箱图像未显示货箱状态时可以检测出摄像头异常,从而有效的检测货箱状态,相较于现有技术中使用雷达实现检测的方案,成本有所降低,并且解决了相关技术中检测货箱状态的方法无法检测货箱内是否装载货物的技术问题。After obtaining the image of the cargo box, the first network model is used to process the image of the cargo box to obtain the confidence of the state of the cargo box, and then the state of the cargo box is determined based on the confidence of the state of the cargo box. It can detect whether the top cover of the shipping box is effectively closed, and can also detect whether the cargo box is loaded with goods, and detect the capacity of the goods loaded in the cargo box, and can detect the abnormality of the camera when the obtained image of the cargo box does not show the status of the cargo box , so as to effectively detect the status of the cargo box, compared with the solution of using radar to realize detection in the prior art, the cost is reduced, and the method of detecting the status of the cargo box in the related art can not detect whether the cargo box is loaded with goods. question.
Claims (16)
- 一种货箱状态的检测方法,包括:A method for detecting the state of a cargo box, comprising:获取货箱图像;Get the image of the cargo box;利用第一网络模型对所述货箱图像进行处理,得到货箱状态置信度;Using the first network model to process the image of the container to obtain the confidence level of the state of the container;基于所述货箱状态置信度,确定货箱状态,其中,所述货箱状态包括如下之一:货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常、货箱内装载货物的货物量不满足预设量。Based on the confidence level of the state of the cargo box, the state of the cargo box is determined, wherein the state of the cargo box includes one of the following: the top cover of the cargo box is closed, no cargo is loaded in the cargo box, and the amount of cargo loaded in the cargo box meets a preset value volume, abnormal camera, and the amount of goods loaded in the container does not meet the preset amount.
- 根据权利要求1所述的方法,其中,利用第一网络模型对所述货箱图像进行处理,得到货箱状态置信度,包括:The method according to claim 1, wherein, using the first network model to process the image of the cargo box to obtain the confidence level of the state of the cargo box, comprising:对所述货箱图像进行剪裁,得到目标区域图像;Cropping the image of the cargo box to obtain an image of the target area;对所述目标区域图像进行预处理,得到处理后的图像;Preprocessing the target area image to obtain a processed image;将所述处理后的图像输入到所述第一网络模型中,得到所述货箱状态置信度。The processed image is input into the first network model to obtain the confidence level of the state of the cargo box.
- 根据权利要求2所述的方法,其中,所述货箱状态置信度包括:用于表征所述货箱顶盖封闭的第一置信度,用于表征所述货箱内未装载货物的第二置信度,用于表征所述货箱内装载货物的货物量满足所述预设量的第三置信度,用于表征所述摄像头异常的第四置信度,和,用于表征所述货箱内装载货物的货物量不满足预设量的第五置信度。3. The method of claim 2, wherein the container state confidence level comprises: a first confidence level characterizing the closure of the container top lid, a second confidence level characterizing the unloaded cargo in the container a confidence level, a third confidence level used to characterize that the amount of goods loaded in the container satisfies the preset amount, a fourth confidence level used to characterize the abnormality of the camera, and a confidence level used to characterize the container The fifth confidence level that the quantity of goods loaded inside does not meet the preset quantity.
- 根据权利要求1所述的方法,其中,利用第一网络模型对所述货箱图像进行处理,得到货箱状态置信度,还包括:The method according to claim 1, wherein the first network model is used to process the image of the cargo box to obtain the confidence level of the state of the cargo box, further comprising:提取多帧所述货箱图像对应的多帧货箱状态置信度;extracting the multi-frame container state confidence levels corresponding to the multi-frame container images;将所述多帧货箱状态置信度输入第二网络模型,获取所述货箱状态置信度。The multi-frame container state confidence level is input into the second network model to obtain the container state confidence level.
- 根据权利要求3所述的方法,其中,基于所述货箱状态置信度,确定货箱状态,包括:The method of claim 3, wherein determining the state of the container based on the confidence level of the state of the container comprises:提取所述第一置信度、所述第二置信度、所述第三置信度、所述第四置信度和所述第五置信度中最高值对应的货箱状态为所述货箱状态;或,extracting the container state corresponding to the highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level as the container state; or,提取所述第一置信度、所述第二置信度、所述第三置信度、所述第四置信度和所述第五置信度大于预设阈值的货箱状态为所述货箱状态;或,extracting the container state whose first confidence level, the second confidence level, the third confidence level, the fourth confidence level and the fifth confidence level are greater than a preset threshold as the container state; or,提取所述第一置信度、所述第二置信度、所述第三置信度、所述第四置信度和所述第五置信度中最高值,并且大于预设阈值对应的货箱状态为所述货箱状态。The highest value among the first confidence level, the second confidence level, the third confidence level, the fourth confidence level, and the fifth confidence level is extracted, and the state of the container that is greater than the preset threshold value is: The state of the box.
- 根据权利要求3所述的方法,其中,基于所述货箱状态置信度,确定货箱状态,包括:基于所述货箱状态置信度和预设规则,确定所述货箱状态,其中,所述预设规则用于表征所述货箱状态置信度的优先级。The method according to claim 3, wherein determining the status of the cargo box based on the confidence level of the status of the cargo box comprises: determining the status of the cargo box based on the confidence level of the status of the cargo box and a preset rule, wherein the The preset rule is used to represent the priority of the confidence level of the state of the container.
- 根据权利要求6所述的方法,其中,基于所述货箱状态置信度,确定所述货箱状态,包括:6. The method of claim 6, wherein determining the container state based on the container state confidence comprises:判断所述第四置信度是否大于第五预设值;judging whether the fourth confidence level is greater than a fifth preset value;若所述第四置信度大于所述第五预设值,则确定所述货箱状态为所述摄像头异常;If the fourth confidence level is greater than the fifth preset value, it is determined that the state of the cargo box is an abnormality of the camera;若所述第四置信度小于等于所述第五预设值,则判断所述第一置信度是否大于第二预设值;If the fourth confidence level is less than or equal to the fifth preset value, determine whether the first confidence level is greater than the second preset value;若所述第一置信度大于所述第二预设值,则确定所述货箱状态为所述货箱顶盖封闭;If the first confidence level is greater than the second preset value, determining that the state of the cargo box is that the top cover of the cargo box is closed;若所述第一置信度小于等于所述第二预设值,则判断所述第二置信度是否大于第三预设值;If the first confidence level is less than or equal to the second preset value, determine whether the second confidence level is greater than a third preset value;若所述第二置信度大于所述第三预设值,则确定所述货箱状态为所述货箱内未装载货物;If the second confidence level is greater than the third preset value, it is determined that the state of the cargo box is that no cargo is loaded in the cargo box;若所述第二置信度小于等于所述第三预设值,则判断所述第三置信度是否大于第四预设值;If the second confidence level is less than or equal to the third preset value, determine whether the third confidence level is greater than a fourth preset value;若所述第三置信度大于所述第四预设值,则确定所述货箱状态为所述货箱内装载货物的货物量满足预设量;If the third confidence level is greater than the fourth preset value, determining that the state of the cargo box is that the amount of goods loaded in the cargo box meets the preset amount;若所述第三置信度小于等于所述第四预设值,则判断所述第五置信度是否大于第六预设值;If the third confidence level is less than or equal to the fourth preset value, determine whether the fifth confidence level is greater than the sixth preset value;若所述第五置信度大于所述第六预设值,则确定所述货箱状态为所述货箱内装载货物的货物量不满足预设量。If the fifth confidence level is greater than the sixth preset value, it is determined that the state of the cargo box is that the amount of goods loaded in the cargo box does not meet the preset amount.
- 根据权利要求2所述的方法,其中,所述预处理包括如下至少之一:缩放处理和归一化处理。The method of claim 2, wherein the preprocessing includes at least one of: scaling and normalization.
- 根据权利要求1所述的方法,其中,所述方法还包括:The method of claim 1, wherein the method further comprises:获取原始货箱图像;Get the original crate image;对所述原始货箱图像进行处理,得到多组训练样本;processing the original cargo box image to obtain multiple sets of training samples;利用所述多组训练样本对初始模型进行训练,得到所述第一网络模型。The initial model is trained by using the multiple sets of training samples to obtain the first network model.
- 根据权利要求9所述的方法,其中,对所述原始货箱图像进行处理,得到多组训练样本,包括:The method according to claim 9, wherein the original cargo box image is processed to obtain multiple sets of training samples, including:对所述原始货箱图像进行扰动处理,得到多组原始货箱图像;Performing perturbation processing on the original cargo box image to obtain multiple sets of original cargo box images;对所述多组原始货箱图像进行剪裁处理,得到多组目标区域图像;Perform clipping processing on the multiple sets of original cargo box images to obtain multiple sets of target area images;对所述多组目标区域图像进行预处理,得到所述多组训练样本。The multiple sets of target area images are preprocessed to obtain the multiple sets of training samples.
- 根据权利要求10所述的方法,其中,所述扰动处理包括如下至少之一:旋转、平移、缩放、加噪、模糊、光照变化和通道变化。11. The method of claim 10, wherein the perturbation processing includes at least one of: rotation, translation, scaling, noise, blur, illumination change, and channel change.
- 根据权利要求1所述的方法,其中,获取货箱图像,包括:The method of claim 1, wherein acquiring an image of the cargo box comprises:检测当前光线强度是否大于第一预设值;Detecting whether the current light intensity is greater than the first preset value;如果所述当前光线强度大于所述第一预设值,则利用第一摄像头获取所述货箱图像;If the current light intensity is greater than the first preset value, use the first camera to acquire the image of the cargo box;如果所述当前光线强度小于等于所述第一预设值,则利用第二摄像头获取所述货箱图像。If the current light intensity is less than or equal to the first preset value, use the second camera to acquire the image of the cargo box.
- 根据权利要求9所述的方法,其中,在利用所述多组训练样本对初始模型进行训练,得到所述第一网络模型之前,所述方法还包括:The method according to claim 9, wherein, before using the multiple sets of training samples to train an initial model to obtain the first network model, the method further comprises:在所述初始模型的初始层加入归一化层,其中,所述归一化层用于对所述多组训练样本进行归一化处理。A normalization layer is added to the initial layer of the initial model, wherein the normalization layer is used for normalizing the multiple groups of training samples.
- 一种货箱状态的检测装置,包括:A detection device for the state of a cargo box, comprising:获取模块,用于获取货箱图像;The acquisition module is used to acquire the image of the cargo box;处理模块,用于利用第一网络模型对所述货箱图像进行处理,得到货箱状态置信度;a processing module, configured to process the image of the cargo box by using the first network model to obtain the confidence level of the status of the cargo box;确定模块,用于基于所述货箱状态置信度,确定货箱状态,其中,所述货箱状态包括如下之一:货箱顶盖封闭、货箱内未装载货物、货箱内装载货物的货物量满足预设量、摄像头异常、货箱内装载货物的货物量不满足预设量。The determining module is configured to determine the state of the cargo box based on the confidence level of the state of the cargo box, wherein the state of the cargo box includes one of the following: the top cover of the cargo box is closed, the cargo is not loaded in the cargo box, and the cargo is loaded in the cargo box. The amount of goods meets the preset amount, the camera is abnormal, and the amount of goods loaded in the container does not meet the preset amount.
- 一种存储介质,所述存储介质包括存储的程序,其中,在所述程序运行时控制所述存储介质所在设备执行权利要求1至13中任意一项所述的货箱状态的检测方法。A storage medium, the storage medium comprising a stored program, wherein when the program is executed, a device where the storage medium is located is controlled to execute the method for detecting the state of a cargo box according to any one of claims 1 to 13.
- 一种处理器,所述处理器用于运行程序,其中,所述程序运行时执行权利要求1 至13中任意一项所述的货箱状态的检测方法。A processor, which is used for running a program, wherein the method for detecting the state of a cargo box according to any one of claims 1 to 13 is executed when the program is running.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
DE112021006736.2T DE112021006736T5 (en) | 2020-12-28 | 2021-12-27 | METHOD AND DEVICE FOR DETECTING THE CONDITION OF A LOADING TRAY |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011589677.5 | 2020-12-28 | ||
CN202011589677.5A CN114693588A (en) | 2020-12-28 | 2020-12-28 | Method and device for detecting state of container |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2022143562A1 true WO2022143562A1 (en) | 2022-07-07 |
Family
ID=82131782
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2021/141762 WO2022143562A1 (en) | 2020-12-28 | 2021-12-27 | Cargo container state detection method and apparatus |
Country Status (3)
Country | Link |
---|---|
CN (1) | CN114693588A (en) |
DE (1) | DE112021006736T5 (en) |
WO (1) | WO2022143562A1 (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103869789A (en) * | 2014-03-26 | 2014-06-18 | 卢大伟 | Transported cargo quality monitoring method and system based on internet of things |
CN107122747A (en) * | 2017-04-28 | 2017-09-01 | 北京理工大学 | A kind of railway carriage state non-contact detection device and method |
CN108416901A (en) * | 2018-03-27 | 2018-08-17 | 合肥美的智能科技有限公司 | Method and device for identifying goods in intelligent container and intelligent container |
US20180260772A1 (en) * | 2017-01-31 | 2018-09-13 | Focal Systems, Inc | Out-of-stock detection based on images |
CN109003304A (en) * | 2018-07-12 | 2018-12-14 | 南京云计趟信息技术有限公司 | A kind of camera angle mobile detecting system and method based on deep learning |
CN109341763A (en) * | 2018-10-10 | 2019-02-15 | 广东长盈科技股份有限公司 | A kind of transportation data collection system and method based on Internet of Things |
-
2020
- 2020-12-28 CN CN202011589677.5A patent/CN114693588A/en active Pending
-
2021
- 2021-12-27 WO PCT/CN2021/141762 patent/WO2022143562A1/en active Application Filing
- 2021-12-27 DE DE112021006736.2T patent/DE112021006736T5/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103869789A (en) * | 2014-03-26 | 2014-06-18 | 卢大伟 | Transported cargo quality monitoring method and system based on internet of things |
US20180260772A1 (en) * | 2017-01-31 | 2018-09-13 | Focal Systems, Inc | Out-of-stock detection based on images |
CN107122747A (en) * | 2017-04-28 | 2017-09-01 | 北京理工大学 | A kind of railway carriage state non-contact detection device and method |
CN108416901A (en) * | 2018-03-27 | 2018-08-17 | 合肥美的智能科技有限公司 | Method and device for identifying goods in intelligent container and intelligent container |
CN109003304A (en) * | 2018-07-12 | 2018-12-14 | 南京云计趟信息技术有限公司 | A kind of camera angle mobile detecting system and method based on deep learning |
CN109341763A (en) * | 2018-10-10 | 2019-02-15 | 广东长盈科技股份有限公司 | A kind of transportation data collection system and method based on Internet of Things |
Also Published As
Publication number | Publication date |
---|---|
CN114693588A (en) | 2022-07-01 |
DE112021006736T5 (en) | 2023-10-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112132156B (en) | Image saliency target detection method and system based on multi-depth feature fusion | |
CN108830225B (en) | Method, device, equipment and medium for detecting target object in terahertz image | |
CN111178183A (en) | Face detection method and related device | |
CN109727275B (en) | Object detection method, device, system and computer readable storage medium | |
CN111310826B (en) | Method and device for detecting labeling abnormality of sample set and electronic equipment | |
US20160337545A1 (en) | System and method for low light document capture and binarization with multiple flash images | |
US20180308236A1 (en) | Image Background Subtraction For Dynamic Lighting Scenarios | |
CN113378648A (en) | Artificial intelligence port and wharf monitoring method | |
CN106570855A (en) | Method and system for quickly judging pork freshness | |
CN109784322B (en) | Method, equipment and medium for identifying vin code based on image processing | |
CN110569770A (en) | Human body intrusion behavior recognition method and device, storage medium and electronic equipment | |
CN104268595B (en) | general object detection method and system | |
US20140093129A1 (en) | Object detection apparatus and method | |
CN111783654A (en) | Vehicle weight identification method and device and electronic equipment | |
Fernando et al. | Automatic road traffic signs detection and recognition using ‘You Only Look Once’version 4 (YOLOv4) | |
CN108960247B (en) | Image significance detection method and device and electronic equipment | |
CN112784675A (en) | Target detection method and device, storage medium and terminal | |
CN111402185B (en) | Image detection method and device | |
CN112949423B (en) | Object recognition method, object recognition device and robot | |
WO2022143562A1 (en) | Cargo container state detection method and apparatus | |
CN111191575B (en) | Naked flame detection method and system based on flame jumping modeling | |
CN114926631A (en) | Target frame generation method and device, nonvolatile storage medium and computer equipment | |
CN115147818A (en) | Method and device for identifying mobile phone playing behaviors | |
CN117975440A (en) | Food image processing method, device, equipment and medium based on semantic segmentation | |
US20240249559A1 (en) | Image liveness detection method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 21914298 Country of ref document: EP Kind code of ref document: A1 |
|
WWE | Wipo information: entry into national phase |
Ref document number: 112021006736 Country of ref document: DE |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 21914298 Country of ref document: EP Kind code of ref document: A1 |