CN113705097B - Vehicle model construction method and device, computer equipment and storage medium - Google Patents

Vehicle model construction method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN113705097B
CN113705097B CN202111004842.0A CN202111004842A CN113705097B CN 113705097 B CN113705097 B CN 113705097B CN 202111004842 A CN202111004842 A CN 202111004842A CN 113705097 B CN113705097 B CN 113705097B
Authority
CN
China
Prior art keywords
model
original
vehicle
request
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111004842.0A
Other languages
Chinese (zh)
Other versions
CN113705097A (en
Inventor
吴涤豪
沈旭
周汉清
韩旭
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Weride Technology Co Ltd
Original Assignee
Guangzhou Weride Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Weride Technology Co Ltd filed Critical Guangzhou Weride Technology Co Ltd
Priority to CN202111004842.0A priority Critical patent/CN113705097B/en
Publication of CN113705097A publication Critical patent/CN113705097A/en
Application granted granted Critical
Publication of CN113705097B publication Critical patent/CN113705097B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • G06F30/27Design optimisation, verification or simulation using machine learning, e.g. artificial intelligence, neural networks, support vector machines [SVM] or training a model
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9538Presentation of query results
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Data Mining & Analysis (AREA)
  • Artificial Intelligence (AREA)
  • Software Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Computer Hardware Design (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Geometry (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the invention provides a method, a device, computer equipment and a storage medium for constructing a vehicle model, wherein the method comprises the following steps: generating a plurality of virtual machines with the same environments as a plurality of vehicles respectively, receiving a first request for constructing a model, respectively importing an original model into the plurality of virtual machines in response to the first request, respectively constructing the original model in the plurality of virtual machines in response to the first request, obtaining a plurality of target models, issuing the plurality of target models for the original model, simulating vehicles with different environments by using the virtual machines when the vehicle is offline, thereby constructing a static target model in different environments, ensuring that the target model is correctly loaded in the vehicle, enabling the vehicle to directly load the target model for operation after downloading the target model with the adapted environment, avoiding the operation of dynamically constructing the model in the environment of the vehicle when the automatic driving system is initialized, and reducing the initialization time of the automatic driving system.

Description

Vehicle model construction method and device, computer equipment and storage medium
Technical Field
The embodiment of the invention relates to the technical field of automatic driving, in particular to a vehicle model construction method, a vehicle model construction device, computer equipment and a storage medium.
Background
In autopilot, a number of models, particularly neural networks, are applied, which are loaded when the autopilot system is started and implement various functions of autopilot, such as perception, path planning, etc.
When the automatic driving system is initialized, the models are dynamically built according to the current environment of the vehicle, and the building process takes a long time, so that the initialization time of the automatic driving system is long and can be as long as a few minutes.
Disclosure of Invention
The embodiment of the invention provides a vehicle model construction method, a vehicle model construction device, computer equipment and a storage medium, which are used for solving the problem that the time consumption for constructing an automatic driving model is long when an automatic driving system is initialized.
In a first aspect, an embodiment of the present invention provides a method for constructing a vehicle model, including:
generating a plurality of virtual machines with the same environments as the plurality of vehicles respectively;
receiving a first request for building a model;
in response to the first request, respectively importing an original model into a plurality of virtual machines;
responding to the first request, respectively constructing the original models in a plurality of virtual machines, and obtaining a plurality of target models;
And publishing a plurality of target models for the original model.
Optionally, the receiving a first request to build a model includes:
a first request sent by a command line tool to build a model is received through a fast interface framework FastAPI.
Optionally, said responding to said first request, importing an original model into a plurality of said virtual machines, respectively, includes:
extracting an identification of an original model from the first request;
downloading the original model from a path appointed in the virtual machine according to the identification;
and importing the original model into a plurality of virtual machines respectively.
Optionally, said building said original model in a plurality of said virtual machines in response to said first request, respectively, to obtain a plurality of target models, including:
extracting a configuration file from the first request, wherein information for constructing the original model is recorded in the configuration file;
and respectively constructing the original models in the virtual machines according to the configuration files to obtain a plurality of target models.
Optionally, in response to the first request, the building the original models in a plurality of virtual machines respectively to obtain a plurality of target models, and further includes:
Querying a first catalogue where the original model is located in each virtual machine;
and setting a path for outputting the original model as the first catalog in the configuration file.
Optionally, in response to the first request, the building the original models in a plurality of virtual machines respectively to obtain a plurality of target models, and further includes:
inquiring a preset second catalogue in each virtual machine;
and setting the path of the output result of the original model as the second catalog in the configuration file.
Optionally, the building the original model in a plurality of virtual machines according to the configuration file respectively to obtain a plurality of target models includes:
searching script files configured for the original model in each virtual machine;
and calling the script file to construct the original model according to the configuration file, and obtaining a target model.
Optionally, the method further comprises:
and responding to the second request, sending a plurality of target models and/or the original models corresponding to the original models to the vehicle, wherein the vehicle is used for loading the target models or constructing the original models in the vehicle.
Optionally, the method further comprises:
receiving a third request for the vehicle to query the target model;
responding to the third request, and inquiring the target model constructed in the virtual machine with the same environment as the vehicle to obtain an inquiring result;
and notifying the vehicle of the query result, wherein the vehicle is used for loading the target model when the environment is the same as the virtual machine for constructing the target model, and constructing the original model in the environment of the vehicle when the environment is different from the virtual machine for constructing the target model or the original model meets a preset construction condition, and the construction condition comprises that the time for constructing the original model is smaller than a preset threshold value.
In a second aspect, an embodiment of the present invention further provides a device for constructing a vehicle model, including:
the virtual machine generation module is used for generating a plurality of virtual machines with the same environments as the plurality of vehicles respectively;
the first request receiving module is used for receiving a first request for constructing a model;
the original model importing module is used for respectively importing the original model into the plurality of virtual machines in response to the first request;
The original model construction module is used for responding to the first request and respectively constructing the original models in a plurality of virtual machines to obtain a plurality of target models;
and the object model issuing module is used for issuing a plurality of object models aiming at the original model.
Optionally, the first request receiving module is further configured to:
a first request sent by a command line tool to build a model is received through a fast interface framework FastAPI.
Optionally, the raw model importing module includes:
an identification extraction module for extracting an identification of an original model suitable for automatic driving from the first request;
the original model downloading module is used for downloading the original model from the path appointed in the virtual machine according to the identification;
and the original model storage module is used for importing the original model into a plurality of virtual machines respectively.
Optionally, the original model building module includes:
the configuration file extraction module is used for extracting a configuration file from the first request, and the configuration file records information for constructing the original model;
and the configuration file construction module is used for constructing the original models in the virtual machines according to the configuration files respectively to obtain a plurality of target models.
Optionally, the original model building module further includes:
the first catalog inquiry module is used for inquiring a first catalog of the original model in each virtual machine;
and the first catalog setting module is used for setting the path for outputting the original model as the first catalog in the configuration file.
Optionally, the original model building module further includes:
the second catalog inquiry module is used for inquiring a preset second catalog in each virtual machine;
and the second catalog setting module is used for setting the path of the output result of the original model as the second catalog in the configuration file.
Optionally, the profile construction module includes:
the script file searching module is used for searching script files configured for the original model in each virtual machine;
and the script file construction module is used for calling the script file to construct the original model according to the configuration file so as to obtain a target model.
Optionally, the method further comprises:
the second request receiving module is used for receiving a second request sent by the original model downloaded by the vehicle;
and the target model sending module is used for responding to the second request and sending a plurality of target models and/or the original models corresponding to the original models to the vehicle, wherein the vehicle is used for loading the target models or constructing the original models in the vehicle.
Optionally, the method further comprises:
a third request receiving module for receiving a third request for the vehicle to query the target model;
the target model query module is used for responding to the third request and querying the target model constructed in the virtual machine with the same environment as the vehicle to obtain a query result;
the query result notification module is used for notifying the vehicle of the query result, the vehicle is used for loading the target model when the environment is the same as the virtual machine for constructing the target model, and constructing the original model in the environment of the vehicle when the environment is different from the virtual machine for constructing the target model or the original model meets a preset construction condition, wherein the construction condition comprises that the time for constructing the original model is smaller than a preset threshold value.
In a third aspect, an embodiment of the present invention further provides a computer apparatus, including:
one or more processors;
a memory for storing one or more programs,
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method of constructing a vehicle model as described in the first aspect.
In a fourth aspect, an embodiment of the present invention further provides a computer readable storage medium, where a computer program is stored, where the computer program is executed by a processor to implement the method for constructing a vehicle model according to the first aspect.
In this embodiment, multiple virtual machines with the same environments as multiple vehicles are generated, a first request for building a model is received, an original model is respectively imported into the multiple virtual machines in response to the first request, the original model is built in the multiple virtual machines in response to the first request, multiple target models are obtained, the multiple target models are issued for the original model, the virtual machines are used for simulating vehicles with different environments when the multiple target models are offline, and therefore static target models are built in different environments, correct loading of the target models in the vehicles can be guaranteed, the vehicles can download the target models with the adaptive environments and then directly load the target models for operation, operation of dynamically building the model in the environment of the vehicle when an automatic driving system is initialized is avoided, and initialization time of the automatic driving system is reduced. Moreover, the target model can be built on virtual machines in different environments on a large scale, and the construction efficiency is high.
Drawings
FIG. 1 is a flowchart of a method for constructing a vehicle model according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of a vehicle according to a first embodiment of the present invention;
FIG. 3 is an exemplary diagram of a build model provided in accordance with a first embodiment of the present invention;
FIG. 4 is a flowchart of a method for constructing a vehicle model according to a second embodiment of the present invention;
fig. 5 is a schematic structural diagram of a vehicle model building apparatus according to a third embodiment of the present invention;
fig. 6 is a schematic structural diagram of a computer device according to a fourth embodiment of the present invention.
Detailed Description
The invention is described in further detail below with reference to the drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting thereof. It should be further noted that, for convenience of description, only some, but not all of the structures related to the present invention are shown in the drawings.
Example 1
Fig. 1 is a flowchart of a method for constructing a vehicle model according to a first embodiment of the present invention, where the method may be applied to offline construction of a model applied to automatic driving, and the method may be performed by a vehicle model constructing apparatus, which may be implemented by software and/or hardware, may be configured in a computer device, for example, a server, a personal computer, or the like, and specifically includes the following steps:
Step 101, generating a plurality of virtual machines with the same environments as the plurality of vehicles.
The vehicle in this embodiment is configured with an autopilot system, which can support autopilot, and autopilot may refer to the ability of the vehicle itself to have environmental awareness, path planning, and autonomously implement vehicle control, i.e., humanoid driving by electronically controlling the vehicle.
Depending on the degree of confidence in the vehicle handling task, autonomous vehicles can be classified into L0 non-Automation (No Automation), L1 driver assistance (driverussianance), L2 partial Automation (Partial Automation), L3 conditional Automation (conditional Automation), L4 High Automation (High Automation), L5 full Automation (full Automation).
The vehicle driven automatically in this embodiment may refer to a vehicle meeting any one of requirements L1-L5, where the system performs an auxiliary function in L1-L3, and when L4 is reached, the vehicle driving is handed over to the system, so the vehicle driven automatically may be selected as a vehicle meeting any one of requirements L4 and L5.
As shown in fig. 2, the vehicle 200 may include a drive control apparatus 201, a body bus 202, an ECU (electronic control unit) 203, an ECU204, an ECU205, a sensor 206, a sensor 207, a sensor 208, and an actuator 209, an actuator 210, and an actuator 211.
The driving control apparatus (also referred to as an onboard brain) 201 is responsible for overall intelligent control of the entire vehicle 200. The driving control apparatus 201 may be a separately provided controller, for example, a programmable logic controller (ProgrammableLogicController, PLC), a singlechip, an industrial controller, or the like; the device can also be equipment consisting of other electronic devices with input/output ports and operation control functions; but also a computer device installed with a vehicle driving control type application. The driving control device may analyze and process data sent from each ECU and/or data sent from each sensor received on the body bus 202, make a corresponding decision, and send an instruction corresponding to the decision to the body bus.
The body bus 202 may be a bus for connecting the driving control device 201, ECU203, ECU204, ECU205, sensor 206, sensor 207, sensor 208, and other devices of the vehicle 200, which are not shown. Because of the wide acceptance of high performance and reliability of CAN (controller area network) buses, the body bus commonly used in motor vehicles is currently a CAN bus. Of course, it is understood that the body bus may be other types of buses.
The body bus 202 may send the instruction sent by the driving control device 201 to the ECU203, the ECU204, and the ECU205, and the ECU203, the ECU204, and the ECU205 analyze the instruction and send the analyzed instruction to the corresponding executing device for execution.
The sensors 206, 207, 208 include, but are not limited to, lidar, cameras, and the like.
It should be understood that the number of vehicles, drive control devices, body buses, ECUs, actuators, and sensors in fig. 2 are merely illustrative. There may be any number of vehicles, driving control devices, body buses, ECU, and sensors, as desired for implementation.
Models suitable for automatic driving are applied in vehicles, particularly neural networks, such as Lananet and H-Net combinations, polyLaneNet, VPGNet, 3D-Lananet and the like, and data (such as image data and point cloud data) collected by sensors can be used for realizing partial functions in automatic driving, such as lane line detection, traffic light detection, traffic sign detection, other vehicle detection, route planning and the like.
These models are built depending on the environment of the vehicle, and in order to facilitate distinguishing the states of the models, the model that is not built is denoted as an original model, and the model after the construction is denoted as a target model.
The environment of the vehicle may be divided into a hardware environment, a software environment, and the hardware environment is mainly heterogeneous devices (i.e., devices that provide computing power to a model), for example, GPU (graphics processing unit), TPU (tensor processor), NPU (neuralnetwork processingunit), neural network processor), and the like, and the software environment includes an operating system (type of operating system, version of operating system), library (type of library (e.g., CUDA, math, numpy, h5py, mathplotlib, framework, etc.), version of library, and the like.
In this embodiment, considering that the same source is differently built in vehicles with different environments, multiple machines with the same environments as those of multiple vehicles can be generated in the computer device by using a virtual technology, and the multiple machines are recorded as virtual machines, so that the environment of different vehicles can be simulated as much as possible to build the source model.
In one example, as shown in fig. 3, virtual machine 321 may be generated for environment a, virtual machine 322 may be generated for environment B, virtual machine 323 may be generated for environment C, and so on.
Step 102, a first request to build a model is received.
In this embodiment, the computer device serves as a server, and the user may prepare the original model locally at the client, package the original model, and send a first request to the server to request to construct the original model.
The client cleint may be a command line tool implemented using python, go, or other languages.
In general, the original model is a model that has been completed with training, and after construction, can be applied to automatic driving of a vehicle, the structure of the original model is not limited to a neural network that is designed manually, but can be optimized by a model quantization method, a neural network that is searched for a target hardware delay characteristic by a NAS (neural network structure search) method, and so on, which is not limited in this embodiment.
The server side server is configured with a service, which is recorded as a build service, the build service can also be implemented by using languages such as python, go, and the like, and frames such as a quick interface frame FastAPI, django are applied, and the command line tool can call the quick interface frame FastAPI to send a first request for building a model, so that the service can receive the first request for building the model sent by the command line tool through the quick interface frame FastAPI.
Among them, fastAPI is a high performance Web (page) framework for building APIs (Application ProgrammingInterface, application program interfaces).
Further, in this embodiment, a configuration file with a uniform format is provided for different building modes of the original model, and information of building the original model by adapting to multiple types of technologies may be filled in by a user according to the format of the configuration file, a path of the original model located in a client is provided, the client packages the original model, and configuration information and an identifier (such as an ID) of the original model are added to the content in the first request.
Step 103, in response to the first request, importing the original model into the plurality of virtual machines respectively.
The same functional original model may be deployed in vehicles of different environments (hardware environment and/or software environment), and thus, the build service in the server responds to the first request of the client, and the original model (especially the same original model suitable for automatic driving is respectively imported into the plurality of virtual machines) so that the same original model can be in different environments (hardware environment and/or software environment) to simulate the real vehicle environment (hardware environment and/or software environment) distribution.
In one example, as shown in FIG. 3, the original model 310 may be imported into virtual machine 321, virtual machine 322, virtual machine 323, respectively.
In a specific implementation, the build service may extract an identification (e.g., an ID) of an original model suitable for autopilot from the first request, retrieve the original model from the client machine according to the identification, download the corresponding original model from a path specified by the original model in the virtual machine, decompress and import the original model into a respective plurality of virtual machines.
And 104, respectively constructing original models in a plurality of virtual machines in response to the first request, and obtaining a plurality of target models.
The construction service in the server responds to the first request of the client, the construction operation is respectively executed in a plurality of virtual machines aiming at the same model, and the target model can be obtained after the construction is completed.
Taking deep learning framework dark net in YOLO as an example, the construction process is as follows:
1. and configuring the GPU.
2. Downloading the version of OpenCV supported by dark net, clicking exe for decompression.
3. And opening corresponding projects from the dark net, sequentially selecting folders such as dark net-master, build and dark net in a dark net path, and starting options such as release X64 which are adaptive to the GPU.
4. Configuring OpenCV, and walking in four steps: the append contains directory, append library directory, append dependent item, openCV dependent dll copies to the dark net. Exe same directory (which can also be configured directly as an environment variable), i.e., four steps are configured to head file path, lib path and lib name, item dependent dll.
5. Testing
More versions in dark net, more related projects and more messy files of part of projects can be deleted first, and then files related to the projects can be added.
For example, a file storing vector weights during training, a profile file of YOLO, a cmd run command, a profile during training, data, category names, a file storing tags, a file storing vector weights during testing, and so on.
In one example, as shown in FIG. 3, an original model 310 may be built in an environment A of a virtual machine 321, a target model 321 may be obtained, an original model 310 may be built in an environment B of a virtual machine 322, a target model 332 may be obtained, an original model 310 may be built in an environment C of a virtual machine 323, and a target model 333 may be obtained.
In one embodiment of the present invention, step 104 includes the steps of:
step 1041, extracting a configuration file from the first request.
The server analyzes the first request of the client, extracts a configuration file set for the corresponding original model from the first request, and records information for constructing the original model in the configuration file.
Because the client of the original model uploads the client to the server, the information of the client of the original model changes partially depending on the information of the equipment, and the information in the configuration file is changed accordingly, so that the accuracy of the configuration file is ensured, and the accuracy of constructing the original model is ensured.
In one case, as the path of the original model changes, the first directory where the original model is located may be queried in each virtual machine accordingly, and the path of the output original model is set as the first directory in the configuration file so that the original model is loaded correctly.
In another case, the path of the output result of the original model is empty, and accordingly, a preset second directory may be queried in each virtual machine, and the path of the output result of the original model is set as the second directory in the configuration file.
Of course, the above information of the change configuration file is merely an example, and other information of the change configuration file may be set according to actual situations when implementing the embodiment of the present invention, which is not limited in the embodiment of the present invention. In addition, in addition to the information of the configuration file, those skilled in the art may also use other information of the configuration file according to actual needs, which is not limited in the embodiment of the present invention.
Step 1042, constructing original models in the multiple virtual machines according to the configuration files, and obtaining multiple target models.
In each virtual machine, reading information for constructing an original model in the configuration file, and correctly constructing the original model according to the information to obtain a target model.
Furthermore, a portion of the original model may be provided with a script file for construction, where the script file may be a script file matched with the original model, for example, a script file corresponding to a TensorFlow may be a TF-TRT, a custom script file, etc., which is not limited in this embodiment.
Script files set for different original models can be stored in the virtual machines, and script files configured for the original models are searched in each virtual machine, so that the script files are called to construct the original models according to information of the original models constructed in the configuration files, the original models are constructed, and the target models are obtained.
And verifying parameters (information for constructing an original model) of the input script file, ensuring that each field of the parameters is complete, configuring various dependent environments according to the parameters by the script file, executing construction, packaging and uploading construction results (comprising log files and environments recorded during construction in the log files) to construction services of the server, and returning identification of a construction service retrieval target model of the server.
Step 105, issuing a plurality of target models for the original model.
If the construction of the target models under different environments is completed aiming at the same original model, the target models can be uniformly identified as the same model, and the target models under the same original model are issued outwards, so that the target models can be downloaded by the authorized vehicle.
Furthermore, the original model may be built as a model with a new function, or may belong to a version for updating an existing model, and the information for updating the new model or completing updating the model may be actively pushed to the vehicle by the server, or may be the polling of the vehicle to the server at regular time, which is not limited in this embodiment.
In this embodiment, multiple virtual machines with the same environments as multiple vehicles are generated, a first request for building a model is received, an original model suitable for automatic driving is respectively imported into the multiple virtual machines in response to the first request, the original model is built in the multiple virtual machines in response to the first request, multiple target models are obtained, the multiple target models are issued for the original model, vehicles with different environments are simulated by using the virtual machines when the original model is offline, and therefore static target models are built in different environments, correct loading of the target models in the vehicles can be guaranteed, the vehicles can download the target models with the adaptive environments and then directly load the target models for operation, operation of dynamically building the model for the environments of the vehicles when the automatic driving system is initialized is avoided, and initialization time of the automatic driving system is reduced. Moreover, the target model can be built on virtual machines in different environments on a large scale, and the construction efficiency is high.
Example two
Fig. 4 is a flowchart of a method for constructing a vehicle model according to a second embodiment of the present invention, where the method further includes the steps of:
Step 401, generating a plurality of virtual machines whose environments are the same as those of a plurality of vehicles, respectively.
Step 402, a first request to build a model is received.
Step 403, in response to the first request, importing the original model into the plurality of virtual machines, respectively.
Step 404, in response to the first request, respectively constructing original models in the plurality of virtual machines to obtain a plurality of target models.
Step 405, publishing a plurality of target models for the original model.
Step 406, receiving a second request sent by the original model of the vehicle download.
Step 407, in response to the second request, transmitting a plurality of target models and/or original models corresponding to the original models to the vehicle.
And the vehicle sends a second request for downloading the newly added or updated original model to the server at preset time or under the conditions of idle and the like.
The server responds to the second request of the vehicle, in one case, searches for a plurality of target models which are built completely by searching for the identification of the target model, and sends the plurality of target models to the vehicle, wherein the target models are built completely and belong to a static model, and the vehicle can be directly loaded. Since the environment (especially, a library) of the vehicle may change, a plurality of target models may be downloaded to the vehicle at one time, after the environment changes, a suitable target model may still be found for downloading, so that the number of times of downloading the target model is reduced, and thus, the time consumed for downloading the target model is reduced.
In another case, the original model can be directly sent to the vehicle, the original model is not built, the vehicle can be built when the automatic driving system is initialized, and the original model is ensured to be accurately built and accurately run.
Of course, the server may also send the original model and the corresponding multiple target models to the vehicle together, where the vehicle selects to load the target model or construct the original model according to the actual situation, which is not limited in this embodiment.
Step 408, a third request is received for a vehicle to query the target model.
And 409, responding to the third request, and inquiring a target model constructed in the virtual machine with the same environment as the vehicle to obtain an inquiring result.
Step 410, notifying the vehicle of the query result.
After downloading the target model, the vehicle sends a third request for inquiring the environment for constructing the target model to the server.
The server responds to a third request of the vehicle, checks the environment of the vehicle, searches whether a target model constructed in a virtual machine with the same environment as the vehicle exists, and records information of whether the target model constructed in the virtual machine with the same environment as the vehicle exists in a query result.
Further, in addition to whether there is information of a target model constructed in a virtual machine having the same environment as the vehicle, information of an original model may be recorded in the query result.
The server informs the vehicle of the query result, in one case, the vehicle loads the target model when the environment is the same as the virtual machine for constructing the target model, and in the other case, if the target model constructed in the virtual machine with the same environment as the vehicle does not exist, the information of the original model can be compared with the preset construction.
And when the environment is different from the virtual machine for constructing the target model or the original model meets preset construction conditions, constructing the original model in the environment of the vehicle.
The information of the original model can be counted by a server through testing, and updated along with finer original model, and the construction condition is a condition for controlling the time of constructing the original model.
Illustratively, the build conditions include that the time to build the original model is less than a preset threshold, the complexity of the original model is less than a preset threshold (i.e., the original model is relatively simple, the build time is short), the number of levels of the original model is less than a preset threshold (i.e., the original model is a lightweight model, the build time is short), the environment variables relied upon by the original model are less than a preset threshold (i.e., the original model is less dependent than a small number of variables, the build time is short), etc.
According to the embodiment, the adaptation of the target model and the vehicle environment is automatically realized through the service of the server, the accuracy of the adaptation of the target model and the vehicle environment can be ensured from the source, the probability of personal selection errors is reduced, and the usability is improved.
Of course, in addition to the server query, the present embodiment may load the target model adapted to the environment in the vehicle in other manners, for example, the server records the environment when building the target model in an independent file in the target model, the vehicle may locally check the target model built in the virtual machine with the same environment as the vehicle, and so on, which is not limited in this embodiment.
It should be noted that, for simplicity of description, the method embodiments are shown as a series of acts, but it should be understood by those skilled in the art that the embodiments are not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the embodiments. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred embodiments, and that the acts are not necessarily required by the embodiments of the invention.
Example III
Fig. 5 is a block diagram of a vehicle model construction device according to a third embodiment of the present invention, which specifically includes the following modules:
a virtual machine generation module 501 for generating a plurality of virtual machines having the same environments as the plurality of vehicles, respectively;
a first request receiving module 502, configured to receive a first request for building a model;
an original model importing module 503, configured to import an original model into the plurality of virtual machines in response to the first request;
an original model building module 504, configured to build the original models in a plurality of virtual machines in response to the first request, to obtain a plurality of target models;
a target model publishing module 505, configured to publish a plurality of target models for the original model.
In one embodiment of the present invention, the first request receiving module 502 is further configured to:
a first request sent by a command line tool to build a model is received through a fast interface framework FastAPI.
In one embodiment of the present invention, the raw model import module 503 includes:
an identification extraction module for extracting an identification of an original model suitable for automatic driving from the first request;
The original model downloading module is used for downloading the original model from the path appointed in the virtual machine according to the identification;
and the original model storage module is used for importing the original model into a plurality of virtual machines respectively.
In one embodiment of the present invention, the raw model building module 504 includes:
the configuration file extraction module is used for extracting a configuration file from the first request, and the configuration file records information for constructing the original model;
and the configuration file construction module is used for constructing the original models in the virtual machines according to the configuration files respectively to obtain a plurality of target models.
In another embodiment of the present invention, the raw model building module 504 further includes:
the first catalog inquiry module is used for inquiring a first catalog of the original model in each virtual machine;
and the first catalog setting module is used for setting the path for outputting the original model as the first catalog in the configuration file.
In yet another embodiment of the present invention, the raw model building module 504 further includes:
the second catalog inquiry module is used for inquiring a preset second catalog in each virtual machine;
And the second catalog setting module is used for setting the path of the output result of the original model as the second catalog in the configuration file.
In one embodiment of the present invention, the profile construction module includes:
the script file searching module is used for searching script files configured for the original model in each virtual machine;
and the script file construction module is used for calling the script file to construct the original model according to the configuration file so as to obtain a target model.
In one embodiment of the present invention, further comprising:
the second request receiving module is used for receiving a second request sent by the original model downloaded by the vehicle;
and the target model sending module is used for responding to the second request and sending a plurality of target models and/or the original models corresponding to the original models to the vehicle, wherein the vehicle is used for loading the target models or constructing the original models in the vehicle.
In one embodiment of the present invention, further comprising:
a third request receiving module for receiving a third request for the vehicle to query the target model;
the target model query module is used for responding to the third request and querying the target model constructed in the virtual machine with the same environment as the vehicle to obtain a query result;
The query result notification module is used for notifying the vehicle of the query result, the vehicle is used for loading the target model when the environment is the same as the virtual machine for constructing the target model, and constructing the original model in the environment of the vehicle when the environment is different from the virtual machine for constructing the target model or the original model meets a preset construction condition, wherein the construction condition comprises that the time for constructing the original model is smaller than a preset threshold value.
The vehicle model construction device provided by the embodiment of the invention can execute the vehicle model construction method provided by any embodiment of the invention, and has the corresponding functional modules and beneficial effects of the execution method.
Example IV
Fig. 6 is a schematic structural diagram of a computer device according to a fourth embodiment of the present invention. FIG. 6 illustrates a block diagram of an exemplary computer device 12 suitable for use in implementing embodiments of the present invention. The computer device 12 shown in fig. 6 is merely an example and should not be construed as limiting the functionality and scope of use of embodiments of the present invention.
As shown in FIG. 6, the computer device 12 is in the form of a general purpose computing device. Components of computer device 12 may include, but are not limited to: one or more processors or processing units 16, a system memory 28, a bus 18 that connects the various system components, including the system memory 28 and the processing units 16.
Bus 18 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor, and a local bus using any of a variety of bus architectures. By way of example, and not limitation, such architectures include Industry Standard Architecture (ISA) bus, micro channel architecture (MAC) bus, enhanced ISA bus, video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus.
Computer device 12 typically includes a variety of computer system readable media. Such media can be any available media that is accessible by computer device 12 and includes both volatile and nonvolatile media, removable and non-removable media.
The system memory 28 may include computer system readable media in the form of volatile memory, such as Random Access Memory (RAM) 30 and/or cache memory 32. The computer device 12 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 34 may be used to read from or write to non-removable, nonvolatile magnetic media (not shown in FIG. 6, commonly referred to as a "hard disk drive"). Although not shown in fig. 6, a magnetic disk drive for reading from and writing to a removable non-volatile magnetic disk (e.g., a "floppy disk"), and an optical disk drive for reading from or writing to a removable non-volatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In such cases, each drive may be coupled to bus 18 through one or more data medium interfaces. Memory 28 may include at least one program product having a set (e.g., at least one) of program modules configured to carry out the functions of embodiments of the invention.
A program/utility 40 having a set (at least one) of program modules 42 may be stored in, for example, memory 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each or some combination of which may include an implementation of a network environment. Program modules 42 generally perform the functions and/or methods of the embodiments described herein.
The computer device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), one or more devices that enable a user to interact with the computer device 12, and/or any devices (e.g., network card, modem, etc.) that enable the computer device 12 to communicate with one or more other computing devices. Such communication may occur through an input/output (I/O) interface 22. Moreover, computer device 12 may also communicate with one or more networks such as a Local Area Network (LAN), a Wide Area Network (WAN) and/or a public network, such as the Internet, through network adapter 20. As shown, network adapter 20 communicates with other modules of computer device 12 via bus 18. It should be appreciated that although not shown, other hardware and/or software modules may be used in connection with computer device 12, including, but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, data backup storage systems, and the like.
The processing unit 16 executes various functional applications and data processing by running programs stored in the system memory 28, for example, implementing the construction method of the vehicle model provided by the embodiment of the present invention.
Example five
The fifth embodiment of the present invention further provides a computer readable storage medium, on which a computer program is stored, where the computer program when executed by a processor implements each process of the method for constructing a vehicle model, and the same technical effects can be achieved, so that repetition is avoided, and no further description is given here.
The computer readable storage medium may include, for example, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the computer-readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
Note that the above is only a preferred embodiment of the present invention and the technical principle applied. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, while the invention has been described in connection with the above embodiments, the invention is not limited to the embodiments, but may be embodied in many other equivalent forms without departing from the spirit or scope of the invention, which is set forth in the following claims.

Claims (9)

1. A method of constructing a vehicle model, comprising:
generating a plurality of virtual machines with the same environments as the plurality of vehicles respectively;
receiving a first request for building a model;
respectively importing an original model into a plurality of virtual machines in response to the first request, wherein the original model is a model which is trained and is applied to automatic driving of a vehicle after construction;
responding to the first request, respectively constructing the original models in a plurality of virtual machines, and obtaining a plurality of target models;
Issuing a plurality of target models for the original model;
receiving a second request sent by the vehicle for downloading the original model;
responding to the second request, and sending a plurality of target models and/or original models corresponding to the original models to the vehicle, wherein the vehicle is used for loading the target models or constructing the original models in the vehicle;
receiving a third request for the vehicle to query the target model;
responding to the third request, and inquiring the target model constructed in the virtual machine with the same environment as the vehicle to obtain an inquiring result;
notifying the vehicle of the query result, wherein the vehicle is used for loading the target model when the environment is the same as the virtual machine for constructing the target model, and constructing the original model in the environment of the vehicle when the environment is different from the virtual machine for constructing the target model or the original model meets a preset construction condition, and the construction condition comprises that the time for constructing the original model is less than a preset threshold;
wherein, responding to the first request, respectively constructing the original models in a plurality of virtual machines to obtain a plurality of target models, including:
Extracting a configuration file from the first request, wherein information for constructing the original model is recorded in the configuration file;
and respectively constructing the original models in the virtual machines according to the configuration files to obtain a plurality of target models.
2. The method of claim 1, wherein receiving the first request to build the model comprises:
a first request sent by a command line tool to build a model is received through a fast interface framework FastAPI.
3. The method of claim 1, wherein the importing the original model into the plurality of virtual machines, respectively, in response to the first request comprises:
extracting an identification of an original model from the first request;
downloading the original model from a path appointed in the virtual machine according to the identification;
and respectively importing the original models into a plurality of virtual machines.
4. The method of claim 1, wherein said constructing said original model in a plurality of said virtual machines in response to said first request to obtain a plurality of target models, respectively, further comprises:
querying a first catalogue where the original model is located in each virtual machine;
And setting a path for outputting the original model as the first catalog in the configuration file.
5. The method of claim 1, wherein said constructing said original model in a plurality of said virtual machines in response to said first request to obtain a plurality of target models, respectively, further comprises:
inquiring a preset second catalogue in each virtual machine;
and setting the path of the output result of the original model as the second catalog in the configuration file.
6. The method according to claim 1, wherein said constructing said original model in a plurality of said virtual machines according to said configuration file to obtain a plurality of target models, respectively, comprises:
searching script files configured for the original model in each virtual machine;
and calling the script file to construct the original model according to the configuration file, and obtaining a target model.
7. A vehicle model construction apparatus, comprising:
the virtual machine generation module is used for generating a plurality of virtual machines with the same environments as the plurality of vehicles respectively;
the first request receiving module is used for receiving a first request for constructing a model;
The original model importing module is used for respectively importing an original model into a plurality of virtual machines in response to the first request, wherein the original model is a model which is trained and is applied to automatic driving of a vehicle after construction;
the original model construction module is used for responding to the first request and respectively constructing the original models in a plurality of virtual machines to obtain a plurality of target models;
the object model issuing module is used for issuing a plurality of object models aiming at the original model;
the second request receiving module is used for receiving a second request sent by the original model downloaded by the vehicle;
the target model sending module is used for responding to the second request and sending a plurality of target models and/or original models corresponding to the original models to the vehicle, wherein the vehicle is used for loading the target models or constructing the original models in the vehicle;
a third request receiving module for receiving a third request for the vehicle to query the target model;
the target model query module is used for responding to the third request and querying the target model constructed in the virtual machine with the same environment as the vehicle to obtain a query result;
A query result notification module, configured to notify the vehicle of the query result, where the vehicle is configured to load the target model when an environment is the same as the virtual machine that constructs the target model, and construct the original model in the environment of the vehicle when the environment is different from the virtual machine that constructs the target model or the original model meets a preset construction condition, where the construction condition includes that a time for constructing the original model is less than a preset threshold;
wherein, the original model construction module comprises:
the configuration file extraction module is used for extracting a configuration file from the first request, and the configuration file records information for constructing the original model;
and the configuration file construction module is used for constructing the original models in the virtual machines according to the configuration files respectively to obtain a plurality of target models.
8. A computer device, the computer device comprising:
one or more processors;
a memory for storing one or more programs,
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method of constructing a vehicle model of any of claims 1-6.
9. A computer-readable storage medium, on which a computer program is stored, which computer program, when being executed by a processor, implements a method of constructing a vehicle model according to any one of claims 1-6.
CN202111004842.0A 2021-08-30 2021-08-30 Vehicle model construction method and device, computer equipment and storage medium Active CN113705097B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111004842.0A CN113705097B (en) 2021-08-30 2021-08-30 Vehicle model construction method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111004842.0A CN113705097B (en) 2021-08-30 2021-08-30 Vehicle model construction method and device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113705097A CN113705097A (en) 2021-11-26
CN113705097B true CN113705097B (en) 2024-04-02

Family

ID=78656892

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111004842.0A Active CN113705097B (en) 2021-08-30 2021-08-30 Vehicle model construction method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113705097B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114968445B (en) * 2022-03-11 2023-11-21 重庆长安汽车股份有限公司 Vehicle view configuration method and system for APP and readable storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109800475A (en) * 2018-12-27 2019-05-24 北京百度网讯科技有限公司 Automatic Pilot data processing method, device, equipment and computer storage medium
CN112434371A (en) * 2020-11-14 2021-03-02 武汉中海庭数据技术有限公司 Joint simulation method and system supporting large-scale vehicles
CN112836395A (en) * 2021-03-10 2021-05-25 北京车和家信息技术有限公司 Vehicle driving data simulation method and device, electronic equipment and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20210158147A1 (en) * 2019-11-26 2021-05-27 International Business Machines Corporation Training approach determination for large deep learning models
JP7310641B2 (en) * 2020-02-20 2023-07-19 トヨタ自動車株式会社 Model generation method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109800475A (en) * 2018-12-27 2019-05-24 北京百度网讯科技有限公司 Automatic Pilot data processing method, device, equipment and computer storage medium
CN112434371A (en) * 2020-11-14 2021-03-02 武汉中海庭数据技术有限公司 Joint simulation method and system supporting large-scale vehicles
CN112836395A (en) * 2021-03-10 2021-05-25 北京车和家信息技术有限公司 Vehicle driving data simulation method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN113705097A (en) 2021-11-26

Similar Documents

Publication Publication Date Title
US20210011908A1 (en) Model-based structured data filtering in an autonomous vehicle
US11829896B2 (en) Uncertainty-based data filtering in a vehicle
KR102225822B1 (en) Apparatus and method for generating learning data for artificial intelligence performance
CN105739337B (en) A kind of human-computer interaction type voice control and teaching system and method
CN110399306B (en) Automatic testing method and device for software module
CN104731607A (en) Terminal lifelong learning handling method, device and system
CN109614325B (en) Method and device for determining control attribute, electronic equipment and storage medium
US20230034173A1 (en) Incident resolution
WO2020182892A1 (en) System and method for interoperable communication of between entities with different structures
CN113705097B (en) Vehicle model construction method and device, computer equipment and storage medium
CN104135520A (en) Method and device for identifying Android terminal
US20220114477A1 (en) Event driven configurable artificial intelligence workflow
CN111753862A (en) Method and device for training neural network model and image recognition method
CN111552665B (en) Method, device, equipment and medium for converting annotation information format
CN112652302A (en) Voice control method, device, terminal and storage medium
CN114327185A (en) Vehicle screen control method and device, medium and electronic equipment
CN117370523A (en) Large language model application service method and device
US20230273826A1 (en) Neural network scheduling method and apparatus, computer device, and readable storage medium
CN116226850A (en) Method, device, equipment, medium and program product for detecting virus of application program
CN110838338A (en) System, method, storage medium, and electronic device for creating biological analysis item
CN111143424A (en) Characteristic scene data mining method and device and terminal
CN115185625A (en) Self-recommendation type interface updating method based on configurable card and related equipment thereof
CN114896094A (en) Fault positioning method and device, electronic equipment and storage medium
US20210012220A1 (en) Rules-based structured data filtering in an autonomous vehicle
CN113449094A (en) Corpus obtaining method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant