CN112559885A - Method and device for determining training model of map interest point and electronic equipment - Google Patents

Method and device for determining training model of map interest point and electronic equipment Download PDF

Info

Publication number
CN112559885A
CN112559885A CN202011561079.7A CN202011561079A CN112559885A CN 112559885 A CN112559885 A CN 112559885A CN 202011561079 A CN202011561079 A CN 202011561079A CN 112559885 A CN112559885 A CN 112559885A
Authority
CN
China
Prior art keywords
poi
training
training model
model
error value
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.)
Granted
Application number
CN202011561079.7A
Other languages
Chinese (zh)
Other versions
CN112559885B (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.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and 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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202011561079.7A priority Critical patent/CN112559885B/en
Publication of CN112559885A publication Critical patent/CN112559885A/en
Application granted granted Critical
Publication of CN112559885B publication Critical patent/CN112559885B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/29Geographical information databases
    • 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/9537Spatial or temporal dependent retrieval, e.g. spatiotemporal queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/289Phrasal analysis, e.g. finite state techniques or chunking
    • G06F40/295Named entity recognition
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • G06N20/20Ensemble learning

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Computation (AREA)
  • Software Systems (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Evolutionary Biology (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Remote Sensing (AREA)
  • Machine Translation (AREA)

Abstract

The application discloses a method and a device for determining a training model of a map interest point and electronic equipment, and relates to the technical field of natural language processing and big data in the field of deep learning, wherein the method comprises the following steps: acquiring at least one type of pre-training task related to a point of interest (POI); determining a training model in a first stage according to a pre-training task; and determining the training model of the second stage according to the parameters of the training model of the first stage and at least one type of special tasks related to POI. The method and the device can improve the performance of all downstream natural language processing tasks in the map POI name field, and can be issued as a universal model parameter, so that the processing efficiency of the map POI is greatly improved.

Description

Method and device for determining training model of map interest point and electronic equipment
Technical Field
The application discloses a method, a device, equipment, a medium and a program product for determining a training model of a map interest point, in particular to the technical field of deep learning, and specifically relates to natural language processing and big data.
Background
The map application utilizes the internet technology to connect the real world, and with the development of 5G and AI, the data of the map industry is more and more huge and abundant, wherein besides the image data such as the signboard image, the data also comprises the text data such as the name of a POI (Point of interest) on the signboard image, the text data in the intelligent intelligence, and the like, and the text data is directly or indirectly related to the name of the POI.
Models used in the POI field are different, which results in that many models cannot share a part of the domain knowledge, for example, models such as LSTM need to train related tasks from scratch, and the domain knowledge cannot be extracted from the related tasks.
The parameters of the existing pre-training model are obtained by repeatedly training on a general language library, the knowledge of the POI field is not provided, and a plurality of semantic relations and characteristics in the POI field have great difference with general texts. Although the pre-training parameters provided by the system can be used for fine adjustment, the system is not good in actual engineering and cannot be shared for migration training.
Disclosure of Invention
The application provides a method, a device, equipment, a medium and a program product for determining a training model of a map interest point.
According to an aspect of the present application, there is provided a method for determining a training model of a map interest point, the method including:
acquiring at least one type of pre-training task related to a point of interest (POI);
determining a training model in a first stage according to the pre-training task;
and determining a training model of a second stage according to the parameters of the training model of the first stage and at least one type of proprietary tasks related to the POI.
According to another aspect of the present application, there is provided a training model determining apparatus for a map interest point, including:
the system comprises an acquisition module, a pre-training module and a pre-training module, wherein the acquisition module is used for acquiring at least one type of pre-training task related to a point of interest (POI);
the first processing module is used for determining a training model in a first stage according to the pre-training task;
and the second processing module is used for determining the training model at the second stage according to the parameters of the training model at the first stage and at least one type of proprietary tasks related to the POI.
According to another aspect of the present application, there is provided an electronic device including:
at least one processor;
and a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method for training model determination of map points of interest provided herein.
According to another aspect of the present application, there is provided a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the method for training model determination of map points of interest provided herein.
According to another aspect of the present application, a computer program product is provided, comprising a computer program which, when executed by a processor, implements the method for determining a training model of a map point of interest provided herein.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present application, nor do they limit the scope of the present application. Other features of the present application will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not intended to limit the present application. Wherein:
FIG. 1 is a flowchart of a method for determining a training model of a map point of interest provided in the present application;
FIG. 2 is a schematic flow chart of another method for determining a training model of a map point of interest provided in the present application;
FIG. 3 is a schematic diagram of a first-stage and second-stage implementation flow in a method for determining a training model of a map interest point provided by the present application;
FIG. 4 is a flowchart illustrating a method for determining a training model for a second stage according to an embodiment of the present disclosure;
FIG. 5 is a structural diagram of a coordinate embedding layer of a training model determination method for map interest points according to the present application;
FIG. 6 is a block diagram of a device for determining a training model of a map interest point according to the present application;
fig. 7 is a block diagram of an electronic device for implementing a method for determining a training model of a map interest point according to an embodiment of the present application.
Detailed Description
The following description of the exemplary embodiments of the present application, taken in conjunction with the accompanying drawings, includes various details of the embodiments of the application for the understanding of the same, which are to be considered exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
The following description of the exemplary embodiments of the present application, taken in conjunction with the accompanying drawings, includes various details of the embodiments of the application for the understanding of the same, which are to be considered exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
A method, an apparatus, a device, a medium, and a program product for determining a training model of a map point of interest according to embodiments of the present application are described below with reference to the accompanying drawings.
Fig. 1 is a schematic flowchart of a method for determining a training model of a map interest point according to an embodiment of the present application.
The embodiment of the present application is exemplified in that the training model determining method is configured in a training model determining apparatus, and the training model determining apparatus may be applied to any electronic device, so that the electronic device may perform a training model determining function.
The electronic device may be a Personal Computer (PC), a cloud device, a mobile device, and the like, and the mobile device may be a hardware device having various operating systems, such as a mobile phone, a tablet Computer, a Personal digital assistant, a wearable device, and an in-vehicle device.
As shown in fig. 1, the method for determining a training model of a map interest point may include the following steps: step S101, at least one type of pre-training task related to the POI is obtained.
And S102, determining a training model in a first stage according to the pre-training task.
Step S103, determining a training model at the second stage according to the parameters of the training model at the first stage and at least one type of special tasks related to POI.
In the embodiment of the application, pre-training is performed in stages, and the training in the first stage obtains a language model which is weakly related to the POI field, and the optimization aims to convert the model with low confusion in the general field and high confusion in the POI field into the model with low confusion in the POI field. And in the second stage of training, deep semantic extraction tasks of the language model in the POI field are further evolved, and evaluation indexes of corresponding tasks are improved, so that a universal language model which is strongly related to the POI field is obtained.
On the basis of the embodiment, the application provides another method for determining the training model of the map interest points.
Fig. 2 is a schematic flowchart of another method for determining a training model of a map interest point according to an embodiment of the present disclosure.
As shown in fig. 2, the method for determining a training model of a map interest point may further include the following steps:
in step S201, at least one of a mask language model, a next sentence prediction model, and an entire word mask model related to the POI is acquired.
Here, the mask language model uses the language model to predict the words that are masked by randomly masking the words in the POI name with mask;
the next sentence prediction model is input into a network for coding by truncating a longer POI name into two text segments or forming a text pair form by using the POI names with alias names, and finally, the feature corresponding to the first zone bit [ CLS ] is selected as the input feature of the classifier for classification;
the whole word masking model is used for uniformly masking two words with word-level meanings.
Step S202, using a mask language model to encode the input POI name, and obtaining a first error value.
In specific implementation, characters in the POI name are randomly covered by using a covering function, characters at covered positions are predicted, the predicted characters are compared with actual characters at the covered positions, and a first error value is obtained.
Step S203, using the next sentence prediction model to encode the input POI name, and obtaining a second error value.
In the concrete implementation, the POI name is divided into at least two text sections, a second text section is predicted according to the first text section, and the predicted second text section is compared with a real second text section to obtain a second error value.
Step S204, a whole word covering model is adopted to encode the input POI name, and a third error value is obtained.
In specific implementation, a plurality of characters of a word level in the POI name are randomly masked by using a masking function, words at the masked positions are predicted, and the predicted words are compared with actual words at the masked positions to obtain a third error value.
In step S205, a sum of the first error value, the second error value and the third error value is determined, and the sum is used as an output of the training model in the first stage.
Wherein the sum is the first error value + the second error value + the third error value. As shown in fig. 3, the flowchart is a flow chart for implementing tasks performed in a first stage and a second stage of a POI (point of interest) pre-training algorithm, the POI pre-training algorithm is specifically divided into two training stages, each stage includes a corresponding pre-training task, the first stage directly performs pre-training by multi-task learning, where MLM is a Mask Language Model (Mask Language Model), NSP is Next statement Prediction (Next sequence Prediction), and WWM is Whole Word Mask (Whole Word Mask);
here, the mask language model randomly masks the words in the POI name with mask, and predicts the masked words using the language model, for example, masking the 'lanzhou beef pull plane' to 'CLS' lanzhou 'lamb' mask meat pull plane 'SEP', inputting into the pre-training model for encoding, and predicting the actual word 'cow' at the position of the 'mask';
the next sentence prediction model is to cut the longer POI name into two text segments, or to use the POI name with alias to compose the text pair, input it into the network for encoding, finally select the feature corresponding to the first flag bit [ CLS ] as the input feature of the classifier for classification, for example, "langzhou beef ramen (post-factory village store)" is encoded as "[ CLS ] langzhou beef ramen [ SEP ] post-factory village store [ SEP ] for classification in the input encoder, of course, two different POIs can also be randomly sampled for combination;
whole word masking: similar to MLM, the only difference is that masking is unified for two words with word-level meaning, adding domain knowledge such as "lanzhou beef pull-up" directly masked as "CLS" lanzhou mask "pull-up [ SEP ].
It can be noted that, in this embodiment, the pre-training content in the first stage includes a mask language model, a next sentence prediction model, and a whole word mask model, and a first error value loss1, a second error value loss2, and a third error value loss3 are respectively obtained, and the sum of the first error value loss1, the second error value loss2, and the third error value loss3 is used to obtain the output of the first stage model, that is, the formula loss1+ loss2+ loss3, where loss is the output of the first stage model.
Step S206, determining the training model of the second stage according to the parameters of the training model of the first stage and at least one type of special tasks related to POI.
It should be noted that, the implementation process of step S206 may refer to the implementation process of step S103 in the foregoing embodiment, and is not described herein again.
Based on the above embodiment, when determining the training model at the second stage, the first type of POI-related proprietary task may be trained under the condition that the parameter of the training model at the first stage is minimum, which is described in detail below with reference to fig. 4, where fig. 4 is a flowchart illustrating a method for determining the training model at the second stage according to an embodiment of the present disclosure.
As shown in fig. 4, the method may further include the steps of:
step S401, under the condition that the parameters of the training model in the first stage are minimum, a first type of special tasks related to POI are trained to obtain a first result.
Step S402, training the input N + 1-th type special task related to the POI based on the first result to obtain an N + 1-th result, wherein N is a positive integer.
In the embodiment of the application, named entity recognition under a POI scene is carried out on an input N + 1-th type special task related to the POI, and at least one of POI classification, POI matching, label classification and initial matching processing is carried out.
The POI classification includes: distinguishing whether a POI is a real POI name;
POI matching includes: matching whether the two sections of texts are the same POI or not;
the label classification includes: one tag for each POI; the initial matching comprises: and splicing the Pinyin letter headers of the POI names and matching the POI names.
As shown in fig. 3, the second stage of training is performed by a continuous learning method framework for multi-task learning:
performing a pre-training task 1 on the POI names which are pre-trained in the first stage;
performing a pre-training task 1 and a pre-training task 2;
then carrying out a pre-training task 1, a pre-training task 2 and a pre-training task 3;
and finally, performing a pre-training task 1, a pre-training task 2, a pre-training task 3 and … …, wherein the pre-training task N-1 and the pre-training task N are positive integers, and obtaining a satisfactory POI name learning result.
It should be noted that the pre-training task 1, the pre-training task 2, and the pre-training task 3, … …, and the pre-training task in the pre-training task N-1 and the pre-training task N may include: point of interest named entity identification (POI NER), point of interest classification (POI class), point of interest match (POI match), Tag class (Tag class), initial match (capetal match).
Pre-training task 1, pre-training task 2, pre-training task 3, … …, pre-training task N-1, pre-training task N are proprietary tasks related to POI.
Explaining named entity identification, POI classification, POI matching, label classification and initial matching in the POI scene:
named entity recognition (POI NER): the named entity recognition task under the POI scene is input into a conditional random field for probability calculation by extracting the characteristics of a language model, and the category of each character is distributed, wherein a BIO marking method is generally used and is the same as the traditional NER task;
POI category (POI classsify): distinguishing whether a POI is a real POI name or not, wherein the positive sample of the part can be directly selected from a POI database, and then some negative samples are selected from a general language database or confusing phrases;
POI match (POI match): whether the two sections of texts are matched to be the same POI or not can be matched, the original POI name can be enhanced by using some data enhancement methods, for example, suffix names are removed, extra noise texts are added to obtain texts similar to the POI as positive samples, the negative samples can directly match different POI, and core words of the original POI can be removed and combined;
tag classification (tag classification): in the POI field, each POI corresponds to a corresponding Tag, for example, "hot and spicy" corresponds to "food Tag," group light square "corresponds to" shopping square Tag, and these Tag information are very important for analyzing the properties of the POI, so Tag classification task is added to the language model to perform fine-grained classification on the categories of the POI;
initial match (Capital match): this section can be applied to, for example, a scene where POIs are related to a WiFi name by concatenating the pinyin letter headers of the POI names and then matching the pinyin letter headers with the POI names, for example, "jojmlxg" and "jojmlxg" are matched with each other.
In the embodiment, a first type of special task related to POI is trained to obtain a first result;
training the input second type of special tasks related to the POI based on the first result to obtain a second result; training the input second type of special tasks related to the POI, and carrying out POI classification;
training the input third-class special tasks related to the POI based on the second result to obtain a third result; training the input third-class special tasks related to the POI, and performing POI classification and POI matching;
training the input fourth type of special tasks related to the POI based on the third result to obtain a fourth result; training the input fourth type of special tasks related to the POI, and performing POI classification, POI matching and label classification;
training the input fifth type of special tasks related to the POI based on the fourth result to obtain a fifth result; training the input fifth type of special tasks related to the POI, and performing POI classification, POI matching, label classification and initial letter matching;
based on the method, the sixth to the N types of special tasks related to POI can be further trained;
in the training model of the second stage, fine tuning training is further performed by using the model parameters after the training of the first stage, but a continuous pre-training idea is used, the model training is gradual, and the difficulty is increased by adding one task each time. The first stage is used for understanding and coding effective information in the POI field by reducing the confusion degree of the language model, and the second stage is used for further training the language model by improving the difficulty and complexity of tasks and finely adjusting parameters in the language model, so that the model is more universal and robust.
On the basis of the foregoing embodiment, in an optional embodiment of the present application, the method for determining a training model of a map interest point may further include:
the position information of the POI is embedded into the training model of the first stage.
Wherein, the position information of the POI is determined by the following method: gridding an area in a preset range where the POI is located, and taking a grid where the POI is located as position information of the POI; the size of the grid is determined by the density of POIs in the area.
As shown in fig. 5, according to the coordinate position information in the POI field, an Embedding layer of a coordinate Embedding layer is additionally added to an input Embedding layer of a pre-trained model, and a region is meshed to obtain a limited number of coordinate Embedding in a limited space, so that the area size of a mesh can be adaptively changed according to different POI densities, and thus, the POI can be modeled by combining with the position information of the real world, and the situation that the POI names are the same in different regions is effectively distinguished. The method is suitable for occasions with requirements on position information, such as text matching or search recommendation fields.
In fig. 5, coordinate embedding is corresponding coordinate information after gridding for the POI field; the position embedding is position information of the corresponding POI name; paragraph embedding is paragraph number information corresponding to the corresponding POI name text; word embedding is textual information corresponding to the corresponding POI name.
The performance of all downstream tasks in the map POI name field can be greatly improved by the embodiment of the application, and the downstream tasks can be issued as a universal model parameter, so that the efficiency of map POI team cooperation is greatly improved, and the research and development cost is saved.
In order to implement the above embodiments, the present application provides a device for determining a training model of a map interest point.
Fig. 6 is a schematic structural diagram of a device for determining a training model of a map interest point according to an embodiment of the present application.
As shown in fig. 6, the apparatus 600 for determining a training model of a map interest point may include: an acquisition module 610, a first processing module 620, and a second processing module 630.
The obtaining module 610 is configured to obtain at least one type of pre-training task related to a point of interest POI.
The first processing module 620 is configured to determine a training model of a first stage according to the pre-training task.
The second processing module 630 is configured to determine the training model of the second stage according to the parameters of the training model of the first stage and at least one type of the proprietary task related to the POI.
Optionally, the obtaining module 610 is specifically configured to: at least one of a mask language model, a next sentence prediction model, and an entire word mask model associated with the POI is obtained.
Optionally, the first processing module 620 may include:
and the first coding unit is used for coding the input POI name by adopting the mask language model to obtain a first error value.
The second coding unit is used for coding the input POI name by adopting the next statement prediction model to obtain a second error value;
the third coding unit is used for coding the input POI name by adopting the whole word covering model to obtain a third error value;
and the determining unit is used for determining the sum of the first error value, the second error value and the third error value, and taking the sum as the output of the training model in the first stage.
Optionally, the first encoding unit may be further configured to:
randomly masking characters in the POI name by using a masking function, predicting characters at the masked positions, and comparing the predicted characters with actual characters at the masked positions to obtain a first error value.
Optionally, the second encoding unit may be further configured to:
and dividing the POI name into at least two text segments, predicting a second text segment according to the first text segment, and comparing the predicted second text segment with the real second text segment to obtain a second error value.
Optionally, the third encoding unit may be further configured to:
randomly masking a plurality of characters of a word level in the POI name by using a masking function, predicting words at the masked positions, and comparing the predicted words with actual words at the masked positions to obtain a third error value.
Optionally, the second processing module 620 may further include:
the first training unit is used for training a first type of proprietary tasks related to the POI under the condition that the parameters of the training model at the first stage are minimum to obtain a first result;
and the second training unit is used for training the input (N + 1) th type of proprietary task related to the POI based on the first result to obtain an (N + 1) th result, wherein N is a positive integer.
Optionally, the second training unit may be further configured to:
carrying out named entity recognition under a POI scene on the inputted N + 1-th type POI-related proprietary task, and carrying out at least one of POI classification, POI matching, label classification and initial matching processing;
the POI classification includes: distinguishing whether a POI is a real POI name;
POI matching includes: matching whether the two sections of texts are the same POI or not;
the label classification includes: one tag for each POI;
the initial matching comprises: and splicing the Pinyin letter headers of the POI names and matching the POI names.
Optionally, the apparatus for determining a training model of a map interest point 40 may further include:
and the embedding module is used for embedding the position information of the POI into the training model in the first stage. Wherein, the position information of the POI is determined by the following method:
gridding an area in a preset range where the POI is located, and taking a grid where the POI is located as position information of the POI; the size of the grid is determined according to the density of POI in the area.
The apparatus provided in this embodiment can implement each process implemented in the method embodiments shown in the above embodiments, and can achieve the same beneficial effects, and is not described here again to avoid repetition.
In order to achieve the above embodiments, the present application proposes an electronic device including:
at least one processor;
and a memory communicatively coupled to the at least one processor;
wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method for determining a training model of map points of interest as described in the above embodiments.
In order to achieve the above embodiments, the present application proposes a non-transitory computer-readable storage medium storing computer instructions for causing the computer to execute the training model determination method of map interest points described in the above embodiments.
In order to implement the above embodiments, the present application proposes a computer program product comprising a computer program which, when executed by a processor, implements the method for determining a training model of a map point of interest described in the above embodiments.
There is also provided, in accordance with an embodiment of the present application, an electronic device, a non-transitory computer-readable storage medium having stored thereon computer instructions, and a computer program product.
FIG. 7 illustrates a schematic block diagram of an example electronic device 700 that can be used to implement embodiments of the present application. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the present application that are described and/or claimed herein.
As shown in fig. 7, the device 700 comprises a computing unit 701, which may perform various suitable actions and processes according to a computer program stored in a Read Only Memory (ROM)702 or a computer program loaded from a storage unit 708 into a Random Access Memory (RAM) 703. In the RAM703, various programs and data required for the operation of the device 700 can also be stored. The computing unit 701, the ROM702, and the RAM703 are connected to each other by a bus 704. An input/output (I/O) interface 705 is also connected to bus 704.
Various components in the device 700 are connected to the I/O interface 705, including: an input unit 706 such as a keyboard, a mouse, or the like; an output unit 707 such as various types of displays, speakers, and the like; a storage unit 708 such as a magnetic disk, optical disk, or the like; and a communication unit 709 such as a network card, modem, wireless communication transceiver, etc. The communication unit 709 allows the device 700 to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunication networks.
Computing unit 701 may be a variety of general purpose and/or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The calculation unit 701 performs the respective methods and processes described above, such as the image sample processing method. For example, in some embodiments, the image sample processing method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 708.
In some embodiments, part or all of a computer program may be loaded onto and/or installed onto device 700 via ROM702 and/or communications unit 709. When loaded into RAM703 and executed by the computing unit 701, may perform one or more of the steps of the method 708 described above. Alternatively, in other embodiments, the computing unit 701 may be configured to perform the image sample processing method by any other suitable means (e.g. by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present application may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this application, a computer-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A computer readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on 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.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The Server can be a cloud Server, also called a cloud computing Server or a cloud host, and is a host product in a cloud computing service system, so as to solve the defects of high management difficulty and weak service expansibility in the traditional physical host and VPS service ("Virtual Private Server", or simply "VPS").
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present application may be executed in parallel, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present application can be achieved, and the present invention is not limited herein.
The above-described embodiments should not be construed as limiting the scope of the present application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (23)

1. A method for determining a training model of a map point of interest, the method comprising:
acquiring at least one type of pre-training task related to a point of interest (POI);
determining a training model in a first stage according to the pre-training task;
and determining a training model of a second stage according to the parameters of the training model of the first stage and at least one type of proprietary tasks related to the POI.
2. The training model determination method of claim 1, wherein obtaining at least one class of pre-training tasks related to the POI comprises:
at least one of a mask language model, a next sentence prediction model, and an entire word mask model associated with the POI is obtained.
3. The training model determination method of claim 2, wherein determining a first stage training model from the pre-training task comprises:
coding the input POI name by adopting the mask language model to obtain a first error value;
coding the input POI name by adopting the next statement prediction model to obtain a second error value;
coding the input POI name by adopting the whole word covering model to obtain a third error value;
and determining the sum of the first error value, the second error value and the third error value, and using the sum as the output of the training model of the first stage.
4. The training model determining method according to claim 3, wherein encoding the POI name input using the mask language model to obtain a first error value comprises:
randomly masking characters in the POI name by using a masking function, predicting characters at the masked positions, and comparing the predicted characters with actual characters at the masked positions to obtain a first error value.
5. The training model determining method according to claim 3, wherein encoding the POI name input by using the next sentence prediction model to obtain a second error value comprises:
and dividing the POI name into at least two text segments, predicting a second text segment according to the first text segment, and comparing the predicted second text segment with the real second text segment to obtain a second error value.
6. The training model determination method of claim 3, wherein encoding the input POI name using the whole word masking model to obtain a third error value comprises:
randomly masking a plurality of characters of a word level in the POI name by using a masking function, predicting a word at a masked position, and comparing the predicted word with an actual word at the masked position to obtain a third error value.
7. The training model determination method of claim 1, wherein determining the training model for the second stage based on the parameters of the training model for the first stage and at least one class of proprietary tasks related to the POI comprises:
under the condition that the parameters of the training model in the first stage are minimum, a first type of special tasks related to the POI are trained to obtain a first result;
and training the input N + 1-th type of proprietary task related to the POI based on the first result to obtain an N + 1-th result, wherein N is a positive integer.
8. The training model determination method of claim 7, wherein training the input N +1 th class of proprietary tasks related to the POI comprises:
carrying out named entity recognition under a POI scene on the inputted N + 1-th type special task related to the POI, and carrying out at least one of POI classification, POI matching, label classification and initial matching processing;
the POI classification includes: distinguishing whether a POI is a real POI name;
the POI matching comprises: matching whether the two sections of texts are the same POI or not;
the label classification includes: one tag for each POI;
the first letter matching comprises: and splicing the Pinyin letter headers of the POI names and matching the POI names.
9. The training model determination method according to claim 1, further comprising:
and embedding the position information of the POI into the training model of the first stage.
10. The training model determination method of claim 9, wherein the position information of the POI is determined by:
gridding an area in a preset range where a POI is located, and taking a grid where the POI is located as position information of the POI; the size of the grid is determined according to the density of POIs in the area.
11. A training model determination apparatus for map points of interest, comprising:
the system comprises an acquisition module, a pre-training module and a pre-training module, wherein the acquisition module is used for acquiring at least one type of pre-training task related to a point of interest (POI);
the first processing module is used for determining a training model in a first stage according to the pre-training task;
and the second processing module is used for determining the training model at the second stage according to the parameters of the training model at the first stage and at least one type of proprietary tasks related to the POI.
12. The training model determination apparatus of claim 11, wherein the acquisition module is further configured to:
at least one of a mask language model, a next sentence prediction model, and an entire word mask model associated with the POI is obtained.
13. The training model determination apparatus of claim 12, wherein the first processing module comprises:
the first coding unit is used for coding the input POI name by adopting the mask language model to obtain a first error value;
the second coding unit is used for coding the input POI name by adopting the next statement prediction model to obtain a second error value;
the third coding unit is used for coding the input POI name by adopting the whole word covering model to obtain a third error value;
and the determining unit is used for determining the sum of the first error value, the second error value and the third error value, and using the sum as the output of the training model in the first stage.
14. The training model determination apparatus of claim 13, wherein the first encoding unit is further configured to:
randomly masking characters in the POI name by using a masking function, predicting characters at the masked positions, and comparing the predicted characters with actual characters at the masked positions to obtain a first error value.
15. The training model determination apparatus of claim 13, wherein the second encoding unit is further configured to:
and dividing the POI name into at least two text segments, predicting a second text segment according to the first text segment, and comparing the predicted second text segment with the real second text segment to obtain a second error value.
16. The training model determination apparatus of claim 13, wherein the third encoding unit is further configured to:
randomly masking a plurality of characters of a word level in the POI name by using a masking function, predicting a word at a masked position, and comparing the predicted word with an actual word at the masked position to obtain a third error value.
17. The training model determination apparatus of claim 11, wherein the second processing module comprises:
the first training unit is used for training a first type of proprietary tasks related to the POI under the condition that the parameters of the training model at the first stage are minimum to obtain a first result;
and the second training unit is used for training the input (N + 1) th type of proprietary task related to the POI based on the first result to obtain an (N + 1) th result, wherein N is a positive integer.
18. The training model determination apparatus of claim 17, wherein the second training unit is further configured to:
carrying out named entity recognition under a POI scene on the inputted N + 1-th type special task related to the POI, and carrying out at least one of POI classification, POI matching, label classification and initial matching processing;
the POI classification includes: distinguishing whether a POI is a real POI name;
the POI matching comprises: matching whether the two sections of texts are the same POI or not;
the label classification includes: one tag for each POI;
the first letter matching comprises: and splicing the Pinyin letter headers of the POI names and matching the POI names.
19. The training model determination apparatus of claim 11, wherein the apparatus further comprises:
and the embedding module is used for embedding the position information of the POI into the training model in the first stage.
20. The training model determination device of claim 19, wherein the position information of the POI is determined by:
gridding an area in a preset range where a POI is located, and taking a grid where the POI is located as position information of the POI; the size of the grid is determined according to the density of POIs in the area.
21. An electronic device, comprising:
at least one processor;
and a memory communicatively coupled to the at least one processor;
wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of training model determination of map points of interest of any of claims 1-10.
22. A non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the method for training model determination of map points of interest of any one of claims 1-10.
23. A computer program product comprising a computer program which, when executed by a processor, implements a method of training model determination of map points of interest according to any of claims 1-10.
CN202011561079.7A 2020-12-25 2020-12-25 Training model determining method and device for map interest points and electronic equipment Active CN112559885B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011561079.7A CN112559885B (en) 2020-12-25 2020-12-25 Training model determining method and device for map interest points and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011561079.7A CN112559885B (en) 2020-12-25 2020-12-25 Training model determining method and device for map interest points and electronic equipment

Publications (2)

Publication Number Publication Date
CN112559885A true CN112559885A (en) 2021-03-26
CN112559885B CN112559885B (en) 2024-01-12

Family

ID=75032634

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011561079.7A Active CN112559885B (en) 2020-12-25 2020-12-25 Training model determining method and device for map interest points and electronic equipment

Country Status (1)

Country Link
CN (1) CN112559885B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113342912A (en) * 2021-05-24 2021-09-03 北京百度网讯科技有限公司 Geographical location area coding method, and method and device for establishing coding model
CN113705628A (en) * 2021-08-06 2021-11-26 北京百度网讯科技有限公司 Method and device for determining pre-training model, electronic equipment and storage medium
CN113836925A (en) * 2021-09-16 2021-12-24 北京百度网讯科技有限公司 Training method and device for pre-training language model, electronic equipment and storage medium
CN114357105A (en) * 2022-03-10 2022-04-15 北京百度网讯科技有限公司 Pre-training method and model fine-tuning method of geographic pre-training model
CN114970741A (en) * 2022-06-15 2022-08-30 北京百度网讯科技有限公司 Data processing method and device and electronic equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2977916A1 (en) * 2013-03-18 2016-01-27 Baidu Online Network Technology (Beijing) Co., Ltd Search suggestion method and apparatus for map search, and computer storage medium and device
CN106372666A (en) * 2016-08-31 2017-02-01 同观科技(深圳)有限公司 Target identification method and device
CN108304873A (en) * 2018-01-30 2018-07-20 深圳市国脉畅行科技股份有限公司 Object detection method based on high-resolution optical satellite remote-sensing image and its system
US20200065302A1 (en) * 2018-08-27 2020-02-27 Baidu Online Network Technology (Beijing) Co., Ltd. Method, computer device and storage medium for mining point of interest competitive relationship
CN110909145A (en) * 2019-11-29 2020-03-24 支付宝(杭州)信息技术有限公司 Training method and device for multi-task model
CN111144115A (en) * 2019-12-23 2020-05-12 北京百度网讯科技有限公司 Pre-training language model obtaining method and device, electronic equipment and storage medium
CN111967599A (en) * 2020-08-25 2020-11-20 百度在线网络技术(北京)有限公司 Method and device for training model, electronic equipment and readable storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2977916A1 (en) * 2013-03-18 2016-01-27 Baidu Online Network Technology (Beijing) Co., Ltd Search suggestion method and apparatus for map search, and computer storage medium and device
CN106372666A (en) * 2016-08-31 2017-02-01 同观科技(深圳)有限公司 Target identification method and device
CN108304873A (en) * 2018-01-30 2018-07-20 深圳市国脉畅行科技股份有限公司 Object detection method based on high-resolution optical satellite remote-sensing image and its system
US20200065302A1 (en) * 2018-08-27 2020-02-27 Baidu Online Network Technology (Beijing) Co., Ltd. Method, computer device and storage medium for mining point of interest competitive relationship
CN110909145A (en) * 2019-11-29 2020-03-24 支付宝(杭州)信息技术有限公司 Training method and device for multi-task model
CN111144115A (en) * 2019-12-23 2020-05-12 北京百度网讯科技有限公司 Pre-training language model obtaining method and device, electronic equipment and storage medium
CN111967599A (en) * 2020-08-25 2020-11-20 百度在线网络技术(北京)有限公司 Method and device for training model, electronic equipment and readable storage medium

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
JIN-YOUNG KIM 等: ""Personalized POI Embedding for Successive POI Recommendation with Large-scale Smart Card Data"", 《IEEE》 *
何馨宇;李丽双;: "基于双向LSTM和两阶段方法的触发词识别", 中文信息学报, no. 06 *
吴小雪;张庆辉;: "预训练语言模型在中文电子病历命名实体识别上的应用", 电子质量, no. 09 *

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113342912A (en) * 2021-05-24 2021-09-03 北京百度网讯科技有限公司 Geographical location area coding method, and method and device for establishing coding model
CN113705628A (en) * 2021-08-06 2021-11-26 北京百度网讯科技有限公司 Method and device for determining pre-training model, electronic equipment and storage medium
CN113705628B (en) * 2021-08-06 2024-02-06 北京百度网讯科技有限公司 Determination method and device of pre-training model, electronic equipment and storage medium
CN113836925A (en) * 2021-09-16 2021-12-24 北京百度网讯科技有限公司 Training method and device for pre-training language model, electronic equipment and storage medium
CN114357105A (en) * 2022-03-10 2022-04-15 北京百度网讯科技有限公司 Pre-training method and model fine-tuning method of geographic pre-training model
CN114357105B (en) * 2022-03-10 2022-06-10 北京百度网讯科技有限公司 Pre-training method and model fine-tuning method of geographic pre-training model
WO2023168909A1 (en) * 2022-03-10 2023-09-14 北京百度网讯科技有限公司 Pre-training method and model fine-tuning method for geographical pre-training model
CN114970741A (en) * 2022-06-15 2022-08-30 北京百度网讯科技有限公司 Data processing method and device and electronic equipment

Also Published As

Publication number Publication date
CN112559885B (en) 2024-01-12

Similar Documents

Publication Publication Date Title
CN112560501B (en) Semantic feature generation method, model training method, device, equipment and medium
CN112559885B (en) Training model determining method and device for map interest points and electronic equipment
CN112560496A (en) Training method and device of semantic analysis model, electronic equipment and storage medium
US20230011678A1 (en) Method for predicting protein-protein interaction
CN113361578B (en) Training method and device for image processing model, electronic equipment and storage medium
CN113407698B (en) Method and device for training and recognizing intention of intention recognition model
CN113420822B (en) Model training method and device and text prediction method and device
CN113836925A (en) Training method and device for pre-training language model, electronic equipment and storage medium
CN113553412A (en) Question and answer processing method and device, electronic equipment and storage medium
CN113722493A (en) Data processing method, device, storage medium and program product for text classification
CN115293149A (en) Entity relationship identification method, device, equipment and storage medium
CN114861637B (en) Spelling error correction model generation method and device, and spelling error correction method and device
CN113407610A (en) Information extraction method and device, electronic equipment and readable storage medium
CN114417878B (en) Semantic recognition method and device, electronic equipment and storage medium
CN115640520A (en) Method, device and storage medium for pre-training cross-language cross-modal model
CN115358243A (en) Training method, device, equipment and storage medium for multi-round dialogue recognition model
CN114647727A (en) Model training method, device and equipment applied to entity information recognition
CN112989797B (en) Model training and text expansion methods, devices, equipment and storage medium
CN112699237B (en) Label determination method, device and storage medium
CN112632227A (en) Resume matching method, resume matching device, electronic equipment, storage medium and program product
CN116662484A (en) Text regularization method, device, equipment and storage medium
CN113361522B (en) Method and device for determining character sequence and electronic equipment
CN114091463B (en) Regional work order random point analysis method and device, electronic equipment and readable storage medium
CN114817476A (en) Language model training method and device, electronic equipment and storage medium
CN114841172A (en) Knowledge distillation method, apparatus and program product for text matching double tower model

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