Virtual pet generation method, device, electronic device and storage medium

By obtaining user characteristics, determining the types and characteristics of target pets, and using maps to generate virtual pets that match the user, solving the problem of complex and single types of virtual pet generation process, realizing that users can generate virtual pets that match themselves with one click, improving the user experience.

CN114904281BActive Publication Date: 2025-09-02NEW RUIPENG PET HEALTHCARE GRP CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210463884.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-28
Publication Date
2025-09-02
Estimated Expiration
2042-04-28

AI Technical Summary

Technical Problem

The existing virtual pet generation process is complicated, and user customization lacks imagination and does not match users. The merchant has formulated a single type of virtual pet, which cannot meet the diverse needs of users, and the user experience is poor.

Method used

By obtaining user characteristics, determining the type and characteristics of the target pet, and using maps to generate virtual pets that match the user, simplifying the generation process.

Benefits of technology

It realizes that users generate virtual pets that match themselves with one click, simplifies the generation process and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114904281B_ABST
    Figure CN114904281B_ABST
Patent Text Reader

Abstract

The embodiments of the present application disclose a method, device, electronic device, and storage medium for generating a virtual pet. The method comprises: upon receiving a virtual pet generation request from a target user, obtaining the target user's user characteristics; determining a target pet type corresponding to the target user based on the user characteristics; determining multiple target pet features corresponding to the target user based on the target pet type and the user characteristics, wherein the multiple target pet features are composed of features of various body parts of the virtual pet; obtaining multiple target maps corresponding to the multiple target pet features, wherein the multiple target pet features correspond one-to-one to the multiple target maps, and each target map is used to generate a target pet feature; and generating the virtual pet based on the multiple target maps. The embodiments of the present application facilitate simplifying the virtual pet generation process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of electronic technology, and in particular to a method, device, electronic device and storage medium for generating a virtual pet. Background Art

[0002] Currently, all virtual pets are either customized by users or pre-made by vendors for users to choose from. For users lacking imagination, customizing a pet may be difficult, as the entire customization process is complex and the resulting virtual pet may not be compatible with the user. Virtual pets pre-made by vendors are often limited in variety, failing to meet users' diverse needs and resulting in a poor user experience.

[0003] How to simplify the process of generating virtual pets and generate virtual pets that are adapted to users is a technical problem that needs to be solved urgently. Summary of the Invention

[0004] The embodiments of the present application provide a method, device, electronic device, and storage medium for generating a virtual pet, which generates a virtual pet matching the user with one click based on user characteristics, simplifies the virtual pet generation process, and improves the user experience.

[0005] In a first aspect, an embodiment of the present application provides a method for generating a virtual pet, comprising:

[0006] When a virtual pet generation request of a target user is obtained, user characteristics of the target user are obtained;

[0007] Determining a target pet type corresponding to the target user based on the user characteristics;

[0008] Determining a plurality of target pet features corresponding to the target user according to the target pet type and the user features, wherein the plurality of target pet features are composed of features of various body parts of the virtual pet;

[0009] Obtain multiple target maps corresponding to the multiple target pet features, wherein the multiple target pet features and the multiple target maps Figure 1 One-to-one, each target map is used to generate a target pet feature;

[0010] The virtual pet is generated according to the multiple target maps.

[0011] In a second aspect, an embodiment of the present application provides a virtual pet generating device, comprising: an acquiring unit and a processing unit;

[0012] The acquiring unit is configured to acquire user characteristics of the target user when acquiring a virtual pet generation request from the target user;

[0013] The processing unit is configured to determine a plurality of target pet features corresponding to the target user according to the target pet type and the user features, wherein the plurality of target pet features are composed of features of various body parts of the virtual pet; and obtain a plurality of target maps corresponding to the plurality of target pet features, wherein the plurality of target pet features and the plurality of target maps are connected. Figure 1 Each target map is used to generate a target pet feature in a one-to-one correspondence; the virtual pet is generated according to the multiple target maps.

[0014] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a processor, the processor being connected to a memory, the memory being used to store a computer program, the processor being used to execute the computer program stored in the memory, so that the electronic device executes the method described in the first aspect.

[0015] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and the computer program enables a computer to execute the method described in the first aspect.

[0016] In a fifth aspect, an embodiment of the present application provides a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer is operable to enable the computer to execute the method described in the first aspect.

[0017] The implementation of the embodiments of the present application has the following beneficial effects:

[0018] As can be seen, in the embodiment of the present application, when a user has a need to generate a virtual pet, they can submit a virtual pet generation request through the user terminal, that is, requesting to generate a virtual pet with one click. Then, the virtual pet generation device can obtain the user's user characteristics and determine the pet type that is compatible with the user (i.e., the target pet type) based on the user characteristics; then, based on the target pet type and the user characteristics, determine the user's favorite pet characteristics, i.e., the target pet characteristics; finally, based on the target pet characteristics, a virtual pet that is compatible with the user is generated based on the target map corresponding to the target pet characteristics. Therefore, in the embodiment of the present application, the user only needs to submit a virtual pet request to generate a virtual pet that is compatible with the user, without the user having to make it independently. This simplifies the virtual pet generation process, realizes intelligent virtual pet generation, and improves the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0020] Figure 1 A flowchart of a virtual pet generation system provided in an embodiment of the present application;

[0021] Figure 2 A flowchart of a method for generating a virtual pet provided in an embodiment of the present application;

[0022] Figure 3 A schematic diagram of registering and authorizing on a front-end application provided in an embodiment of the present application;

[0023] Figure 4 A schematic diagram of constructing a social topology graph and a sub-social topology graph provided in an embodiment of the present application;

[0024] Figure 5 A schematic diagram of a basic map provided in an embodiment of the present application;

[0025] Figure 6 A schematic diagram of superimposing a basic map provided in an embodiment of the present application;

[0026] Figure 7 A block diagram of the functional units of a virtual pet generation device provided in an embodiment of the present application;

[0027] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0028] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0029] The terms "first," "second," "third," and "fourth," etc., in the specification and claims of this application and the accompanying drawings are used to distinguish between different objects, rather than to describe a specific order. In addition, the terms "including," "having," and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus comprising a series of steps or elements is not limited to the listed steps or elements, but may optionally include steps or elements not listed, or may optionally include other steps or elements inherent to the process, method, product, or apparatus.

[0030] References herein to "embodiments" mean that a particular feature, result, or characteristic described in connection with the embodiments may be included in at least one embodiment of the present application. The appearance of this phrase in various places in the specification does not necessarily refer to the same embodiment, nor does it constitute an independent or alternative embodiment that is mutually exclusive of other embodiments. It is understood, both explicitly and implicitly, by those skilled in the art that the embodiments described herein may be combined with other embodiments.

[0031] See Figure 1 , Figure 1 The embodiment of the present application provides a virtual pet generation system. The virtual pet generation system includes a user terminal 10 and a virtual pet generation device 20. The virtual pet generation device 20 maintains a front-end application, and the user terminal 10 is installed with the front-end application.

[0032] For example, a target user (i.e., a user who wishes to create a virtual pet) can submit a virtual pet creation request to the virtual pet creation device 20 via a front-end application on the user terminal 10. Accordingly, the virtual pet creation device 20 can receive the virtual pet creation request and, based on the target user's user characteristics, determine a target pet type corresponding to the target user, i.e., the target pet type in which the target user is interested. Furthermore, based on the target pet type and the user characteristics, multiple target pet features corresponding to the target user are determined, i.e., the pet features in which the target user is interested. These multiple target pet features are comprised of features of various body parts of the virtual pet. Furthermore, based on these multiple target pet features, multiple target maps corresponding to the target user are determined. Specifically, multiple target maps corresponding to the multiple target features are retrieved from a map library, each of which is used to generate the target pet features corresponding to the target map. Finally, the virtual pet is generated based on the multiple target maps, i.e., the multiple target maps are superimposed to obtain the virtual pet.

[0033] As can be seen, in the embodiment of the present application, when a user has a need to generate a virtual pet, they can submit a virtual pet generation request through the user terminal, that is, requesting to generate a virtual pet with one click. Then, the virtual pet generation device can obtain the user's user characteristics and determine the pet type that is compatible with the user (i.e., the target pet type) based on the user characteristics; then, based on the target pet type and the user characteristics, determine the user's favorite pet characteristics, i.e., the target pet characteristics; finally, based on the target pet characteristics, a virtual pet that is compatible with the user is generated based on the target map corresponding to the target pet characteristics. Therefore, in the embodiment of the present application, the user only needs to submit a virtual pet request to generate a virtual pet that is compatible with the user, without the user having to make it independently. This simplifies the virtual pet generation process, realizes intelligent virtual pet generation, and improves the user experience.

[0034] See Figure 2 , Figure 2 The following is a flow chart of a method for generating a virtual pet provided in an embodiment of the present application. The method is applied to the above-mentioned virtual pet generating device 20. The method includes but is not limited to the following steps:

[0035] 201: When a virtual pet generation request from a target user is obtained, the virtual pet generation device obtains user characteristics of the target user.

[0036] Exemplarily, the virtual pet generating device 20 maintains a front-end application, and the target user can submit a virtual pet generation request on the front-end application to achieve one-click generation of a virtual pet. The front-end application can be an application, a small program, etc. It should be noted that the target user is any registered user in the front-end application. In order to achieve one-click generation of a virtual pet, such as Figure 3 As shown, the target user needs to complete the registration on the front-end application and become a registered user of the virtual pet generating device. The target user also grants the virtual pet generating device the authority to obtain the user characteristics of the target user. Therefore, after the target user completes the registration, as shown in FIG. Figure 3 As shown, the one-key generation function button of the virtual pet on the front-end application can be clicked to submit the virtual pet generation request to the virtual pet generation device.

[0037] In addition, after acquiring the user characteristics of the target user, the virtual pet generating device 20 only uses the user characteristics to generate a virtual pet for the target user, and does not perform any other processing on the user characteristics.

[0038] Optionally, the aforementioned user characteristics may include the target user's social relationships, i.e., social relationships formed by social users with whom the target user has indirect or direct social connections. It should be noted that any social user is also a user registered on the front-end application maintained by the virtual pet generation device. Therefore, the virtual pet generation device can filter out registered users with social connections with the target user from all registered users to obtain the social users corresponding to the target user. For example, registered users with social connections with the target user, i.e., social users, can be selected based on whether there is communication between the registered users.

[0039] Optionally, the above user characteristics further include the target user's historical browsing behavior, which is the target user's historical browsing behavior on the front-end application.

[0040] 202: The virtual pet generating device determines a target pet type corresponding to the target user according to the user characteristics.

[0041] For example, based on the above social relationships, a social topology graph of the target user is constructed. Figure 4 As shown, a social topology graph is constructed with the target user and the social users with whom the target user has social relationships as nodes. The nodes in the social topology graph thus include the target user and the social users with whom the target user has direct or indirect social relationships. Next, the types of pets kept by each user in the social topology graph are obtained. Each user's pet can be a virtual pet or a physical pet. Finally, the types of pets kept by each user are merged to obtain multiple candidate pet types, i.e., the types of all pets kept by the users in the social topology graph. The candidate pet types include, but are not limited to, Garfield cats, American shorthairs, British shorthairs, Shiba Inus, Huskies, and other pet types.

[0042] Furthermore, a sub-social topology graph corresponding to each candidate pet type is obtained from the social topology graph, wherein the users in the social topology graph include the target user and the social users who raise each candidate pet type in the social topology graph. For example, Figure 4 As shown, the social topology graph determines the social users who keep each candidate pet type, and then extracts the social users who keep the candidate pet type and the target user from the social topology graph to obtain a sub-social topology graph corresponding to each candidate pet type. When extracting the sub-social topology graph, the social relationships between users are not changed (i.e., the edge connections are not changed); the relevant users are simply extracted from the social topology graph.

[0043] Furthermore, the user's interest in each candidate pet category is determined based on the sub-social topology graph corresponding to each candidate pet category. Finally, the candidate pet category with the highest interest among the multiple candidate pet categories is selected as the target pet category.

[0044] Exemplarily, the similarity between each social user and the target user in the sub-social topology graph is determined separately. For example, the registration information of each registered user when registering in the front-end application can be obtained, and the registration information of each registered user can be vectorized to obtain the feature vector of each registered user. Therefore, the similarity between the feature vector of each social user and the feature vector of the target user can be used as the similarity between each social user and the target user. Then, the distance between each social user in the sub-social topology graph and the target user is obtained, wherein the distance is the number of nodes between each social user in the sub-social topology graph and the target user in the sub-social topology graph. It should be noted that the separated nodes also include the nodes where each target user is located. As Figure 4 As shown, the distance between the target user and social user 3 in the first sub-social topology is 2. Finally, based on the distances and similarities corresponding to the social users in the sub-social topology, the influence of each social user in the sub-social topology on each candidate pet type is determined.

[0045] For example, the influence of each social user on each candidate pet type is expressed by formula (1):

[0046]

[0047] Among them, influence i is the influence of the i-th social user on each candidate pet type, distance i is the distance between the i-th social user and the target user, k i is the similarity between the i-th social user and the target user.

[0048] It should be noted that, as can be seen from formula (1), the above-mentioned influence refers to the degree of influence that each social user has on the target user's desire to raise the candidate pet type when raising the candidate pet type. The greater the social distance between the social user and the target user, the smaller the influence. Therefore, the influence determined by formula (1) is relatively accurate.

[0049] Finally, the influence of each social user in the sub-social topology graph on each candidate pet type is summed up to obtain the target user's interest level in each candidate pet type.

[0050] 203: The virtual pet generating device determines a plurality of target pet features corresponding to the target user according to the target pet type and the user features, wherein the plurality of target pet features are composed of features of various body parts of the virtual pet.

[0051] Exemplarily, multiple preset pet features are obtained for each body part of the target pet type. The preset pet features for each body part include hair color, size, shape, and so on. For example, for each pet, the pet features for each body part are pre-set based on the physical pet. For example, for the physical Garfield cat, the head colors include black, light yellow cream, white, and so on. Therefore, the multiple preset features for the head of a pet such as Garfield can be set as: black, light yellow cream, white, and so on. Finally, based on the target user's historical browsing behavior, the target user's preference for each preset pet feature for each body part is determined.

[0052] Exemplarily, the historical browsing behavior includes a target user's browsing history of pets (including physical pets or virtual pets) within a historical time period. The historical time period can be one month, one year, or other historical time period from the current moment. Based on the browsing history, the target user determines the pets browsed each time within the historical time period, as well as the pet features of the pets browsed each time by the target user. Statistics are then collected for each pet feature browsed within the historical time period to obtain all pet features browsed by the target user within the historical time period, as well as the number of views of each pet feature. For example, if the target user browses Garfield for the first time and the head color of the cat is black, and browses Garfield for the second time and the head color of the cat is also black, then the browsed pet feature is determined to be black, and the number of views is 2. The ratio of the number of views of each pet feature to the total number of pets browsed by the target user is used as the target user's liking for the pet feature. The target user's liking for the pet feature they browsed is then used as the liking for the preset pet feature corresponding to the pet feature, thereby obtaining the target user's liking for each preset pet feature of each body part. It should be noted that if the pet features browsed by the target user do not include a preset pet feature, the likeability of the preset pet feature will be set to 0.

[0053] Furthermore, based on the preference for each preset pet feature for each body part, the top k preset pet features are selected from the multiple preset pet features corresponding to each body part as the k candidate pet features corresponding to each body part, where k is an integer greater than 1. A candidate pet feature is selected from each of the k candidate pet features for each body part and combined to obtain multiple pet feature combinations. That is, a candidate pet feature is selected from each of the k candidate pet features for each body part and combined to obtain multiple pet feature combinations. For example, if the target pet type has two body parts, the number of pet feature combinations obtained is (k*k) / 2.

[0054] Furthermore, the matching degree between the multiple candidate pet features in each pet feature combination is determined, wherein the matching degree of each pet feature combination is used to characterize the naturalness of the multiple candidate pet features in each pet feature combination after forming a pet.

[0055] Exemplarily, multiple candidate pet features in each pet feature combination are vectorized to obtain a feature vector corresponding to each candidate pet feature; multiple feature vectors of multiple candidate pet features in each pet feature combination are spliced ​​in a splicing order corresponding to the target pet type to obtain a target feature vector corresponding to each pet feature combination; the similarity between the target feature vector corresponding to each pet feature combination and multiple preset feature vectors corresponding to the target pet type is determined respectively to obtain multiple similarities, and the multiple similarities correspond one-to-one to the multiple preset feature vectors; wherein each preset feature vector is a pet feature of a body part of an entity pet under the target pet type, and the vectorized feature vectors of the pet feature of the body part of the entity pet are spliced ​​in the splicing order; the maximum similarity among the multiple similarities is used as the matching degree between the multiple candidate pet features in each pet feature combination.

[0056] Furthermore, the target user's preference for each pet feature combination is determined based on the matching degree of each pet feature combination and the target user's preference for each candidate pet feature in each pet feature combination. Exemplarily, the target user's preference for each candidate pet feature in each pet feature combination is summed to obtain a summed result corresponding to each pet feature combination; the product of the summed result and the matching degree of each pet feature combination is then used as the target user's preference for each pet feature combination. Finally, the pet feature combination with the highest preference among the multiple pet feature combinations is used as the target pet combination feature, and the multiple candidate pet features in the target pet combination feature are used as the multiple target pet features corresponding to the target user.

[0057] 204: The virtual pet generating device determines a plurality of target maps corresponding to the target user by combining the plurality of target pet features with the plurality of target maps. Figure 1 One-to-one, each target map is used to generate target pet features corresponding to each target map.

[0058] Exemplarily, each target pet feature is matched with a plurality of base maps corresponding to the target pet type to obtain a plurality of first target pet features, wherein the plurality of first target pet features are target pet features for which a matching base map exists among the plurality of target pet features. It should be noted that each base map is only used to generate pet features of one body part. Figure 5 As shown, each target pet feature is compared with each basic texture in the basic texture library. If it is determined that the pet feature generated by a certain basic texture is the target pet feature, the target pet feature is used as the first target pet feature, and then multiple first target pet features are obtained, and the target pet features other than the first target pet feature in the multiple target pet features are used as multiple second pet features.

[0059] Then, a plurality of base textures corresponding to each of the plurality of second target pet features are obtained from the plurality of base textures, wherein the plurality of base textures are superimposed to generate the second target pet feature. It should be noted that when there is no base texture for generating the target pet feature in the base texture library, a plurality of base textures required for generating the target pet can be obtained, and the target pet feature can be generated by superimposing the plurality of base textures. For example, Figure 6 As shown, when the target pet feature is yellow, and the base texture for generating yellow is not set in the texture library, the base texture for generating yellow can be generated by combining the base texture for generating red and the base texture for generating green, combining the color mixing principle, and thus obtaining the base texture corresponding to the target pet feature. Therefore, the multiple base textures corresponding to each second target pet feature are superimposed to obtain the base texture corresponding to each second target pet feature, wherein the multiple second target pet features are all target pet features in the multiple target pet features except the multiple first target pet features; the base texture corresponding to each first target pet feature and the base texture corresponding to each second target pet feature are used as the multiple target textures corresponding to the target user.

[0060] 205: The virtual pet generating device generates the virtual pet according to the multiple target maps.

[0061] Exemplarily, the multiple target maps are superimposed to generate the virtual pet.

[0062] As can be seen, in the embodiment of the present application, when a user has a need to generate a virtual pet, they can submit a virtual pet generation request through the user terminal, that is, requesting to generate a virtual pet with one click. Then, the virtual pet generation device can obtain the user's user characteristics and determine the pet type that is compatible with the user (i.e., the target pet type) based on the user characteristics; then, based on the target pet type and the user characteristics, determine the user's favorite pet characteristics, i.e., the target pet characteristics; finally, based on the target pet characteristics, a virtual pet that is compatible with the user is generated based on the target map corresponding to the target pet characteristics. Therefore, in the embodiment of the present application, the user only needs to submit a virtual pet request to generate a virtual pet that is compatible with the user, without the user having to make it independently. This simplifies the virtual pet generation process, realizes intelligent virtual pet generation, and improves the user experience.

[0063] In one embodiment of the present application, the pet accessories browsed by the target user in the historical time period are obtained, and the number of views of each accessory is counted, and multiple accessories are screened out based on the order of the number of views from high to low; then, corresponding virtual accessories are added to the virtual pet respectively.

[0064] It can be seen that in this embodiment, the user's browsing behavior can be combined to add the user's favorite virtual accessories to the virtual pet, thereby further improving the user experience.

[0065] In one embodiment of the present application, voice parameters corresponding to the virtual pet may be determined based on the registration information of the target user; when it is detected that the virtual pet is having a conversation with the target user, the virtual pet is controlled to have a conversation with the target user based on the voice parameters.

[0066] For example, the speech parameters of the present application include but are not limited to: intonation, speaking speed, timbre and intensity.

[0067] Exemplarily, based on the user characteristics of the target user, multiple reference users that match the target user are obtained. Optionally, the user characteristics are the registration information of the target user, wherein the registration information includes registration information under multiple preset dimensions, wherein the multiple preset dimensions can be age, gender, work content, etc. Therefore, the registration information of the target user under the i-th preset dimension and the registration information of any other registered user under the i-th preset dimension are obtained, wherein the i-th preset dimension is any one of the multiple preset dimensions. Then, it is determined whether the registration information of the target user under the i-th preset dimension and the registration information of the other registered users under the i-th preset dimension are the same. If they are the same, the i-th preset dimension is used as the target preset dimension of the other registered users; further, the number of target preset dimensions of the other registered users is obtained. If the number of target preset dimensions of the other registered users is greater than a threshold, the other registered users are used as reference users that match the target user, and multiple reference users are obtained.

[0068] Furthermore, at least one sentence spoken by each reference user's virtual pet when interacting with each reference user is obtained.

[0069] It should be noted that for each registered user, when the virtual pet is generated, the virtual pet's voice parameters are preset, i.e., the system's default voice parameters. However, these voice parameters are editable. Therefore, after each registered user's virtual pet is generated, the time when each registered user first edits the virtual pet's voice parameters is obtained. Then, the conversations between each registered user's virtual pet and each registered user from that editing time to the current time are cached, obtaining at least one utterance from each registered user's virtual pet's interaction with each registered user. Therefore, after determining the reference users, at least one utterance from each reference user's virtual pet's interaction with each reference user is retrieved from the cache.

[0070] Furthermore, feature extraction is performed on each of at least one utterance of each reference user's virtual pet to obtain a voiceprint feature vector for each utterance. For example, feature extraction can be performed on each utterance using a pre-trained audio encoder to obtain a voiceprint feature vector for each utterance. The voiceprint feature vectors for each utterance of each reference user's virtual pet are then averaged to obtain a voiceprint feature vector corresponding to each reference user.

[0071] Furthermore, a target voiceprint feature vector for the target user is determined based on the voiceprint feature vectors of each reference user. Exemplarily, the voiceprint feature vectors of each reference user can be averaged to obtain the target voiceprint feature vector for the target user. Finally, speech parameters are determined based on the target voiceprint feature vector. Exemplarily, the target feature vector can be decoded using an audio decoder to obtain the speech parameters. For example, the audio decoder can be a multi-task model that decodes the target voiceprint feature vector to obtain the speech parameters, namely, the virtual pet's intonation, timbre, speech rate, and intensity.

[0072] See Figure 7 , Figure 7 The embodiment of the present application provides a functional unit block diagram of a virtual pet generation device. The virtual pet generation device 700 includes: an acquisition unit 701 and a processing unit 702; wherein,

[0073] The acquisition unit 701 is configured to acquire user characteristics of a target user when a virtual pet generation request of the target user is obtained;

[0074] The processing unit 702 is configured to determine a target pet type corresponding to the target user based on the user characteristics;

[0075] Determining a plurality of target pet features corresponding to the target user according to the target pet type and the user features, wherein the plurality of target pet features are composed of features of various body parts of the virtual pet;

[0076] Obtain multiple target maps corresponding to the multiple target pet features, wherein the multiple target pet features and the multiple target maps Figure 1 One-to-one, each target map is used to generate a target pet feature;

[0077] The virtual pet is generated according to the multiple target maps.

[0078] In one embodiment of the present application, the user characteristics include the social relationships of the target user; in determining the target pet type corresponding to the user based on the user characteristics, the processing unit 702 is specifically configured to:

[0079] Constructing a social topology graph of the target user based on the social relationships, wherein the nodes in the social topology graph include the target user and social users who have social relationships with the target user in the social relationships;

[0080] Merging the types of pets raised by each user in the social topology graph to obtain multiple candidate pet types;

[0081] Obtaining a sub-social topology graph corresponding to each candidate pet type from the social topology graph, wherein the sub-social topology graph corresponding to each candidate pet type includes the target user and social users in the social topology graph who raise the candidate pet type;

[0082] Determining the target user's interest in each candidate pet category based on the sub-social topology graph corresponding to each candidate pet category;

[0083] The candidate pet category with the highest degree of interest among the plurality of candidate pet categories is used as the target pet category.

[0084] In one embodiment of the present application, in determining the target user's interest level in each candidate pet category based on the sub-social topology graph corresponding to each candidate pet category, the processing unit 702 is configured to:

[0085] Determine the similarity between each social user in the sub-social topology graph corresponding to each candidate pet type and the target user;

[0086] Obtaining the distance between each social user in the sub-social topology graph corresponding to each candidate pet type and the target user, wherein the distance is the number of nodes between each social user in the sub-social topology graph and the target user in the sub-social topology graph;

[0087] Determining the influence of each social user in the sub-social topology graph on each candidate pet type based on the distance and similarity of each social user in the sub-social topology graph corresponding to each candidate pet type;

[0088] The influence of each social user in the sub-social topology graph corresponding to each candidate pet category on each candidate pet category is summed up to obtain the target user's interest level in each candidate pet category.

[0089] In one embodiment of the present application, the user characteristics include the historical browsing behavior of the target user; in determining a plurality of target pet characteristics corresponding to the target user based on the target pet type and the user characteristics, the processing unit 702 is specifically configured to:

[0090] Acquire a plurality of preset pet features corresponding to various body parts included in the target pet type;

[0091] determining, based on the historical browsing behavior, the target user's preference for each of the plurality of preset pet features corresponding to the respective body parts;

[0092] According to the preference for each preset pet feature of each body part, the top k preset pet features are selected from the multiple preset pet features corresponding to each body part as the k candidate pet features corresponding to each body part, where k is an integer greater than 1;

[0093] Select one candidate pet feature from the k candidate pet features of each body part and combine them to obtain multiple pet feature combinations;

[0094] Determining the matching degree between the multiple candidate pet features in each pet feature combination, wherein the matching degree of each pet feature combination is used to characterize the naturalness of a pet formed by the multiple candidate pet features in each pet feature combination;

[0095] Determining the target user's preference for each pet feature combination based on the matching degree of each pet feature combination and the target user's preference for each candidate pet feature in each pet feature combination;

[0096] The pet feature combination with the highest degree of liking among the multiple pet feature combinations is used as the target pet combination feature, and the multiple candidate pet features in the target pet combination feature are used as the multiple target pet features corresponding to the target user.

[0097] In one embodiment of the present application, in determining the matching degree between multiple candidate pet features in each pet feature combination, the processing unit 702 is specifically configured to:

[0098] Vectorizing multiple candidate pet features in each pet feature combination to obtain a feature vector corresponding to each candidate pet feature in each pet feature combination;

[0099] Get the splicing order corresponding to the target pet type,

[0100] splicing the multiple feature vectors corresponding to the multiple candidate pet features in each pet feature combination according to the splicing order to obtain a target feature vector corresponding to each pet feature combination;

[0101] Determine the similarity between the target feature vector corresponding to each pet feature combination and a plurality of preset feature vectors corresponding to the target pet type, and obtain a plurality of similarities, wherein the plurality of similarities correspond one-to-one to the plurality of preset feature vectors; each preset feature vector is obtained by vectorizing the pet features of a body part of a physical pet of the target pet type, and splicing the vectorized feature vectors of the pet features of the body part of the physical pet according to the splicing order;

[0102] The greatest similarity among the multiple similarities is used as the matching degree between the multiple candidate pet features in each pet feature combination.

[0103] In one embodiment of the present application, in determining the target user's liking for each pet feature combination based on the matching degree of each pet feature combination and the target user's liking for each candidate pet feature in each pet feature combination, the processing unit 702 is specifically configured to:

[0104] Summing up the target user's preference for each candidate pet feature in each pet feature combination to obtain a target preference for each pet feature combination;

[0105] The product of the matching degree of each pet feature combination and the target preference of the target user for each pet feature combination is used as the preference of the target user for each pet feature combination.

[0106] In one embodiment of the present application, in terms of obtaining multiple target maps corresponding to the multiple target pet features, the processing unit 702 is specifically configured to:

[0107] Matching each target pet feature with a plurality of base maps corresponding to the target pet type to obtain a plurality of first target pet features, wherein the plurality of first target pet features are target pet features for which a matching base map exists among the plurality of target pet features;

[0108] Acquire a plurality of base maps corresponding to each second target pet feature in the plurality of second target pet features from the plurality of base maps, and superimpose the plurality of base maps corresponding to each second target pet feature to obtain a base map corresponding to each second target pet feature, wherein the plurality of second target pet features are all target pet features in the plurality of target pet features except the plurality of first target pet features;

[0109] The basic map corresponding to each target first pet feature and the basic map corresponding to each second target pet feature are used as multiple target maps corresponding to the target user.

[0110] See Figure 8 , Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. Figure 8 As shown, electronic device 800 includes a transceiver 801, a processor 802, and a memory 803. These are connected via a bus 804. The memory 803 is used to store computer programs and data, and can transmit the data stored in the memory 803 to the processor 802.

[0111] The processor 802 is configured to read the computer program in the memory 803 and perform the following operations:

[0112] When a virtual pet generation request of a target user is obtained, user characteristics of the target user are obtained;

[0113] Determining a target pet type corresponding to the target user based on the user characteristics;

[0114] Determining a plurality of target pet features corresponding to the target user according to the target pet type and the user features, wherein the plurality of target pet features are composed of features of various body parts of the virtual pet;

[0115] Obtain multiple target maps corresponding to the multiple target pet features, wherein the multiple target pet features and the multiple target maps Figure 1 One-to-one, each target map is used to generate a target pet feature;

[0116] The virtual pet is generated according to the multiple target maps.

[0117] In one embodiment of the present application, the user characteristics include the social relationships of the target user; in determining the target pet type corresponding to the user based on the user characteristics, the processor 802 is specifically configured to perform the following operations:

[0118] Constructing a social topology graph of the target user based on the social relationships, wherein the nodes in the social topology graph include the target user and social users who have social relationships with the target user in the social relationships;

[0119] Merging the types of pets raised by each user in the social topology graph to obtain multiple candidate pet types;

[0120] Obtaining a sub-social topology graph corresponding to each candidate pet type from the social topology graph, wherein the sub-social topology graph corresponding to each candidate pet type includes the target user and social users in the social topology graph who raise the candidate pet type;

[0121] Determining the target user's interest in each candidate pet category based on the sub-social topology graph corresponding to each candidate pet category;

[0122] The candidate pet category with the highest degree of interest among the plurality of candidate pet categories is used as the target pet category.

[0123] In one embodiment of the present application, in determining the target user's interest level in each candidate pet category based on the sub-social topology graph corresponding to each candidate pet category, the processor 802 is specifically configured to perform the following operations:

[0124] Determine the similarity between each social user in the sub-social topology graph corresponding to each candidate pet type and the target user;

[0125] Obtaining the distance between each social user in the sub-social topology graph corresponding to each candidate pet type and the target user, wherein the distance is the number of nodes between each social user in the sub-social topology graph and the target user in the sub-social topology graph;

[0126] Determining the influence of each social user in the sub-social topology graph on each candidate pet type based on the distance and similarity of each social user in the sub-social topology graph corresponding to each candidate pet type;

[0127] The influence of each social user in the sub-social topology graph corresponding to each candidate pet category on each candidate pet category is summed up to obtain the target user's interest level in each candidate pet category.

[0128] In one embodiment of the present application, the user characteristics include the historical browsing behavior of the target user; in determining a plurality of target pet characteristics corresponding to the target user based on the target pet type and the user characteristics, the processor 802 is specifically configured to perform the following operations:

[0129] Acquire a plurality of preset pet features corresponding to various body parts included in the target pet type;

[0130] determining, based on the historical browsing behavior, the target user's preference for each of the plurality of preset pet features corresponding to the respective body parts;

[0131] According to the preference for each preset pet feature of each body part, the top k preset pet features are selected from the multiple preset pet features corresponding to each body part as the k candidate pet features corresponding to each body part, where k is an integer greater than 1;

[0132] Select one candidate pet feature from the k candidate pet features of each body part and combine them to obtain multiple pet feature combinations;

[0133] Determining the matching degree between the multiple candidate pet features in each pet feature combination, wherein the matching degree of each pet feature combination is used to characterize the naturalness of a pet formed by the multiple candidate pet features in each pet feature combination;

[0134] Determining the target user's preference for each pet feature combination based on the matching degree of each pet feature combination and the target user's preference for each candidate pet feature in each pet feature combination;

[0135] The pet feature combination with the highest degree of liking among the multiple pet feature combinations is used as the target pet combination feature, and the multiple candidate pet features in the target pet combination feature are used as the multiple target pet features corresponding to the target user.

[0136] In one embodiment of the present application, in determining the matching degree between multiple candidate pet features in each pet feature combination, the processor 802 is specifically configured to perform the following operations:

