Virtual scene generation method and device and electronic equipment
By partitioning and using the target big model to fill instance objects, the resource waste problem caused by the construction of virtual scenes in the prior art is solved, and more efficient virtual scene generation and resource utilization are achieved.
Patent Information
- Application Number
- CN202411864552.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-17
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2044-12-17
AI Technical Summary
The prior art relies on manual fine modeling when building virtual scenes, resulting in waste of resources and poor performance of virtual scenes in reusability and scalability.
By obtaining the scene generation request, partition the original virtual scene as the basic virtual scene, use the target big model to fill the instance object in the functional area, and generate the target virtual scene.
It reduces the waste of human resources and costs, improves the reusability and scalability of virtual scenes, and promotes the effective utilization of scene resources.
Smart Images

Figure CN119810380A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, and in particular to application fields such as machine learning, large language models, metaverse, digital world, game development, smart cities, outdoor scene design, traffic design and planning, traffic management and simulation, and architectural design, and specifically to a virtual scene generation method, device, and electronic equipment. Background Art
[0002] A virtual scene is a simulated environment built using computer technology and digital simulation technology, allowing users to immerse themselves in it and interact and experience it. Summary of the invention
[0003] The present disclosure provides a virtual scene generation method, device and electronic device.
[0004] According to a first aspect of the present disclosure, a virtual scene generation method is provided, comprising:
[0005] Get the scene generation request;
[0006] In response to the scene generation request, partition the original virtual scene to obtain a basic virtual scene; wherein the basic virtual scene includes a plurality of functional areas;
[0007] Taking each of the multiple functional areas as a target area, and using a target macro model to fill multiple target instance objects in the target area, so as to obtain a scene area corresponding to the target area;
[0008] Based on the scene area, a target virtual scene is generated.
[0009] According to a second aspect of the present disclosure, there is provided a virtual scene generating device, comprising:
[0010] A request acquisition unit, used to acquire a scene generation request;
[0011] A scene partitioning unit, used to partition the original virtual scene in response to a scene generation request to obtain a basic virtual scene; wherein the basic virtual scene includes a plurality of functional areas;
[0012] An object filling unit, used to take each of the multiple functional areas as a target area, and fill the target area with multiple target instance objects using a target macro model to obtain a scene area corresponding to the target area;
[0013] The scene generation unit is used to generate a target virtual scene based on the scene area.
[0014] According to a third aspect of the present disclosure, there is provided an electronic device, including:
[0015] at least one processor;
[0016] a memory communicatively coupled to the at least one processor;
[0017] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method provided in the first aspect of the present disclosure.
[0018] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the method provided according to the first aspect of the present disclosure.
[0019] According to a fifth aspect of the present disclosure, a computer program product is provided, comprising a computer program, which implements the method provided according to the first aspect of the present disclosure when executed by a processor.
[0020] The use of the present disclosure can reduce the waste of human resources and costs, and at the same time, enhance the performance of the target virtual scene in terms of reusability and scalability, which is conducive to the effective use of scene resources.
[0021] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] The accompanying drawings are used to better understand the present solution and do not constitute a limitation of the present disclosure.
[0023] Figure 1 A flowchart of a virtual scene generation method provided by an embodiment of the present disclosure;
[0024] Figure 2 A schematic diagram of a basic virtual scene acquisition process provided by an embodiment of the present disclosure;
[0025] Figure 3 A schematic diagram of a preliminary instance object selection process provided by an embodiment of the present disclosure;
[0026] Figure 4 A schematic diagram of the representation meaning of a parameter expression provided in an embodiment of the present disclosure;
[0027] Figure 5 A schematic diagram of a target virtual scene provided by an embodiment of the present disclosure;
[0028] Figure 6 An auxiliary illustration of the complete process of a virtual scene generation method provided by an embodiment of the present disclosure;
[0029] Figure 7 A schematic diagram of an application scenario of a virtual scene generation method provided by an embodiment of the present disclosure;
[0030] Figure 8 A schematic structural block diagram of a virtual scene generation device provided in an embodiment of the present disclosure;
[0031] Fig. 9 A schematic structural block diagram of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0032] The following is a description of exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope of the present disclosure. Similarly, for the sake of clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0033] As described in the background technology, a virtual scene is a simulation environment built using computer technology and digital simulation technology, allowing users to immerse themselves in it, interact and experience it. At present, the construction of virtual scenes mainly relies on manual fine modeling, which not only consumes a lot of human resources and costs, but also the created virtual scenes have poor reusability and scalability, which is not conducive to the effective use of scene resources.
[0034] In view of the above problems, the embodiments of the present disclosure provide a virtual scene generation method, which can be applied to electronic devices. The electronic device can be a server or a terminal device. Here, the terminal device can be a workbench, a mainframe computer, a conventional computer (for example, a desktop computer, a laptop computer, a car computer, etc.), a personal digital processing unit or other similar computing devices. Figure 1 The flowchart diagram shown illustrates a virtual scene generation method provided by an embodiment of the present disclosure. It should be noted that although the logical order is shown in the flowchart diagram, in some cases, the steps shown or described in the flowchart can also be performed in other orders.
[0035] Step S101, obtaining a scene generation request.
[0036] The scene generation request may include a target scene style, and based on the target scene style, the scene type and scene characteristics can be further determined. For example, there is a scene generation request "Generate a modern city scene", and the target scene style included in the scene generation request is "modern city", and based on the target scene style of "modern city", the scene type can be further determined to be "city" and the scene characteristics can be "modern".
[0037] In addition, in the embodiments of the present disclosure, the scene generation request can be sent by the developer through the terminal device and received by the electronic device. In one example, the developer can input the scene construction intention on the terminal device by text input or voice input, and generate the scene generation request based on the scene construction intention through the terminal device, and then send the scene generation request to the electronic device.
[0038] Step S102, in response to the scene generation request, partition the original virtual scene to obtain a basic virtual scene.
[0039] Among them, the original virtual scene can be a blank scene substrate, for example, a two-dimensional (2D) blank scene substrate; the basic virtual scene can include multiple functional areas, for example, residential areas, commercial areas, green areas, open areas, industrial areas, etc.
[0040] Step S103, taking each of the multiple functional areas as a target area, and using a target macro model to fill a plurality of target instance objects in the target area to obtain a scene area corresponding to the target area.
[0041] The target large model can be a large language model (LLM) or a trained LLM. Here, the LLM can be a pre-trained neural network model that has general language knowledge, world knowledge, expertise in various fields (e.g., expertise in the metaverse, architectural design, etc.), etc., and is stored in the model in the form of parameters. In one example, the LLM can be an autoregressive generative model of the Transformer architecture.
[0042] After taking each of the multiple functional areas as the target area, multiple target instance objects related to the target area can be filled in the target area based on the target macro model to obtain a scene area corresponding to the target area. For example, if the target area is a residential area, the multiple target instance objects related to it may include residential buildings, trees, leisure seats, convenience stores, medical stations, etc.; for another example, if the target area is a commercial area, the multiple target instance objects related to it may include shopping malls, parking lots, restaurants, banks, cinemas, etc.; for another example, if the target area is a green area, the multiple target instance objects related to it may include trees, grass, landscape platforms, pavilions, etc.
[0043] Step S104: Generate a target virtual scene based on the scene area.
[0044] After obtaining multiple scene areas corresponding to multiple functional areas, a target virtual scene can be generated based on the multiple scene areas. For example, a target virtual scene including multiple scene areas can be generated. The target virtual scene can be a three-dimensional (3D) virtual scene.
[0045] The virtual scene generation method provided by the embodiment of the present disclosure can partition the original virtual scene in response to the scene generation request after obtaining the scene generation request, obtain a basic virtual scene including multiple functional areas, and use each of the multiple functional areas as a target area, fill multiple target instance objects in the target area using the target large model to obtain a scene area corresponding to the target area, and then generate the target virtual scene based on the scene area. Compared with the virtual scene generation method in the prior art that relies on manual fine modeling, the embodiment of the present disclosure, on the one hand, can reduce the waste of human resources and costs by replacing manual operations with an automated process based on the target large model; on the other hand, through the regionalized design concept, the scene area can be reused and expanded as a later template, thereby enhancing the reusability and extensibility of the target virtual scene, which is conducive to the effective use of scene resources.
[0046] In some optional implementations, step S102, that is, "partitioning the original virtual scene to obtain a basic virtual scene in response to a scene generation request" may include:
[0047] Based on the scene generation request, determine the target scene style;
[0048] Get scene partition instructions;
[0049] The partition model is used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain the basic virtual scene.
[0050] Among them, the scene zoning indication can be obtained from the regional design guidance file. Here, the regional design guidance file can be a guidance document formulated and issued by design engineers in the fields of professional metaverse, architectural design, etc., to explain how to reasonably plan, layout and optimize the various functional areas in the virtual scene. For example, the first scene zoning indication can be obtained from the regional design guidance file: the straight-line distance between the residential area and the industrial area is greater than or equal to 20 kilometers (km); for another example, the second scene zoning indication can be obtained from the regional design guidance file: the straight-line distance between the residential area and the commercial area is less than or equal to 10Km; for another example, the third scene zoning indication can be obtained from the regional design guidance file: the straight-line distance between the residential area and the green area is less than 5km.
[0051] After determining the target scene style based on the scene generation request and obtaining the scene partition indication, the partition model can be used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain a basic virtual scene. Among them, the partition model can be an LLM or a trained LLM. In addition, as mentioned above, in the embodiment of the present disclosure, the basic virtual scene may include multiple functional areas. Specifically here, when the partition model is used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain the basic virtual scene, the object selection requirements of each functional area in the multiple functional areas can also be obtained. Among them, the object selection requirements may include the categories of preliminary instance objects that need to be filled, the number of preliminary instance objects of each category, and the specific filling position of each preliminary instance object, etc.
[0052] Please combine Figure 2 For example, after determining that the target scene style is "modern city" based on the scene generation request "Generate a modern city scene", the scene partition indication can be obtained, and the partition model can be used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain a basic virtual scene including 12 functional areas and object selection requirements for each of the 12 functional areas. Among them, the 12 functional areas include 4 residential areas, 2 commercial areas, 3 green areas, 2 open areas and 1 industrial area; the object selection requirements include the categories of the primary instance objects to be filled, the number of primary instance objects in each category, and the specific filling position of each primary instance object.
[0053] Assume that for the first residential area among the four residential areas, the corresponding object selection requirements include:
[0054] The object categories of the primary selected instances to be filled are: residential buildings, trees, leisure seats;
[0055] The number of the primary instance object of the residential building: 1; the number of the primary instance object of the tree: 2 (including the first tree and the second tree); the number of the instance object of the leisure seat: 1;
[0056] The specific filling position of this preliminary instance object of the residential building is: (X1, Y1); the specific filling position of this preliminary instance object of the first tree is (X2, Y2); the specific filling position of this preliminary instance object of the second tree is (X3, Y3); the specific filling position of this preliminary instance object of the leisure chair is (X4, Y4).
[0057] Through the above method, in the embodiment of the present disclosure, the target scene style can be determined based on the scene generation request, and the scene partition indication can be obtained, and then the partition model can be used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain the basic virtual scene. That is to say, in the embodiment of the present disclosure, on the one hand, the partition model is used to directly partition the original virtual scene to obtain the basic virtual scene, which can further reduce the waste of human resources and costs; on the other hand, when the partition model partitions the original virtual scene to obtain the basic virtual scene, it is necessary to use the target scene style and the scene partition indication as a partition reference instead of relying solely on the target scene style. Therefore, it can ensure that multiple functional areas in the basic virtual scene have reasonable planning and layout.
[0058] In addition, as mentioned above, in the embodiment of the present disclosure, the partition model can be a trained LLM. The following will briefly describe the process of training the first LLM to obtain the partition model:
[0059] Generate request samples based on the scene and determine the target scene style samples;
[0060] Get scene partition instructions;
[0061] Using the first LLM, based on the target scene style sample and the scene partition indication, the original virtual scene sample is partitioned to obtain a basic virtual scene sample;
[0062] The first LLM is trained using basic virtual scene samples.
[0063] The scene generation request sample and the scene generation request have the same data structure and representation meaning. For example, the scene generation request sample may include a target scene style sample, and based on the target scene style sample, a scene type sample and a scene feature sample may be further determined.
[0064] After generating a request sample based on the scene, determining the target scene style sample, and obtaining the scene partition indication, the first LLM can be used to partition the original virtual scene sample based on the target scene style sample and the scene partition indication to obtain a basic virtual scene sample. Among them, the basic virtual scene sample may include multiple functional area samples. Specifically here, when the original virtual scene sample is partitioned based on the target scene style sample and the scene partition indication using the first LLM to obtain the basic virtual scene sample, an object selection requirement sample for each functional area sample in the multiple functional area samples can also be obtained. Among them, the object selection requirement sample may include the category of the preliminary instance object sample to be filled, the number of preliminary instance object samples of each category, and the specific filling position of each preliminary instance object sample.
[0065] After obtaining the basic virtual scene samples and the object selection requirement samples, the scene loss between the basic virtual scene samples and the reference basic virtual scene, as well as the requirement loss between the object selection requirement samples and the reference object selection requirement can be calculated, and the first LLM can be trained based on the scene loss and the requirement loss. The reference basic virtual scene and the basic virtual scene samples have the same data structure and representation meaning; the reference object selection requirement and the object selection requirement samples have the same data structure and representation meaning, and the reference basic virtual scene and the reference object selection requirement can be obtained by manual annotation, which will not be elaborated here.
[0066] In addition, it should be noted that in the embodiment of the present disclosure, the above-described process of training the first LLM can be executed in a loop until the trained first LLM meets the first convergence condition, and the trained first LLM is used as the partition model. Among them, the first convergence condition can be that the scene loss meets the preset scene loss requirement, and the requirement loss meets the preset requirement loss requirement. Here, the preset scene loss requirement and the preset requirement loss requirement can be determined based on the actual application scenario, and the embodiment of the present disclosure will not elaborate on this.
[0067] In some optional implementations, the target macromodel includes a first target macromodel and a second target macromodel. Based on this, the step S103 of "using the target macromodel to fill a plurality of target instance objects in the target area to obtain a scene area corresponding to the target area" may include:
[0068] Using the first target large model, a plurality of preliminary selected instance objects related to the target area are selected from the instance object library;
[0069] Using the second target large model, the multiple preliminary instance objects are adjusted to obtain multiple target instance objects corresponding to the multiple preliminary instance objects one by one;
[0070] Fill the target area with multiple target instance objects to obtain a scene area corresponding to the target area.
[0071] Among them, the first target large model can be an LLM or a trained LLM; the second target large model can also be an LLM or a trained LLM.
[0072] In one example, “using the first target macro model to select a plurality of preliminarily selected instance objects related to the target area from the instance object library” may include:
[0073] Obtaining object selection requirements related to the target area;
[0074] Generate an overall object style related to the target area based on the scene generation request using the first target large model;
[0075] Using the first target large model, based on the object selection requirements and the overall object style, multiple preliminary instance objects related to the target area are selected from the instance object library.
[0076] The overall object style may include the initial positioning attributes of each primary instance object to be filled in the target area. For example, for a primary instance object such as a residential building, its initial positioning attributes may include building shape, floor height, facade color, facade texture, door and window design style, etc.; for another example, for a primary instance object such as a tree, its initial positioning attributes may include tree species, tree height, tree inclination, leaf density, leaf color, etc.; for another example, for a primary instance object such as a leisure seat, its initial positioning attributes may include seat material, seat color, seat size, etc.
[0077] In addition, as mentioned above, in the embodiments of the present disclosure, the object selection requirements may include the categories of preliminary instance objects that need to be filled, the number of preliminary instance objects in each category, and the specific filling position of each preliminary instance object.
[0078] After obtaining the overall object style and object selection requirements related to the target area, the first target large model can be used to select multiple preliminary instance objects related to the target area from the instance object library based on the overall object style and object selection requirements. Among them, the instance object library can include a large number of candidate instance objects, and each candidate instance object in the large number of candidate instance objects has an attribute label. For example, for the candidate instance object of residential building A1, its attribute labels may include building shape labels, floor height labels, facade color labels, facade texture labels, door and window design style labels, etc.; for the candidate instance object of tree A2, its attribute labels may include tree variety labels, tree height labels, tree inclination labels, leaf density labels, leaf color labels, etc.; for the candidate instance object of leisure seat A3, its attribute labels may include seat material labels, seat color labels, seat size labels, etc.
[0079] Based on this, in a specific example, after obtaining the overall object style and object selection requirements related to the target area, the first target large model can be used to compare the overall object style and object selection requirements with the attribute labels of each candidate instance object in the instance object library for similarity, and select multiple preliminary instance objects related to the target area from the instance object library.
[0080] Please combine Figure 3 , exemplarily, the object selection requirements related to the target area include:
[0081] The object categories of the primary selected instances to be filled are: residential buildings, trees, leisure seats;
[0082] The number of the primary instance object of the residential building: 1; the number of the primary instance object of the tree: 2 (including the first tree and the second tree); the number of the instance object of the leisure seat: 1;
[0083] The specific filling position of this preliminary instance object of the residential building is: (X1, Y1); the specific filling position of this preliminary instance object of the first tree is (X2, Y2); the specific filling position of this preliminary instance object of the second tree is (X3, Y3); the specific filling position of this preliminary instance object of the leisure chair is (X4, Y4).
[0084] Assume that, using the first target large model, based on the scene generation request, the overall object style related to the target area generated includes:
[0085] The initial positioning attributes of the residential building as the primary instance object are: the building shape is a regular square (including square, rectangle, etc.), the floor height is low (for example, the floor height is 1 to 7 floors), the facade color is gray (including pure dark gray, pure light gray, gray with patterns, etc.), the facade texture is a raised pattern (including raised decorative patterns, raised mural patterns, etc.), and the door and window design style is retro style (for example, Chinese retro style, American retro style, etc.);
[0086] The initial positioning attributes of the first tree as the primary instance object are as follows: the tree species is pine (including black pine, Scots pine, Chinese pine, etc.), the tree height is very high (for example, 20 meters (M) to 30M), the tree inclination is no inclination, the leaf density is dense, and the leaf color is green (including dark green, dark green, light green, etc.);
[0087] The initial positioning attributes of the second tree as the primary instance object are as follows: the tree species is a ginkgo tree (including yellow-leaf ginkgo, tower-shaped ginkgo, split ginkgo, weeping ginkgo, variegated-leaf ginkgo, etc.), the tree height is short (for example, 5M to 10M), the tree inclination is no inclination, the leaf density is dense, and the leaf color is yellow (including dark yellow, light yellow, etc.);
[0088] …
[0089] Then, using the first target large model, based on the object selection requirements and the overall object style, multiple preliminary instance objects related to the target area selected from the instance object library may include residential building B1, tree B2 and tree B3.
[0090] In the above example, the object selection requirements related to the target area can be obtained, and the first target large model can be used to generate the overall object style related to the target area based on the scene generation request, and then the first target large model can be used to select multiple preliminary instance objects related to the target area from the instance object library based on the object selection requirements and the overall object style. In this process, the first target large model is responsible for generating the overall object style related to the target area based on the scene generation request, and selecting multiple preliminary instance objects from the instance object library based on the object selection requirements and the overall object style. Since the first target large model can be an LLM or a trained LLM, it can ensure the matching degree of multiple preliminary instance objects with the scene generation request.
[0091] In one example, “adjusting the plurality of preliminarily selected instance objects using the second target macro model to obtain a plurality of target instance objects corresponding one-to-one to the plurality of preliminarily selected instance objects” may include:
[0092] Each of the multiple initially selected instance objects is used as an object to be adjusted, and the overall object style is refined using the second target large model to obtain a specific object style related to the object to be adjusted;
[0093] Get object adjustment indication;
[0094] The second target large model is used to adjust the object to be adjusted based on the specific object style and the object adjustment instruction, so as to obtain a target instance object corresponding to the object to be adjusted.
[0095] Among them, the second target large model can be an LLM or a trained LLM; the specific object style can include the target positioning attributes of the object to be adjusted (here, the target positioning attributes are more specific and clear than the initial positioning attributes). For example, if the object to be adjusted is a residential building, its target positioning attributes may include the specific building shape, specific floor height, specific facade color, specific facade texture, specific door and window design style, etc.; for another example, if the object to be adjusted is a tree, its target positioning attributes may include the specific tree variety, specific tree height, specific tree inclination, specific leaf density, specific leaf color, etc.; for another example, if the object to be adjusted is a leisure seat, its target positioning attributes may include the specific seat material, specific seat color, specific seat size, etc.
[0096] In addition, in the disclosed embodiment, the object adjustment instruction may be obtained from the guiding object adjustment file. Among them, the guiding object adjustment file may be a guiding document formulated and issued by design engineers in the fields of professional metaverse, architectural design, etc., to explain how to make reasonable adjustments to the adjustment object. For example, the first object adjustment instruction can be obtained from the guiding object adjustment file: the facade color of the residential building cannot be pure dark gray; for another example, the second object adjustment instruction can be obtained from the guiding object adjustment file: the height of the tree cannot exceed 25M; for another example, the third object adjustment instruction can be obtained from the guiding object adjustment file: oleander shall not be planted in residential areas.
[0097] After using the second target macromodel to refine the overall object style, obtain the specific object style related to the object to be adjusted, and obtain the object adjustment instruction, the second target macromodel can be used to adjust the object to be adjusted based on the specific object style and the object adjustment instruction to obtain the target instance object corresponding to the object to be adjusted. In a specific example, "using the second target macromodel to adjust the object to be adjusted based on the specific object style and the object adjustment instruction to obtain the target instance object corresponding to the object to be adjusted" may include:
[0098] Obtaining a parameter expression of the object to be adjusted; wherein the parameter expression includes a plurality of initial parameters, and each of the plurality of initial parameters corresponds to an object attribute of the object to be adjusted;
[0099] Using the second target macromodel, based on the specific object style and the object adjustment indication, the multiple initial parameters are adjusted to obtain multiple target parameters corresponding to the multiple initial parameters one by one;
[0100] Based on multiple target parameters, the object to be adjusted is adjusted to obtain a target instance object corresponding to the object to be adjusted.
[0101] For example, if the object to be adjusted is a residential building, its multiple initial parameters may include the initial parameter corresponding to the object attribute of the specific building shape, the initial parameter corresponding to the object attribute of the specific floor height, the initial parameter corresponding to the object attribute of the specific facade color, the initial parameter corresponding to the object attribute of the specific facade texture, the initial parameter corresponding to the object attribute of the specific door and window design style, etc.; for another example, if the object to be adjusted is a tree, its multiple initial parameters may include the initial parameter corresponding to the object attribute of the specific tree variety, the initial parameter corresponding to the object attribute of the specific tree height, the initial parameter corresponding to the object attribute of the tree inclination, the initial parameter corresponding to the object attribute of the leaf density, the initial parameter corresponding to the object attribute of the leaf color, etc.; for another example, if the object to be adjusted is a leisure chair, its multiple initial parameters may include the initial parameter corresponding to the object attribute of the specific seat material, the initial parameter corresponding to the object attribute of the specific seat color, the initial parameter corresponding to the object attribute of the specific seat size, etc.
[0102] After obtaining the specific object style and object adjustment instructions, and acquiring the parameter expression of the object to be adjusted, the second target large model can be used to adjust multiple initial parameters based on the specific object style and object adjustment instructions, and obtain multiple target parameters corresponding to the multiple initial parameters one by one, and adjust the object to be adjusted based on the multiple target parameters to obtain a target instance object corresponding to the object to be adjusted.
[0103] Please combine Figure 4 , continuing with the aforementioned example, the multiple preliminary instance objects include a residential building B1 and a tree B2.
[0104] When the residential building B1 is taken as the object to be adjusted, the overall object style can be refined to obtain the specific object style related to the object to be adjusted, and the object adjustment indication can be obtained, and then the parameter expression of the object to be adjusted can be obtained (the parameter expression includes the initial parameters corresponding to the object attribute of the specific building shape, the initial parameters corresponding to the object attribute of the specific floor height, the initial parameters corresponding to the object attribute of the specific facade color, the initial parameters corresponding to the object attribute of the specific facade texture, the initial parameters corresponding to the object attribute of the specific door and window design style, etc.), and the second target large model is used to adjust the multiple initial parameters based on the specific object style and the object adjustment indication to obtain multiple target parameters corresponding to the multiple initial parameters one by one, so as to adjust the object to be adjusted based on the multiple target parameters to obtain the target instance object corresponding to the object to be adjusted.
[0105] When tree B2 is taken as the object to be adjusted, the overall object style can be refined to obtain the specific object style related to the object to be adjusted, and the object adjustment indication can be obtained, and then the parameter expression of the object to be adjusted can be obtained (the parameter expression includes initial parameters corresponding to the object attribute of the specific tree variety, the initial parameters corresponding to the object attribute of the specific tree height, the initial parameters corresponding to the object attribute of the tree inclination, the initial parameters corresponding to the object attribute of the leaf density, the initial parameters corresponding to the object attribute of the leaf color, etc.), and the second target large model is used to adjust the multiple initial parameters based on the specific object style and the object adjustment indication to obtain multiple target parameters corresponding to the multiple initial parameters one by one, so as to adjust the object to be adjusted based on the multiple target parameters to obtain the target instance object corresponding to the object to be adjusted.
[0106] In the above example, each of the multiple pre-selected instance objects can be used as an object to be adjusted, and the second target macro model can be used to refine the overall object style, obtain a specific object style related to the object to be adjusted, and obtain an object adjustment instruction, and then the second target macro model can be used to adjust the object to be adjusted based on the specific object style and the object adjustment instruction to obtain a target instance object corresponding to the object to be adjusted. In this way, the diversity and rationality of the target instance objects can be improved, thereby improving the visual effect of the target virtual scene.
[0107] In summary, through the above method, in the embodiment of the present disclosure, the first target large model can be used to select multiple preliminary instance objects related to the target area from the instance object library, and the second target large model can be used to adjust the multiple preliminary instance objects to obtain multiple target instance objects corresponding to the multiple preliminary instance objects, and then the multiple target instance objects are filled into the target area to obtain a scene area corresponding to the target area. That is to say, in the embodiment of the present disclosure, on the one hand, the first target large model can be used to select multiple preliminary instance objects related to the target area from the instance object library to improve the generation efficiency of the target virtual scene; on the other hand, after obtaining multiple initial instance objects, the second target large model can be used to adjust the multiple preliminary instance objects to obtain multiple target instance objects corresponding to the multiple preliminary instance objects to improve the diversity and rationality of the target instance objects, thereby improving the visual effect of the target virtual scene.
[0108] In addition, as mentioned above, in the embodiment of the present disclosure, the first target model can be a trained LLM. The following will briefly describe the process of training the second LLM to obtain the first target model:
[0109] Obtaining a sample of object selection requirements associated with a sample of a target area;
[0110] Generate an overall object style sample related to the target region sample based on the scene generation request sample using the second LLM;
[0111] Using the second LLM, based on the object selection requirement sample and the overall object style sample, a plurality of preliminary instance object samples are selected from the instance object library;
[0112] The second LLM is trained using a plurality of preliminary instance object samples.
[0113] Among them, the target area sample has the same data structure and representation meaning as the target area; the object selection requirement sample has the same data structure and representation meaning as the object selection requirement; the scene generation request sample has the same data structure and representation meaning as the scene generation request; the overall object style sample has the same data structure and representation meaning as the overall object style; the preliminary instance object sample has the same data structure and representation meaning as the preliminary instance object, and they are not elaborated here.
[0114] After obtaining multiple preliminary instance object samples, the first object loss between the multiple preliminary instance object samples and the multiple reference preliminary instance objects can be calculated, and the second LLM can be trained based on the first object loss. The reference preliminary instance objects and the preliminary instance object samples have the same data structure and representation meaning, and the reference preliminary instance objects can be obtained by manual annotation, which will not be described in detail here.
[0115] It should be noted that, in the embodiment of the present disclosure, the above-described process of training the second LLM can be executed in a loop until the trained second LLM meets the second convergence condition, and the trained second LLM is used as the first target large model. The second convergence condition can be that the first object loss meets the first object loss requirement. Here, the first object loss requirement can be determined based on the actual application scenario, and the embodiment of the present disclosure will not be elaborated on this.
[0116] Similarly, as mentioned above, in the embodiment of the present disclosure, the second target model can be a trained LLM. The following will briefly describe the process of training the third LLM to obtain the second target model:
[0117] Using the third LLM, the overall object style sample is refined to obtain a specific object style sample related to the object sample to be adjusted;
[0118] Get object adjustment indication;
[0119] Using the third LLM, based on the specific object style sample and the object adjustment indication, the object sample to be adjusted is adjusted to obtain a target instance object sample corresponding to the object sample to be adjusted;
[0120] The third LLM is trained using the target instance object samples.
[0121] Among them, the overall object style sample has the same data structure and representation meaning as the overall object style; the to-be-adjusted object sample has the same data structure and representation meaning as the to-be-adjusted object; the specific object style sample has the same data structure and representation meaning as the specific object style; the target instance object sample has the same data structure and representation meaning as the target instance object, which will not be elaborated here.
[0122] After selecting the target instance object sample, the second object loss between the target instance object sample and the reference target instance object can be calculated, and the third LLM can be trained based on the second object loss. The reference target instance object has the same data structure and representation meaning as the target instance object sample, and the reference target instance object can be obtained by manual annotation, which will not be described in detail here.
[0123] It should be noted that, in the embodiment of the present disclosure, the process of training the third LLM described above can be executed in a loop until the trained third LLM meets the third convergence condition, and the trained third LLM is used as the second target large model. Among them, the third convergence condition can be that the second object loss meets the second object loss requirement. Here, the second object loss requirement can be determined based on the actual application scenario, and the embodiment of the present disclosure will not be elaborated on this.
[0124] In some optional implementations, step S104, i.e., “generating a target virtual scene based on the scene area” may:
[0125] Based on the scene area, construct an initial virtual scene;
[0126] When it is determined that the initial virtual scene meets the preset scene requirement, a target virtual scene is generated based on the initial virtual scene.
[0127] Among them, the preset scene requirements can be set according to actual application needs, and the embodiments of the present disclosure are not limited to this.
[0128] In one example, “determining that the initial virtual scene meets the preset scene requirements” may include:
[0129] Obtaining a single evaluation result for the initial virtual scene from each evaluation dimension of the multiple evaluation dimensions, so as to obtain a plurality of single evaluation results corresponding to the multiple evaluation dimensions one by one;
[0130] Based on multiple single evaluation results, the overall evaluation result of the initial virtual scene is obtained;
[0131] When the overall evaluation result meets the preset evaluation requirements, it is determined that the initial virtual scene meets the preset scene requirements.
[0132] The multiple evaluation dimensions may include at least one of the demand function evaluation dimension, the spatial relationship evaluation dimension, and the architectural style evaluation dimension. Correspondingly, the multiple single evaluation results may include a first single evaluation result corresponding to the demand function evaluation dimension, a second single evaluation result corresponding to the spatial relationship evaluation dimension, and a third single evaluation result corresponding to the architectural style evaluation dimension. Here, the first single evaluation result is used to characterize whether the initial virtual scene meets the scene generation request; the second single evaluation result is used to characterize whether the spatial relationship of the initial virtual scene is reasonable; and the third single evaluation result is used to characterize whether the architectural style of the initial virtual scene is harmonious.
[0133] After obtaining multiple single evaluation results, the overall evaluation result of the initial virtual scene can be obtained based on the multiple single evaluation results, and when the overall evaluation result meets the preset evaluation requirements, it is determined that the initial virtual scene meets the preset scene requirements. The preset evaluation requirements can be that the first single evaluation result represents that the initial virtual scene meets the scene generation request, the second single evaluation result represents that the spatial relationship of the initial virtual scene is reasonable, and the third single evaluation result represents that the architectural style of the initial virtual scene is harmonious.
[0134] In addition, it should be noted that, in the embodiment of the present disclosure, the LLM may also be used to determine whether the initial virtual scene meets the preset scene requirements.
[0135] In another example, “generating a target virtual scene based on the initial virtual scene” may include:
[0136] Obtain target atmosphere information;
[0137] Based on the target atmosphere information, the initial virtual scene is optimized to generate the target virtual scene.
[0138] The target atmosphere information includes at least one of 3D terrain information and weather information.
[0139] After obtaining the target atmosphere information, the parameter modification function corresponding to the target atmosphere information can be called to optimize the initial virtual scene, generate the target virtual scene, and send the target virtual scene to the terminal device for display. Figure 5 shown.
[0140] Through the above method, in the embodiment of the present disclosure, an initial virtual scene can be constructed based on the scene area, and when it is determined that the initial virtual scene meets the preset scene requirements, a target virtual scene is generated based on the initial virtual scene. Moreover, when it is determined that the initial virtual scene meets the preset scene requirements, it will be evaluated from multiple evaluation dimensions to ensure the reliability of the evaluation results; in addition, when generating the target virtual scene based on the initial virtual scene, the target atmosphere information can also be obtained, and based on the target atmosphere information, the initial virtual scene is optimized to generate the target virtual scene. In this way, not only the rationality of the target virtual scene can be ensured, but also the authenticity of the target virtual scene can be ensured, thereby further improving the visual effect of the target virtual scene.
[0141] The following, combined with Figure 6 , the complete process of the virtual scene generation method provided by the embodiment of the present disclosure is described.
[0142] (1) Obtaining a scene generation request
[0143] The scene generation request may include a target scene style, and based on the target scene style, the scene type and scene characteristics can be further determined. For example, there is a scene generation request "Generate a modern city scene", and the target scene style included in the scene generation request is "modern city", and based on the target scene style of "modern city", the scene type can be further determined to be "city" and the scene characteristics can be "modern".
[0144] In addition, in the embodiments of the present disclosure, the scene generation request can be sent by the developer through the terminal device and received by the electronic device. In one example, the developer can input the scene construction intention on the terminal device by text input or voice input, and generate the scene generation request based on the scene construction intention through the terminal device, and then send the scene generation request to the electronic device.
[0145] (2) Obtaining the basic virtual scene
[0146] In one example, in response to a scene generation request, the original virtual scene may be partitioned to obtain a basic virtual scene.
[0147] In a specific example, “partitioning the original virtual scene in response to a scene generation request to obtain a basic virtual scene” may include:
[0148] Based on the scene generation request, determine the target scene style;
[0149] Get scene partition instructions;
[0150] The partition model is used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain the basic virtual scene.
[0151] Among them, the scene zoning indication can be obtained from the regional design guidance file. Here, the regional design guidance file can be a guidance document formulated and issued by design engineers in the fields of professional metaverse, architectural design, etc., to explain how to reasonably plan, layout and optimize the various functional areas in the virtual scene. For example, the first scene zoning indication can be obtained from the regional design guidance file: the straight-line distance between the residential area and the industrial area is greater than or equal to 20km; for another example, the second scene zoning indication can be obtained from the regional design guidance file: the straight-line distance between the residential area and the commercial area is less than or equal to 10Km; for another example, the third scene zoning indication can be obtained from the regional design guidance file: the straight-line distance between the residential area and the green area is less than 5km.
[0152] After determining the target scene style based on the scene generation request and obtaining the scene partition indication, the partition model can be used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain a basic virtual scene. Among them, the partition model can be an LLM or a trained LLM. In addition, as mentioned above, in the embodiment of the present disclosure, the basic virtual scene may include multiple functional areas. Specifically here, when the partition model is used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain the basic virtual scene, the object selection requirements of each functional area in the multiple functional areas can also be obtained. Among them, the object selection requirements may include the categories of preliminary instance objects that need to be filled, the number of preliminary instance objects of each category, and the specific filling position of each preliminary instance object, etc.
[0153] (3) Select multiple primary instance objects
[0154] Specifically, each of the multiple functional areas can be used as a target area, and a plurality of preliminary instance objects related to the target area can be selected from the instance object library using the first target macro model.
[0155] In one example, “using the first target macro model to select a plurality of preliminarily selected instance objects related to the target area from the instance object library” may include:
[0156] Obtaining object selection requirements related to the target area;
[0157] Generate an overall object style related to the target area based on the scene generation request using the first target large model;
[0158] Using the first target large model, based on the object selection requirements and the overall object style, multiple preliminary instance objects related to the target area are selected from the instance object library.
[0159] The overall object style may include the initial positioning attributes of each primary instance object to be filled in the target area. For example, for a primary instance object such as a residential building, its initial positioning attributes may include building shape, floor height, facade color, facade texture, door and window design style, etc.; for another example, for a primary instance object such as a tree, its initial positioning attributes may include tree species, tree height, tree inclination, leaf density, leaf color, etc.; for another example, for a primary instance object such as a leisure seat, its initial positioning attributes may include seat material, seat color, seat size, etc.
[0160] In addition, as mentioned above, in the embodiments of the present disclosure, the object selection requirements may include the categories of preliminary instance objects that need to be filled, the number of preliminary instance objects in each category, and the specific filling position of each preliminary instance object.
[0161] After obtaining the overall object style and object selection requirements related to the target area, the first target large model can be used to select multiple preliminary instance objects related to the target area from the instance object library based on the overall object style and object selection requirements. Among them, the instance object library can include a large number of candidate instance objects, and each candidate instance object in the large number of candidate instance objects has an attribute label. For example, for the candidate instance object of residential building A1, its attribute labels may include building shape labels, floor height labels, facade color labels, facade texture labels, door and window design style labels, etc.; for the candidate instance object of tree A2, its attribute labels may include tree variety labels, tree height labels, tree inclination labels, leaf density labels, leaf color labels, etc.; for the candidate instance object of leisure seat A3, its attribute labels may include seat material labels, seat color labels, seat size labels, etc.
[0162] Based on this, in a specific example, after obtaining the overall object style and object selection requirements related to the target area, the first target large model can be used to compare the overall object style and object selection requirements with the attribute labels of each candidate instance object in the instance object library for similarity, so as to select multiple preliminary instance objects related to the target area from the instance object library.
[0163] (4) Adjusting multiple primary instance objects
[0164] Specifically, the second target macro model can be used to adjust the multiple preliminary instance objects to obtain multiple target instance objects that correspond one-to-one to the multiple preliminary instance objects.
[0165] In one example, “adjusting the plurality of preliminarily selected instance objects using the second target macro model to obtain a plurality of target instance objects corresponding one-to-one to the plurality of preliminarily selected instance objects” may include:
[0166] Each of the multiple initially selected instance objects is used as an object to be adjusted, and the overall object style is refined using the second target large model to obtain a specific object style related to the object to be adjusted;
[0167] Get object adjustment indication;
[0168] The second target large model is used to adjust the object to be adjusted based on the specific object style and the object adjustment instruction, so as to obtain a target instance object corresponding to the object to be adjusted.
[0169] Among them, the second target large model can be an LLM or a trained LLM; the specific object style can include the target positioning attributes of the object to be adjusted (here, the target positioning attributes are more specific and clear than the initial positioning attributes). For example, if the object to be adjusted is a residential building, its target positioning attributes may include the specific building shape, specific floor height, specific facade color, specific facade texture, specific door and window design style, etc.; for another example, if the object to be adjusted is a tree, its target positioning attributes may include the specific tree variety, specific tree height, specific tree inclination, specific leaf density, specific leaf color, etc.; for another example, if the object to be adjusted is a leisure seat, its target positioning attributes may include the specific seat material, specific seat color, specific seat size, etc.
[0170] In addition, in the disclosed embodiment, the object adjustment instruction may be obtained from the guiding object adjustment file. Among them, the guiding object adjustment file may be a guiding document formulated and issued by design engineers in the fields of professional metaverse, architectural design, etc., to explain how to make reasonable adjustments to the adjustment object. For example, the first object adjustment instruction can be obtained from the guiding object adjustment file: the facade color of the residential building cannot be pure dark gray; for another example, the second object adjustment instruction can be obtained from the guiding object adjustment file: the height of the tree cannot exceed 25M; for another example, the third object adjustment instruction can be obtained from the guiding object adjustment file: oleander shall not be planted in residential areas.
[0171] After using the second target macromodel to refine the overall object style, obtain the specific object style related to the object to be adjusted, and obtain the object adjustment instruction, the second target macromodel can be used to adjust the object to be adjusted based on the specific object style and the object adjustment instruction to obtain the target instance object corresponding to the object to be adjusted. In a specific example, "using the second target macromodel to adjust the object to be adjusted based on the specific object style and the object adjustment instruction to obtain the target instance object corresponding to the object to be adjusted" may include:
[0172] Obtaining a parameter expression of the object to be adjusted; wherein the parameter expression includes a plurality of initial parameters, and each of the plurality of initial parameters corresponds to an object attribute of the object to be adjusted;
[0173] Using the second target macromodel, based on the specific object style and the object adjustment indication, the multiple initial parameters are adjusted to obtain multiple target parameters corresponding to the multiple initial parameters one by one;
[0174] Based on multiple target parameters, the object to be adjusted is adjusted to obtain a target instance object corresponding to the object to be adjusted.
[0175] For example, if the object to be adjusted is a residential building, its multiple initial parameters may include the initial parameter corresponding to the object attribute of the specific building shape, the initial parameter corresponding to the object attribute of the specific floor height, the initial parameter corresponding to the object attribute of the specific facade color, the initial parameter corresponding to the object attribute of the specific facade texture, the initial parameter corresponding to the object attribute of the specific door and window design style, etc.; for another example, if the object to be adjusted is a tree, its multiple initial parameters may include the initial parameter corresponding to the object attribute of the specific tree variety, the initial parameter corresponding to the object attribute of the specific tree height, the initial parameter corresponding to the object attribute of the tree inclination, the initial parameter corresponding to the object attribute of the leaf density, the initial parameter corresponding to the object attribute of the leaf color, etc.; for another example, if the object to be adjusted is a leisure chair, its multiple initial parameters may include the initial parameter corresponding to the object attribute of the specific seat material, the initial parameter corresponding to the object attribute of the specific seat color, the initial parameter corresponding to the object attribute of the specific seat size, etc.
[0176] After obtaining the specific object style and object adjustment instructions, and acquiring the parameter expression of the object to be adjusted, the second target large model can be used to adjust multiple initial parameters based on the specific object style and object adjustment instructions, and obtain multiple target parameters corresponding to the multiple initial parameters one by one, and adjust the object to be adjusted based on the multiple target parameters to obtain a target instance object corresponding to the object to be adjusted.
[0177] In addition, it should be noted that in the embodiment of the present disclosure, after obtaining multiple target instance objects corresponding one-to-one to multiple preliminary instance objects, the multiple target instance objects can be filled into the target area to obtain a scene area corresponding to the target area, and based on the scene area, an initial virtual scene can be constructed.
[0178] (5) Evaluate the initial virtual scene
[0179] The purpose of evaluating the initial virtual scene is to determine whether the initial virtual scene meets the preset scene requirements.
[0180] In an example, the LLM may determine whether the initial virtual scene meets the preset scene requirement, wherein “determining whether the initial virtual scene meets the preset scene requirement” may include:
[0181] Obtaining a single evaluation result for the initial virtual scene from each evaluation dimension of the multiple evaluation dimensions, so as to obtain a plurality of single evaluation results corresponding to the multiple evaluation dimensions one by one;
[0182] Based on multiple single evaluation results, the overall evaluation result of the initial virtual scene is obtained;
[0183] When the overall evaluation result meets the preset evaluation requirements, it is determined that the initial virtual scene meets the preset scene requirements.
[0184] The multiple evaluation dimensions may include at least one of the demand function evaluation dimension, the spatial relationship evaluation dimension, and the architectural style evaluation dimension. Correspondingly, the multiple single evaluation results may include a first single evaluation result corresponding to the demand function evaluation dimension, a second single evaluation result corresponding to the spatial relationship evaluation dimension, and a third single evaluation result corresponding to the architectural style evaluation dimension. Here, the first single evaluation result is used to characterize whether the initial virtual scene meets the scene generation request; the second single evaluation result is used to characterize whether the spatial relationship of the initial virtual scene is reasonable; and the third single evaluation result is used to characterize whether the architectural style of the initial virtual scene is harmonious.
[0185] After obtaining multiple single evaluation results, the overall evaluation result of the initial virtual scene can be obtained based on the multiple single evaluation results, and when the overall evaluation result meets the preset evaluation requirements, it is determined that the initial virtual scene meets the preset scene requirements. The preset evaluation requirements can be that the first single evaluation result represents that the initial virtual scene meets the scene generation request, the second single evaluation result represents that the spatial relationship of the initial virtual scene is reasonable, and the third single evaluation result represents that the architectural style of the initial virtual scene is harmonious.
[0186] When it is determined that the initial virtual scene does not meet the preset scene requirements, the LLM can be used to provide adjustment suggestions for the initial virtual scene and adjust the initial virtual scene.
[0187] (6) Generate target virtual scene
[0188] When it is determined that the initial virtual scene meets the preset scene requirements, the target atmosphere information can be obtained, and based on the target atmosphere information, the initial virtual scene can be optimized to generate the target virtual scene.
[0189] The target atmosphere information includes at least one of 3D terrain information and weather information.
[0190] After the target atmosphere information is obtained, a parameter modification function corresponding to the target atmosphere information may be called to optimize the initial virtual scene and generate the target virtual scene.
[0191] (7) Send the target virtual scene to the terminal device
[0192] Among them, the terminal device is used to display the target virtual scene.
[0193] In addition, it should be noted that, in the embodiments of the present disclosure, when the developer is not satisfied with the target virtual scene, a scene modification requirement may be proposed as a new scene generation requirement to modify the target virtual scene.
[0194] See also Figure 7 , which is a schematic diagram of an application scenario of a virtual scene generation method provided in an embodiment of the present disclosure.
[0195] The virtual scene generation method provided by the embodiment of the present disclosure is applied to an electronic device. The electronic device may be a server or a terminal device. The terminal device may be a workbench, a mainframe computer, a conventional computer (e.g., a desktop computer, a laptop computer, a vehicle-mounted computer, etc.), a personal digital processing device or other similar computing devices.
[0196] Here, electronic devices are used to:
[0197] Get the scene generation request;
[0198] In response to the scene generation request, partition the original virtual scene to obtain a basic virtual scene; wherein the basic virtual scene includes a plurality of functional areas;
[0199] Taking each of the multiple functional areas as a target area, and using a target macro model to fill multiple target instance objects in the target area, so as to obtain a scene area corresponding to the target area;
[0200] Based on the scene area, a target virtual scene is generated.
[0201] It should be noted that in the embodiments of the present disclosure, Figure 7 The application scenario diagram shown is only illustrative and not restrictive. Those skilled in the art can Figure 7 Various obvious changes and / or substitutions are made to the examples, and the obtained technical solutions still fall within the scope of the disclosure of the embodiments of the present disclosure.
[0202] In order to better implement the aforementioned virtual scene generation method, the embodiment of the present disclosure also provides a virtual scene generation device, which can be integrated into an electronic device. The electronic device can be a server or a terminal device. Here, the terminal device can be a workbench, a mainframe computer, a conventional computer (for example, a desktop computer, a laptop computer, a car computer, etc.), a personal digital processing or other similar computing device. Figure 8 The schematic structural block diagram shown is used to illustrate a virtual scene generating device 800 provided in the disclosed embodiment.
[0203] The virtual scene generating device 800 comprises:
[0204] A request acquisition unit 801 is used to acquire a scene generation request;
[0205] The scene partitioning unit 802 is used to partition the original virtual scene in response to the scene generation request to obtain a basic virtual scene; wherein the basic virtual scene includes multiple functional areas;
[0206] The object filling unit 803 is used to take each of the multiple functional areas as a target area, and fill the target area with multiple target instance objects using a target macro model to obtain a scene area corresponding to the target area;
[0207] The scene generation unit 804 is used to generate a target virtual scene based on the scene area.
[0208] In some optional implementations, the object filling unit 803 is used to:
[0209] Using the first target large model, a plurality of preliminary selected instance objects related to the target area are selected from the instance object library;
[0210] Using the second target large model, the multiple preliminary instance objects are adjusted to obtain multiple target instance objects corresponding to the multiple preliminary instance objects one by one;
[0211] Fill the target area with multiple target instance objects to obtain a scene area corresponding to the target area.
[0212] In some optional implementations, the object filling unit 803 is used to:
[0213] Obtaining object selection requirements related to the target area;
[0214] Generate an overall object style related to the target area based on the scene generation request using the first target large model;
[0215] Using the first target large model, based on the object selection requirements and the overall object style, multiple preliminary instance objects related to the target area are selected from the instance object library.
[0216] In some optional implementations, the object filling unit 803 is used to:
[0217] Each of the multiple initially selected instance objects is used as an object to be adjusted, and the overall object style is refined using the second target large model to obtain a specific object style related to the object to be adjusted;
[0218] Get object adjustment indication;
[0219] The second target large model is used to adjust the object to be adjusted based on the specific object style and the object adjustment instruction, so as to obtain a target instance object corresponding to the object to be adjusted.
[0220] In some optional implementations, the object filling unit 803 is used to:
[0221] Obtaining a parameter expression of the object to be adjusted; wherein the parameter expression includes a plurality of initial parameters, and each of the plurality of initial parameters corresponds to an object property of the object to be adjusted;
[0222] Using the second target macromodel, based on the specific object style and the object adjustment indication, the multiple initial parameters are adjusted to obtain multiple target parameters corresponding to the multiple initial parameters one by one;
[0223] Based on multiple target parameters, the object to be adjusted is adjusted to obtain a target instance object corresponding to the object to be adjusted.
[0224] In some optional implementations, the scene generation unit 804 is used to:
[0225] Based on the scene area, construct an initial virtual scene;
[0226] When it is determined that the initial virtual scene meets the preset scene requirement, a target virtual scene is generated based on the initial virtual scene.
[0227] In some optional implementations, the scene generation unit 804 is used to:
[0228] Obtaining a single evaluation result for the initial virtual scene from each evaluation dimension of the multiple evaluation dimensions, so as to obtain a plurality of single evaluation results corresponding to the multiple evaluation dimensions one by one;
[0229] Based on multiple single evaluation results, the overall evaluation result of the initial virtual scene is obtained;
[0230] When the overall evaluation result meets the preset evaluation requirements, it is determined that the initial virtual scene meets the preset scene requirements.
[0231] In some optional implementations, the scene generation unit 804 is used to:
[0232] Obtain target atmosphere information;
[0233] Based on the target atmosphere information, the initial virtual scene is optimized to generate the target virtual scene.
[0234] In some optional implementations, the scene partitioning unit 802 is used to:
[0235] Based on the scene generation request, determine the target scene style;
[0236] Get scene partition instructions;
[0237] The partition model is used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain the basic virtual scene.
[0238] In the embodiment of the present disclosure, the specific functions and examples of each unit in the virtual scene generation device 800 can refer to the relevant descriptions of the corresponding steps in the aforementioned virtual scene generation method embodiment, which will not be repeated here.
[0239] In the technical solution disclosed herein, the acquisition, storage and application of user personal information involved are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0240] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium, and a computer program product.
[0241] Fig. 9 A schematic block diagram of an example electronic device 900 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as vehicle-mounted computing devices, laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.
[0242] like Fig. 9As shown, the electronic device 900 includes a computing unit 901, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 902 or a computer program loaded from a storage unit 908 to a random access memory (RAM) 903. In the RAM 903, various programs and data required for the operation of the electronic device 900 can also be stored. The computing unit 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.
[0243] A number of components in the electronic device 900 are connected to the I / O interface 905, including: an input unit 906, such as a keyboard, a mouse, etc.; an output unit 907, such as various types of renderers, speakers, etc.; a storage unit 908, such as a disk, an optical disk, etc.; and a communication unit 909, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 909 allows the electronic device 900 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0244] The computing unit 901 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 901 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSP), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 901 performs the various methods and processes described above, for example, a virtual scene generation method. For example, in some embodiments, the virtual scene generation method may be implemented as a computer software program, which is tangibly included in a machine-readable medium, for example, a storage unit 908. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 900 via the ROM 902 and / or the communication unit 909. When the computer program is loaded into the RAM 903 and executed by the computing unit 901, one or more steps in the virtual scene generation method described above may be executed. Alternatively, in other embodiments, the computing unit 901 may be configured as a virtual scene generating method in any other appropriate manner (eg, by means of firmware).
[0245] Various embodiments of the systems and techniques described above herein may be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0246] The program code for implementing the method of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer or other programmable data optimization device so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code can be executed completely on the machine, partially on the machine, partially on the machine as an independent software package and partially on a remote machine or completely on a remote machine or server.
[0247] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a RAM, a ROM, an erasable programmable read-only memory (EPROM) or a flash memory, an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0248] To provide interaction with a user, the systems and techniques described herein may be implemented on a computer having: a rendering device (e.g., a cathode ray tube (CRT) renderer or a liquid crystal display (LCD)) for rendering information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices are also used to provide interaction with the user; for example, the feedback provided to the user may 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 input, voice input, or tactile input).
[0249] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, 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 Network (LAN), Wide Area Network (WAN), and the Internet.
[0250] The computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship between the client and the server is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server can be a cloud server, a server of a distributed system, or a server combined with a blockchain.
[0251] The embodiment of the present disclosure also provides a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable a computer to execute a virtual scene generation method.
[0252] The embodiment of the present disclosure also provides a computer program product, including a computer program, which implements the virtual scene generation method when executed by a processor.
[0253] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in the present disclosure can be executed in parallel, sequentially or in a different order, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and this document does not limit this. In addition, in the present disclosure, relational terms such as "first", "second", "third", etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply the existence of any such actual relationship or order between these entities or operations. In addition, "multiple" in the present disclosure can be understood as at least two.
[0254] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the principles of the present disclosure shall be included in the protection scope of the present disclosure.
Claims
1. A virtual scene generation method, comprising: Get the scene generation request; In response to the scene generation request, partition the original virtual scene to obtain a basic virtual scene; wherein the basic virtual scene includes a plurality of functional areas; Taking each of the plurality of functional areas as a target area, and using a target macro model to fill a plurality of target instance objects in the target area, so as to obtain a scene area corresponding to the target area; Based on the scene area, a target virtual scene is generated.
2. The method according to claim 1, wherein: The method of using the target macro model to fill a plurality of target instance objects in the target area to obtain a scene area corresponding to the target area includes: Using the first target macromodel, a plurality of preliminarily selected instance objects related to the target area are selected from an instance object library; Using the second target macro model, adjusting the plurality of initially selected instance objects to obtain a plurality of target instance objects corresponding one-to-one to the plurality of initially selected instance objects; The target area is filled with the multiple target instance objects to obtain a scene area corresponding to the target area.
3. The method according to claim 2, wherein: The method of using the first target macro model to select a plurality of preliminarily selected instance objects related to the target area from an instance object library includes: Acquire object selection requirements related to the target area; Using the first target large model, based on the scene generation request, generating an overall object style related to the target area; The first target macromodel is used to select the plurality of preliminarily selected instance objects related to the target area from the instance object library based on the object selection requirements and the overall object style.
4. The method according to claim 3, wherein: The method of using the second target macro model to adjust the plurality of preliminarily selected instance objects to obtain a plurality of target instance objects corresponding one-to-one to the plurality of preliminarily selected instance objects includes: Taking each of the multiple initially selected instance objects as an object to be adjusted, and using the second target large model to refine the overall object style to obtain a specific object style related to the object to be adjusted; Get object adjustment indication; The object to be adjusted is adjusted using the second target macromodel based on the specific object style and the object adjustment instruction to obtain a target instance object corresponding to the object to be adjusted.
5. The method according to claim 4, wherein: The step of using the second target macromodel to adjust the object to be adjusted based on the specific object style and the object adjustment instruction to obtain a target instance object corresponding to the object to be adjusted includes: Acquire a parameter expression of the object to be adjusted; wherein the parameter expression includes a plurality of initial parameters, and each of the plurality of initial parameters corresponds to an object attribute of the object to be adjusted; Using the second target macromodel, based on the specific object style and the object adjustment instruction, the multiple initial parameters are adjusted to obtain multiple target parameters corresponding to the multiple initial parameters one by one; Based on the multiple target parameters, the object to be adjusted is adjusted to obtain a target instance object corresponding to the object to be adjusted.
6. The method according to any one of claims 1 to 5, wherein: The generating a target virtual scene based on the scene area includes: Based on the scene area, construct an initial virtual scene; In the case where it is determined that the initial virtual scene meets the preset scene requirement, the target virtual scene is generated based on the initial virtual scene.
7. The method according to claim 6, wherein: The determining that the initial virtual scene meets the preset scene requirement includes: Obtaining a single evaluation result for the initial virtual scene from each evaluation dimension of the multiple evaluation dimensions, so as to obtain a plurality of single evaluation results corresponding one-to-one to the multiple evaluation dimensions; Based on the multiple individual evaluation results, obtaining an overall evaluation result of the initial virtual scene; In the case where the overall evaluation result meets the preset evaluation requirement, it is determined that the initial virtual scene meets the preset scene requirement.
8. The method according to claim 6, wherein: The step of generating the target virtual scene based on the initial virtual scene includes: Obtain target atmosphere information; Based on the target atmosphere information, the initial virtual scene is optimized to generate the target virtual scene.
9. The method according to claim 1, wherein: The step of partitioning the original virtual scene in response to the scene generation request to obtain a basic virtual scene includes: Based on the scene generation request, determining a target scene style; Get scene partition instructions; The partition model is used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain a basic virtual scene.
10. A virtual scene generation device, comprising: A request acquisition unit, used to acquire a scene generation request; A scene partitioning unit, configured to partition the original virtual scene in response to the scene generation request to obtain a basic virtual scene; wherein the basic virtual scene includes a plurality of functional areas; An object filling unit, used for taking each of the plurality of functional areas as a target area, and filling the target area with a plurality of target instance objects by using a target macro model, so as to obtain a scene area corresponding to the target area; A scene generation unit is used to generate a target virtual scene based on the scene area.
11. The device according to claim 10, wherein: The object filling unit is used for: Using the first target macromodel, a plurality of preliminarily selected instance objects related to the target area are selected from an instance object library; Using the second target macro model, adjusting the plurality of initially selected instance objects to obtain a plurality of target instance objects corresponding one-to-one to the plurality of initially selected instance objects; The target area is filled with the multiple target instance objects to obtain a scene area corresponding to the target area.
12. The device according to claim 11, wherein The object filling unit is used for: Acquire object selection requirements related to the target area; Using the first target large model, based on the scene generation request, generating an overall object style related to the target area; The first target macromodel is used to select the plurality of preliminarily selected instance objects related to the target area from the instance object library based on the object selection requirements and the overall object style.
13. The device according to claim 12, wherein: The object filling unit is used for: Taking each of the multiple initially selected instance objects as an object to be adjusted, and using the second target large model to refine the overall object style to obtain a specific object style related to the object to be adjusted; Get object adjustment indication; The object to be adjusted is adjusted using the second target macromodel based on the specific object style and the object adjustment instruction to obtain a target instance object corresponding to the object to be adjusted.
14. The device according to claim 13, wherein: The object filling unit is used for: Acquire a parameter expression of the object to be adjusted; wherein the parameter expression includes a plurality of initial parameters, and each of the plurality of initial parameters corresponds to an object attribute of the object to be adjusted; Using the second target macromodel, based on the specific object style and the object adjustment instruction, the multiple initial parameters are adjusted to obtain multiple target parameters corresponding to the multiple initial parameters one by one; Based on the multiple target parameters, the object to be adjusted is adjusted to obtain a target instance object corresponding to the object to be adjusted.
15. The device according to any one of claims 10 to 14, wherein: The scene generation unit is used for: Based on the scene area, construct an initial virtual scene; In the case where it is determined that the initial virtual scene meets the preset scene requirement, the target virtual scene is generated based on the initial virtual scene.
16. The device according to claim 15, wherein: The scene generation unit is used for: Obtaining a single evaluation result for the initial virtual scene from each evaluation dimension of the multiple evaluation dimensions, so as to obtain a plurality of single evaluation results corresponding one-to-one to the multiple evaluation dimensions; Based on the multiple individual evaluation results, obtaining an overall evaluation result of the initial virtual scene; In the case where the overall evaluation result meets the preset evaluation requirement, it is determined that the initial virtual scene meets the preset scene requirement.
17. The device according to claim 15, wherein: The scene generation unit is used for: Obtain target atmosphere information; Based on the target atmosphere information, the initial virtual scene is optimized to generate the target virtual scene.
18. The device according to claim 10, wherein: The scene partition unit is used for: Based on the scene generation request, determining a target scene style; Get scene partition instructions; The partition model is used to partition the original virtual scene based on the target scene style and the scene partition indication to obtain a basic virtual scene.
19. An electronic device comprising: at least one processor; a memory communicatively coupled to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can perform the method according to any one of claims 1 to 9.
20. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 9.
21. A computer program product, comprising a computer program, which, when executed by a processor, implements the method according to any one of claims 1 to 9.
Citation Information
Patent Citations
Virtual scene generation method and device, readable medium and electronic equipment
CN116416404A
Deployment scene generation method and device based on digital twinning
CN117541913A
Virtual house creating method and device, storage medium and electronic device
CN118196349A
Spatial layout virtual scene generation method and device
CN118864663A
Virtual scenario generation method and apparatus, and device and storage medium
WO2022166681A1