CN-121999196-A - Data processing method and related device
Abstract
The application discloses a data processing method and a related device, and relates to the technical field of data processing, wherein the data processing method comprises the steps of detecting vehicle parts of a first vehicle image to obtain part areas corresponding to all vehicle parts respectively; and determining a target vehicle component according to the component area corresponding to the region of interest and the component area corresponding to each vehicle component, wherein the region of interest is selected by a user from the first vehicle image, and determining the target area corresponding to the target vehicle component from the second vehicle image. The data processing method disclosed by the application can determine the region corresponding to the region of interest selected by the user from the first vehicle image from the second vehicle image, so that the user can randomly select the region of interest, and the method has higher efficiency and precision.
Inventors
- ZHANG ZHAOXING
- ZHANG FEIFEI
- ZHANG XIAOWEI
- YANG ZHENGWANG
- YUAN WEIJUN
Assignees
- 北京罗克维尔斯科技有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20241105
Claims (11)
- 1. A method of data processing, comprising: detecting vehicle parts of the first vehicle image to obtain part areas corresponding to the vehicle parts respectively; Determining a target vehicle component according to a component area corresponding to a region of interest and a component area corresponding to each vehicle component, wherein the region of interest is a region selected by a user from the first vehicle image; and determining a target area corresponding to the target vehicle component from the second vehicle image.
- 2. The data processing method according to claim 1, wherein the determining the target area corresponding to the target vehicle component from the second vehicle image includes: Determining an image area which contains the part area corresponding to the target vehicle part from a second vehicle image to obtain a target image area; And determining a region matched with the part region corresponding to the region of interest from the target image region to obtain a target region corresponding to the target vehicle part.
- 3. The data processing method according to claim 1, wherein the determining the target vehicle component according to the component area corresponding to the region of interest and the component area corresponding to each of the vehicle components, respectively, includes: calculating an overlapping degree representation value of a part area corresponding to the region of interest and a part area corresponding to each vehicle part; and determining the vehicle component with the corresponding component region and the component region corresponding to the region of interest, wherein the overlapping degree representation value of the corresponding component region is larger than a set threshold value, as the target vehicle component.
- 4. The data processing method according to claim 2, wherein the determining, from the second vehicle image, an image area including the component area corresponding to the target vehicle component, and obtaining the target image area, includes: Finding a component area corresponding to the target vehicle component from component areas corresponding to each vehicle component contained in the second vehicle image; And determining a minimum rectangular area which completely contains the component area corresponding to the target vehicle component from the second vehicle image according to the position information of the component area corresponding to the target vehicle component, so as to obtain a target image area.
- 5. The data processing method according to claim 2, wherein the determining, from the target image area, an area that matches a component area corresponding to the region of interest, includes: Based on a window with the same size as the part area corresponding to the region of interest, sliding sampling is carried out on the target image area according to a preset sliding mode and a sliding step length, so that a plurality of candidate areas with the same size as the part area corresponding to the region of interest are obtained; And determining a candidate region which is most similar to the part region corresponding to the region of interest in the plurality of candidate regions as a region matched with the part region corresponding to the region of interest.
- 6. The data processing method according to claim 2, characterized in that the determining, from the component areas corresponding to the target vehicle component, a region that matches the component area corresponding to the region of interest includes: Extracting a component area corresponding to the region of interest from the first vehicle image, and extracting the target image area from the second vehicle image; Inputting the extracted component area corresponding to the region of interest and the target image area into an image matching model obtained by training in advance for matching, so as to obtain a region matched with the component area corresponding to the region of interest in the target image area; The image matching model is obtained by training a first training sample and a second training sample marked with a region matched with the first training sample, the first training sample is a component region corresponding to a region of interest in a first training vehicle image, the second training sample is a target image region extracted from a second training vehicle image, and the target image region extracted from the second training vehicle image comprises a component region corresponding to a target vehicle component determined according to the component region corresponding to the region of interest in the first training vehicle image.
- 7. The data processing method according to claim 1, wherein the performing vehicle component detection on the first vehicle image includes: detecting the vehicle component of the first vehicle image by adopting a pre-trained vehicle component detection model; the vehicle part detection model is obtained by training a training vehicle image marked with a part area corresponding to a vehicle part.
- 8. A data processing device is characterized by comprising a vehicle component detection module, a target vehicle component determination module and a target component area determination module; The vehicle component detection module is used for detecting the vehicle component of the first vehicle image to obtain component areas corresponding to the vehicle components respectively; the target vehicle component determining module is configured to determine a target vehicle component according to a component area corresponding to a region of interest and component areas corresponding to the vehicle components, where the region of interest is a region selected by a user from the first vehicle image; The target component area determining module is used for determining a target area corresponding to the target vehicle component from a second vehicle image.
- 9. An electronic device comprising at least one processor and a memory coupled to the processor, wherein: the memory is used for storing a computer program; the processor is configured to execute the computer program to enable the electronic device to implement the steps of the data processing method according to any one of claims 1 to 7.
- 10. A computer storage medium carrying one or more computer programs which, when executed by an electronic device, enable the electronic device to carry out the steps of the data processing method according to any one of claims 1 to 7.
- 11. A computer program product comprising computer readable instructions which, when run on an electronic device, cause the electronic device to carry out the steps of the data processing method according to any one of claims 1 to 7.
Description
Data processing method and related device Technical Field The present application relates to the field of data processing technologies, and in particular, to a data processing method and a related device. Background In some scenarios (such as vehicle design scenarios), it may be desirable to compare a designated component area in a first vehicle image (such as an image of a vehicle of type a) with a corresponding component area in a second vehicle image (such as an image of a vehicle of type B of type a), such as, for example, to compare an upper half of a front left wheel of a vehicle in the first vehicle image with an upper half of a front left wheel of a vehicle in the second vehicle image. It will be appreciated that, to compare the designated component area in the first vehicle image with the corresponding component area in the second vehicle image, it is first necessary to find the component area corresponding to the designated component area in the first vehicle image from the second vehicle image, and how to find the component area corresponding to the designated component area in the first vehicle image from the second vehicle image is a problem that needs to be solved. Disclosure of Invention In view of the above, the present application provides a data processing method and related device, which are used for finding a component area corresponding to a designated component area in a first vehicle image from a second vehicle image, and the technical scheme is as follows: the first aspect of the present application provides a data processing method, including: detecting vehicle parts of the first vehicle image to obtain part areas corresponding to the vehicle parts respectively; Determining a target vehicle component according to a component area corresponding to a region of interest and a component area corresponding to each vehicle component, wherein the region of interest is a region selected by a user from the first vehicle image; and determining a target area corresponding to the target vehicle component from the second vehicle image. In one possible implementation manner, the determining, from the second vehicle image, the target area corresponding to the target vehicle component includes: Determining an image area which contains the part area corresponding to the target vehicle part from a second vehicle image to obtain a target image area; And determining a region matched with the part region corresponding to the region of interest from the target image region to obtain a target region corresponding to the target vehicle part. In one possible implementation manner, the determining the target vehicle component according to the component area corresponding to the region of interest and the component area corresponding to each vehicle component includes: calculating an overlapping degree representation value of a part area corresponding to the region of interest and a part area corresponding to each vehicle part; and determining the vehicle component with the corresponding component region and the component region corresponding to the region of interest, wherein the overlapping degree representation value of the corresponding component region is larger than a set threshold value, as the target vehicle component. In one possible implementation manner, the determining, from the second vehicle image, an image area including the component area corresponding to the target vehicle component, to obtain the target image area includes: Finding a component area corresponding to the target vehicle component from component areas corresponding to each vehicle component contained in the second vehicle image; And determining a minimum rectangular area which completely contains the component area corresponding to the target vehicle component from the second vehicle image according to the position information of the component area corresponding to the target vehicle component, so as to obtain a target image area. In one possible implementation manner, the determining, from the target image area, an area that matches a component area corresponding to the region of interest includes: Based on a window with the same size as the part area corresponding to the region of interest, sliding sampling is carried out on the target image area according to a preset sliding mode and a sliding step length, so that a plurality of candidate areas with the same size as the part area corresponding to the region of interest are obtained; And determining a candidate region which is most similar to the part region corresponding to the region of interest in the plurality of candidate regions as a region matched with the part region corresponding to the region of interest. In one possible implementation manner, the determining, from the component areas corresponding to the target vehicle component, a region matching the component area corresponding to the region of interest includes: Extracting a component area corresponding to the re