[0137] Vectorizing multiple candidate pet features in each pet feature combination to obtain a feature vector corresponding to each candidate pet feature in each pet feature combination;

[0138] Get the splicing order corresponding to the target pet type,

[0139] splicing the multiple feature vectors corresponding to the multiple candidate pet features in each pet feature combination according to the splicing order to obtain a target feature vector corresponding to each pet feature combination;

[0140] Determine the similarity between the target feature vector corresponding to each pet feature combination and a plurality of preset feature vectors corresponding to the target pet type, and obtain a plurality of similarities, wherein the plurality of similarities correspond one-to-one to the plurality of preset feature vectors; each preset feature vector is obtained by vectorizing the pet features of a body part of a physical pet of the target pet type, and splicing the vectorized feature vectors of the pet features of the body part of the physical pet according to the splicing order;

[0141] The greatest similarity among the multiple similarities is used as the matching degree between the multiple candidate pet features in each pet feature combination.

[0142] In one embodiment of the present application, in determining the target user's liking for each pet feature combination based on the matching degree of each pet feature combination and the target user's liking for each candidate pet feature in each pet feature combination, the processor 802 is specifically configured to perform the following operations:

[0143] Summing up the target user's preference for each candidate pet feature in each pet feature combination to obtain a target preference for each pet feature combination;

[0144] The product of the matching degree of each pet feature combination and the target preference of the target user for each pet feature combination is used as the preference of the target user for each pet feature combination.

[0145] In one embodiment of the present application, in terms of obtaining multiple target maps corresponding to the multiple target pet features, the processor 802 is specifically configured to perform the following operations:

[0146] Matching each target pet feature with a plurality of base maps corresponding to the target pet type to obtain a plurality of first target pet features, wherein the plurality of first target pet features are target pet features for which a matching base map exists among the plurality of target pet features;

[0147] Acquire a plurality of base maps corresponding to each second target pet feature in the plurality of second target pet features from the plurality of base maps, and superimpose the plurality of base maps corresponding to each second target pet feature to obtain a base map corresponding to each second target pet feature, wherein the plurality of second target pet features are all target pet features in the plurality of target pet features except the plurality of first target pet features;

[0148] The basic map corresponding to each target first pet feature and the basic map corresponding to each second target pet feature are used as multiple target maps corresponding to the target user.

[0149] It should be understood that the electronic devices in this application may include smartphones (such as Android phones, iOS phones, Windows Phone phones, etc.), tablet computers, PDAs, laptops, mobile Internet devices (MIDs) or wearable devices. The above electronic devices are only examples and are not exhaustive, including but not limited to the above electronic devices. In actual applications, the above electronic devices may also include: smart car terminals, computer equipment, etc.

[0150] An embodiment of the present application further provides a computer-readable storage medium storing a computer program, which is executed by a processor to implement part or all of the steps of any one of the virtual pet generation methods described in the above method embodiments.

[0151] An embodiment of the present application further provides a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to cause a computer to execute some or all of the steps of any virtual pet generation method described in the above method embodiments.

[0152] It should be noted that for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that this application is not limited by the order of the actions described, because according to this application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in this specification are all optional embodiments, and the actions and modules involved are not necessarily required by this application.

[0153] In the above embodiments, the description of each embodiment has its own focus. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0154] In the several embodiments provided in this application, it should be understood that the disclosed devices can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, and the indirect coupling or communication connection of devices or units can be electrical or other forms.

[0155] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0156] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or in the form of software program modules.

[0157] If the integrated unit is implemented in the form of a software program module and sold or used as an independent product, it can be stored in a computer-readable memory. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a memory and includes a number of instructions for enabling a computer device (which can be a personal computer, a server or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned memory includes various media that can store program codes, such as a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk.

[0158] Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments can be completed by instructing related hardware through a program. The program can be stored in a computer-readable memory, and the memory can include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0159] The above is a detailed introduction to the embodiments of the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method and core idea of ​​the present application. At the same time, for those skilled in the art, according to the idea of ​​the present application, there may be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.

Claims

1. A method for generating a virtual pet, characterized in that: include: When a virtual pet generation request of a target user is obtained, user characteristics of the target user are obtained; Determining a target pet type corresponding to the target user based on the user characteristics, wherein the user characteristics include the social relationship of the target user; including: Based on the social relationships, a social topology graph of the target user is constructed; the types of pets raised by each user in the social topology graph are merged to obtain a plurality of candidate pet types; a sub-social topology graph corresponding to each candidate pet type is obtained from the social topology graph, wherein the sub-social topology graph corresponding to each candidate pet type includes the target user and the social users in the social topology graph who raise the candidate pet type; Based on the feature vectors of each social user in the sub-social topology graph corresponding to each candidate pet category and the feature vector of the target user, the similarity between each social user and the target user is determined; the distance between each social user and the target user is obtained, wherein the distance is the number of nodes between each social user and the target user in the sub-social topology graph; based on the distance and similarity corresponding to each social user, the influence of each social user on each candidate pet category is determined; wherein the influence of each social user on each candidate pet category is expressed by the following formula: ; is the influence of the i-th social user on each candidate pet type, and are the distance and similarity between the i-th social user and the target user respectively; Summing up the influence of each social user on each candidate pet category to obtain the target user's interest in each candidate pet category; and taking the candidate pet category with the greatest interest among the multiple candidate pet categories as the target pet category; Determining a plurality of target pet features corresponding to the target user according to the target pet type and the user features, wherein the plurality of target pet features are composed of features of various body parts of the virtual pet; Acquire a plurality of target maps corresponding to the plurality of target pet features, wherein the plurality of target pet features correspond one-to-one to the plurality of target maps, and each target map is used to generate a target pet feature; The virtual pet is generated according to the multiple target maps.

2. The method according to claim 1, characterized in that The user characteristics include the historical browsing behavior of the target user; the multiple target pet characteristics corresponding to the target user are determined based on the target pet type and the user characteristics, including: Acquire a plurality of preset pet features corresponding to various body parts included in the target pet type; determining, based on the historical browsing behavior, the target user's preference for each of the plurality of preset pet features corresponding to the respective body parts; According to the preference for each preset pet feature of each body part, the top k preset pet features are selected from the multiple preset pet features corresponding to each body part as the k candidate pet features corresponding to each body part, where k is an integer greater than 1; Select one candidate pet feature from the k candidate pet features of each body part and combine them to obtain multiple pet feature combinations; Determining the matching degree between the multiple candidate pet features in each pet feature combination, wherein the matching degree of each pet feature combination is used to characterize the naturalness of a pet formed by the multiple candidate pet features in each pet feature combination; Determining the target user's preference for each pet feature combination based on the matching degree of each pet feature combination and the target user's preference for each candidate pet feature in each pet feature combination; The pet feature combination with the highest degree of liking among the multiple pet feature combinations is used as the target pet combination feature, and the multiple candidate pet features in the target pet combination feature are used as the multiple target pet features corresponding to the target user.

3. The method according to claim 2, characterized in that Determining the matching degree between the multiple candidate pet features in each pet feature combination includes: Vectorizing multiple candidate pet features in each pet feature combination to obtain a feature vector corresponding to each candidate pet feature in each pet feature combination; Get the splicing order corresponding to the target pet type, splicing the multiple feature vectors corresponding to the multiple candidate pet features in each pet feature combination according to the splicing order to obtain a target feature vector corresponding to each pet feature combination; Determine the similarity between the target feature vector corresponding to each pet feature combination and a plurality of preset feature vectors corresponding to the target pet type, and obtain a plurality of similarities, wherein the plurality of similarities correspond one-to-one to the plurality of preset feature vectors; each preset feature vector is obtained by vectorizing the pet features of a body part of a physical pet of the target pet type, and splicing the vectorized feature vectors of the pet features of the body part of the physical pet according to the splicing order; The greatest similarity among the multiple similarities is used as the matching degree between the multiple candidate pet features in each pet feature combination.

4. The method according to claim 2 or 3, characterized in that The determining, based on the matching degree of each pet feature combination and the target user's preference for each candidate pet feature in each pet feature combination, the preference of the target user for each pet feature combination includes: Summing up the target user's preference for each candidate pet feature in each pet feature combination to obtain a target preference for each pet feature combination; The product of the matching degree of each pet feature combination and the target preference of the target user for each pet feature combination is used as the preference of the target user for each pet feature combination.

5. The method according to claim 4, characterized in that The step of obtaining a plurality of target maps corresponding to the plurality of target pet features includes: Matching each target pet feature with a plurality of base maps corresponding to the target pet type to obtain a plurality of first target pet features, wherein the plurality of first target pet features are target pet features for which a matching base map exists among the plurality of target pet features; Acquire a plurality of base maps corresponding to each second target pet feature in the plurality of second target pet features from the plurality of base maps, and superimpose the plurality of base maps corresponding to each second target pet feature to obtain a base map corresponding to each second target pet feature, wherein the plurality of second target pet features are all target pet features in the plurality of target pet features except the plurality of first target pet features; The basic map corresponding to each target first pet feature and the basic map corresponding to each second target pet feature are used as multiple target maps corresponding to the target user.

6. A virtual pet generating device, characterized in that: include: Acquisition unit and processing unit; The acquiring unit is configured to acquire user characteristics of the target user when acquiring a virtual pet generation request from the target user; The processing unit is configured to determine a target pet type corresponding to the target user based on the user characteristics, wherein the user characteristics include the social relationship of the target user; comprising: Based on the social relationships, a social topology graph of the target user is constructed; the types of pets raised by each user in the social topology graph are merged to obtain a plurality of candidate pet types; a sub-social topology graph corresponding to each candidate pet type is obtained from the social topology graph, wherein the sub-social topology graph corresponding to each candidate pet type includes the target user and the social users in the social topology graph who raise the candidate pet type; Based on the feature vectors of each social user in the sub-social topology graph corresponding to each candidate pet category and the feature vector of the target user, the similarity between each social user and the target user is determined; the distance between each social user and the target user is obtained, wherein the distance is the number of nodes between each social user and the target user in the sub-social topology graph; based on the distance and similarity corresponding to each social user, the influence of each social user on each candidate pet category is determined; wherein the influence of each social user on each candidate pet category is expressed by the following formula: ; is the influence of the i-th social user on each candidate pet type, and are the distance and similarity between the i-th social user and the target user respectively; Summing up the influence of each social user on each candidate pet category to obtain the target user's interest in each candidate pet category; and taking the candidate pet category with the greatest interest among the multiple candidate pet categories as the target pet category; Based on the target pet type and the user characteristics, a plurality of target pet characteristics corresponding to the target user are determined, wherein the plurality of target pet characteristics are composed of characteristics of various body parts of the virtual pet; a plurality of target maps corresponding to the plurality of target pet characteristics are obtained, wherein the plurality of target pet characteristics and the plurality of target maps have a one-to-one correspondence, and each target map is used to generate a target pet characteristic; and the virtual pet is generated based on the plurality of target maps.

7. An electronic device, characterized in that: include: A processor and a memory, the processor is connected to the memory, the memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory, so that the electronic device performs the method according to any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and the computer program is executed by a processor to implement the method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Method and device for generating 3D image of pet

    CN112785681A

  • Emotion recording method and device, electronic equipment and computer readable storage medium

    CN113989879A