[go: up one dir, main page]

WO2024138720A1 - Image generation method and apparatus, and computer device and storage medium - Google Patents

Image generation method and apparatus, and computer device and storage medium Download PDF

Info

Publication number
WO2024138720A1
WO2024138720A1 PCT/CN2022/144264 CN2022144264W WO2024138720A1 WO 2024138720 A1 WO2024138720 A1 WO 2024138720A1 CN 2022144264 W CN2022144264 W CN 2022144264W WO 2024138720 A1 WO2024138720 A1 WO 2024138720A1
Authority
WO
WIPO (PCT)
Prior art keywords
image
style
content
model
trained
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2022/144264
Other languages
French (fr)
Chinese (zh)
Inventor
陈升
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen TCL New Technology Co Ltd
Original Assignee
Shenzhen TCL New Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen TCL New Technology Co Ltd filed Critical Shenzhen TCL New Technology Co Ltd
Priority to PCT/CN2022/144264 priority Critical patent/WO2024138720A1/en
Publication of WO2024138720A1 publication Critical patent/WO2024138720A1/en
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L21/00Speech or voice signal processing techniques to produce another audible or non-audible signal, e.g. visual or tactile, in order to modify its quality or its intelligibility
    • G10L21/06Transformation of speech into a non-audible representation, e.g. speech visualisation or speech processing for tactile aids
    • G10L21/10Transforming into visible information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N1/00Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
    • H04N1/387Composing, repositioning or otherwise geometrically modifying originals

Definitions

  • display devices are increasingly widely used in people's lives.
  • display devices can display some wallpaper images with different contents and styles by default.
  • the main method used to display wallpaper images is that the technicians pre-set a set of wallpaper images, and when a wallpaper image needs to be displayed, one is randomly selected from the set for display.
  • this solution cannot guarantee that the content of the displayed wallpaper image fits the current environment, and the number of wallpaper images is limited, so there may be uneven image quality, which affects the user's visual experience.
  • the prior art cannot ensure that the content of the displayed wallpaper image fits the current environment, and the number of wallpaper images is also limited, and there may be problems of uneven image quality, which affects the user's visual experience.
  • the image generation instruction includes image attribute information of a target image to be generated
  • An instruction receiving unit used for receiving an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated;
  • An environmental information acquisition unit used to acquire environmental information, wherein the environmental information is collected by a display device that displays the target image;
  • the image generation device provided by the embodiment of the present invention further includes an image generation model training unit, which is used to obtain a generative adversarial model to be trained, wherein the generative adversarial model includes an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image;
  • an image generation model training unit which is used to obtain a generative adversarial model to be trained, wherein the generative adversarial model includes an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image;
  • the image generation system includes a terminal 10 and a server 20, etc.
  • the terminal 10 and the server 20 are connected via a network, such as a wired or wireless network connection, etc., wherein the terminal 10 can exist as a terminal for displaying a target image and sending an image generation instruction of the target image to the server 20.
  • the environmental sound audio is converted into a model input format of the image generation model to obtain environmental information.
  • a weighted calculation method can be used when integrating the ambient sound information and the ambient weather information.
  • the weights of the ambient sound information and the ambient weather information can be the same or different, and technicians and users can set them according to actual display requirements.
  • the style transfer in the style reference image can be implemented based on deep learning technology.
  • a style transfer model can be constructed through deep learning technology to extract style features and content features, and then feature fusion can be performed to achieve style transfer.
  • the step of "extracting style features from at least one preset style reference image, and extracting content features from the content image" can specifically include:
  • style features are extracted from the sample style reference image to obtain sample style features corresponding to the sample style reference image;
  • the model parameters of the style transfer model to be trained are adjusted to obtain a trained style transfer model.
  • the sample style reference image may be an image with any style
  • the sample content image may be an image with any content
  • the model parameters may specifically include the number of feature extraction layers used to extract feature information in the style transfer model, the number of input channels of the feature extraction layers, and the like.
  • the training set can be the large real image set of ImageNet.
  • Select a style transfer network (such as Fast style transfer[3]) for training and update the model parameters.
  • the trained model combines the feature weights extracted from the image content and the feature weights extracted from the style image.
  • the stylized image retains both the content details of the real image and the style details of the style image.
  • the model loss can be calculated based on the style loss between the sample style transfer image and the sample style reference image, and the content loss between the sample content image and the sample style transfer image. That is, the step of "calculating the model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image" may specifically include:
  • the model loss of the style transfer model to be trained is calculated.
  • style transfer models of multiple style types may be trained for backup.
  • the image attribute information includes the image style type.
  • the step of "extracting style features from at least one preset style reference image, and extracting content features from the content image, and obtaining a target image based on the fusion of the content features and the style features" may specifically include:
  • weights corresponding to the content features and the style features may be the same or different, which is not limited in the embodiment of the present invention.
  • an embodiment of the present invention can receive an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated, obtains environmental information, the environmental information is collected by a display device that displays the target image, performs data mapping on the environmental information through a preset image generation model, generates a content image corresponding to the environmental information, extracts style features from at least one preset style reference image, and extracts content features from the content image, and obtains the target image based on the fusion of the content features and the style features; since in an embodiment of the present invention, the image generation model can obtain the content image by mapping according to the environmental information, it can ensure that the content of the image fits the environment, and the content features in the content image can be fused with the style features in the style reference image to finally generate the target image, therefore, wallpaper images with rich content and diverse styles can be generated to enhance the user's visual experience.
  • the image generation instruction includes image attribute information of a target image to be generated, obtains environmental information, the environmental information is collected by a display device that displays the
  • an embodiment of the present invention further provides an image generating device.
  • the environment information acquisition unit 502 may be used to acquire environment information, wherein the environment information is collected by a display device that displays the target image;
  • the content image generation unit 503 may be used to perform data mapping on the environment information through a preset image generation model to generate a content image corresponding to the environment information;
  • the target image generating unit 504 may be configured to extract style features from at least one preset style reference image and content features from the content image, and obtain a target image based on a fusion of the content features and the style features.
  • the image generation apparatus may further include an image generation model training unit 505, which may be used to obtain a generative adversarial model to be trained, wherein the generative adversarial model may include an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image;
  • an image generation model training unit 505 which may be used to obtain a generative adversarial model to be trained, wherein the generative adversarial model may include an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image;
  • the content features and the style features are weightedly fused to obtain a target image.
  • the touch detection device detects the user's touch direction, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into the touch point coordinates, and then sends it to the processor 708, and can receive and execute the command sent by the processor 708.
  • the touch-sensitive surface can be implemented using multiple types such as resistive, capacitive, infrared and surface acoustic wave.
  • the input unit 703 may also include other input devices. Specifically, other input devices may include, but are not limited to, one or more of a physical keyboard, function keys (such as a volume control key, a switch key, etc.), a trackball, a mouse, a joystick, and the like.
  • the computer device may also include at least one sensor 705, such as a light sensor, a motion sensor, and other sensors.
  • the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel according to the brightness of the ambient light, and the proximity sensor may turn off the display panel and/or backlight when the computer device is moved to the ear.
  • the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally three axes), and can detect the magnitude and direction of gravity when stationary.
  • the computer device may also include a camera, a Bluetooth module, etc., which will not be described in detail here.
  • the processor 708 in the computer device will load the executable files corresponding to the processes of one or more application programs into the memory 702 according to the following instructions, and the processor 708 will run the application programs stored in the memory 702 to implement various functions, as follows:
  • the image generation instruction includes image attribute information of a target image to be generated
  • the image generation instruction includes image attribute information of a target image to be generated
  • Style features are extracted from at least one preset style reference image, and content features are extracted from the content image, and a target image is obtained based on the fusion of the content features and the style features.
  • the instructions stored in the computer-readable storage medium can execute the steps in any image generation method provided in the embodiments of the present invention, the beneficial effects that can be achieved by any image generation method provided in the embodiments of the present invention can be achieved. Please refer to the previous embodiments for details and will not be repeated here.
  • a computer program product or a computer program is also provided, the computer program product or the computer program including computer instructions, the computer instructions being stored in a computer-readable storage medium.
  • a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the methods provided in various optional implementations in the above-mentioned embodiments.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Computational Linguistics (AREA)
  • Theoretical Computer Science (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Multimedia (AREA)
  • Artificial Intelligence (AREA)
  • Molecular Biology (AREA)
  • Human Computer Interaction (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Acoustics & Sound (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Quality & Reliability (AREA)
  • Processing Or Creating Images (AREA)

Abstract

Disclosed in the embodiments of the present invention are an image generation method and apparatus, and a computer device and a storage medium. The method may comprise: receiving an image generation instruction, wherein the image generation instruction comprises image attribute information of a target image which is required to be generated; acquiring environment information, wherein the environment information is collected by means of a display device which displays the target image; performing data mapping on the environment information by means of a preset image generation model, so as to generate a content image corresponding to the environment information; and extracting a style feature from at least one preset style reference image, and extracting a content feature from the content image, so as to obtain a target image on the basis of the fusion of the content feature and the style feature. In the embodiments of the present invention, an image generation model may perform mapping according to environment information to obtain a content image, and a content feature in the content image can be fused with a style feature in a style reference image, such that a target image is finally generated, and thus various styles of wallpaper images with rich content can be generated, thereby improving the visual experience of a user.

Description

一种图像生成方法、装置、计算机设备和存储介质Image generation method, device, computer equipment and storage medium 技术领域Technical Field

本发明涉及图像处理技术领域,具体涉及一种图像生成方法、装置、计算机设备和存储介质。The present invention relates to the technical field of image processing, and in particular to an image generating method, device, computer equipment and storage medium.

背景技术Background technique

随着当前经济的快速发展,各类显示设备在人们生活中得到越来越广泛的应用。一般的,为了丰富用户的视觉体验,显示设备可以默认显示一些内容、风格各有不同的壁纸图像。With the rapid development of the current economy, various display devices are increasingly widely used in people's lives. Generally, in order to enrich the visual experience of users, display devices can display some wallpaper images with different contents and styles by default.

目前,在显示壁纸图像时采取的主要方法是,由技术人员预先设置壁纸图像的集合,当需要显示壁纸图像时,从集合中任意地选取一张进行显示。但是采用这种方案,不能够保证显示的壁纸图像的内容与当前环境贴合,且壁纸图像的数量也是有限的,可能存在图像质量参差不齐的问题,影响用户的视觉体验。At present, the main method used to display wallpaper images is that the technicians pre-set a set of wallpaper images, and when a wallpaper image needs to be displayed, one is randomly selected from the set for display. However, this solution cannot guarantee that the content of the displayed wallpaper image fits the current environment, and the number of wallpaper images is limited, so there may be uneven image quality, which affects the user's visual experience.

技术问题technical problem

现有技术中不能够保证显示的壁纸图像的内容与当前环境贴合,且壁纸图像的数量也是有限的,可能存在图像质量参差不齐的问题,影响用户的视觉体验。The prior art cannot ensure that the content of the displayed wallpaper image fits the current environment, and the number of wallpaper images is also limited, and there may be problems of uneven image quality, which affects the user's visual experience.

技术解决方案Technical Solutions

本发明实施例提供一种图像生成方法、装置、计算机设备和存储介质,可以生成内容丰富、风格多样的壁纸图像,令壁纸图像的内容与现实环境贴合,提升用户的视觉体验。The embodiments of the present invention provide an image generation method, apparatus, computer equipment and storage medium, which can generate wallpaper images with rich content and diverse styles, so that the content of the wallpaper image fits the real environment and enhances the user's visual experience.

本发明实施例提供一种图像生成方法,包括:An embodiment of the present invention provides an image generation method, comprising:

接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息;receiving an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated;

获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到;Acquiring environmental information, wherein the environmental information is collected by a display device that displays the target image;

通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像;Performing data mapping on the environmental information through a preset image generation model to generate a content image corresponding to the environmental information;

从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。Style features are extracted from at least one preset style reference image, and content features are extracted from the content image, and a target image is obtained based on the fusion of the content features and the style features.

相应的,本发明实施例还提供一种图像生成装置,包括:Accordingly, an embodiment of the present invention further provides an image generating device, comprising:

指令接收单元,用于接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息;An instruction receiving unit, used for receiving an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated;

环境信息获取单元,用于获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到;An environmental information acquisition unit, used to acquire environmental information, wherein the environmental information is collected by a display device that displays the target image;

内容图像生成单元,用于通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像;A content image generating unit, configured to perform data mapping on the environmental information through a preset image generating model, and generate a content image corresponding to the environmental information;

目标图像生成单元,用于从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。The target image generation unit is used to extract style features from at least one preset style reference image and content features from the content image, and obtain the target image based on the fusion of the content features and the style features.

可选的,本发明实施例提供的图像生成装置还包括图像生成模型训练单元,用于获取待训练的生成对抗模型,所述生成对抗模型包括待训练的图像生成模型和待训练的判别模型,所述生成对抗模型设置有至少一张真实内容样本图像;Optionally, the image generation device provided by the embodiment of the present invention further includes an image generation model training unit, which is used to obtain a generative adversarial model to be trained, wherein the generative adversarial model includes an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image;

通过所述待训练的图像生成模型对训练输入参数进行数据映射,生成所述训练输入参数对应的训练内容图像;Performing data mapping on the training input parameters through the image generation model to be trained to generate a training content image corresponding to the training input parameters;

通过所述待训练的判别模型计算所述训练内容图像相对于所述真实内容样本图像的真实度参数;Calculating the authenticity parameter of the training content image relative to the real content sample image by using the discriminant model to be trained;

基于所述真实度参数对所述待训练的图像生成模型和所述待训练的判别模型进行调整;Adjusting the image generation model to be trained and the discriminant model to be trained based on the truthfulness parameter;

返回执行所述通过所述待训练的图像生成模型对训练输入参数进行数据映射的步骤,直至满足预设的训练结束条件,得到训练后的图像生成模型。Return to execute the step of performing data mapping on the training input parameters through the image generation model to be trained until a preset training end condition is met, thereby obtaining a trained image generation model.

可选的,本发明实施例提供的图像生成装置还包括图像生成模型设置单元,用于获取所述显示设备的显示参数;Optionally, the image generation apparatus provided by the embodiment of the present invention further includes an image generation model setting unit, which is used to obtain display parameters of the display device;

基于所述显示参数,对所述待训练的图像生成模型的模型参数进行设置,得到新的待训练的图像生成模型。Based on the display parameters, the model parameters of the image generation model to be trained are set to obtain a new image generation model to be trained.

可选的,目标图像生成单元,用于根据风格迁移模型中风格提取层的风格特征映射参数,对预设的至少一张风格参考图像进行风格特征提取,得到所述风格参考图像对应的风格特征;Optionally, a target image generating unit is used to extract style features from at least one preset style reference image according to style feature mapping parameters of a style extraction layer in a style transfer model to obtain style features corresponding to the style reference image;

根据所述风格迁移模型中内容提取层的内容特征映射参数,对所述内容图像进行内容特征提取,得到所述内容图像对应的内容特征。According to the content feature mapping parameters of the content extraction layer in the style transfer model, content features are extracted from the content image to obtain content features corresponding to the content image.

可选的,本发明实施例提供的图像生成装置还包括风格迁移模型训练单元,用于通过待训练的风格迁移模型,对样本风格参考图像进行风格特征提取,得到所述样本风格参考图像对应的样本风格特征;Optionally, the image generation device provided by the embodiment of the present invention further includes a style transfer model training unit, which is used to extract style features of the sample style reference image through the style transfer model to be trained, so as to obtain sample style features corresponding to the sample style reference image;

通过所述待训练的风格迁移模型,对样本内容图像进行内容特征提取,得到所述样本内容图像对应的样本内容特征;Extracting content features of the sample content image by using the style transfer model to be trained to obtain sample content features corresponding to the sample content image;

针对所述样本风格特征和所述样本内容特征进行特征融合,得到样本风格迁移图像;Performing feature fusion on the sample style feature and the sample content feature to obtain a sample style transfer image;

基于所述样本风格迁移图像、所述样本风格参考图像和所述样本内容图像,计算所述待训练的风格迁移模型的模型损失;Calculating a model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image;

根据所述模型损失,对所述待训练的风格迁移模型的模型参数进行调整,得到训练后的风格迁移模型。According to the model loss, the model parameters of the style transfer model to be trained are adjusted to obtain a trained style transfer model.

可选的,所述环境信息获取单元,用于通过显示设备采集环境声音音频;Optionally, the environment information acquisition unit is used to collect environment sound audio through a display device;

将所述环境声音音频转化为所述图像生成模型的模型输入格式,得到环境信息。The environmental sound audio is converted into a model input format of the image generation model to obtain environmental information.

可选的,所述目标图像生成单元,用于从预设的至少一张风格参考图像中,选择至少一张所述图像风格类型对应的目标风格参考图像;Optionally, the target image generation unit is used to select at least one target style reference image corresponding to the image style type from at least one preset style reference image;

针对各所述目标风格参考图像提取风格特征,以及从所述内容图像中提取内容特征;Extracting style features for each of the target style reference images, and extracting content features from the content images;

将所述内容特征和所述风格特征进行加权融合,得到目标图像。The content features and the style features are weightedly fused to obtain a target image.

相应的,本发明实施例还提供一种计算机设备,包括存储器和处理器;所述存储器存储有应用程序,所述处理器用于运行所述存储器内的应用程序,以执行本发明实施例所提供的任一种图像生成方法中的步骤。Correspondingly, an embodiment of the present invention further provides a computer device, comprising a memory and a processor; the memory stores an application program, and the processor is used to run the application program in the memory to execute the steps in any one of the image generation methods provided in the embodiments of the present invention.

相应的,本发明实施例还提供一种计算机可读存储介质,所述计算机可读存储介质存储有多条指令,所述指令适于处理器进行加载,以执行本发明实施例所提供的任一种图像生成方法中的步骤。Correspondingly, an embodiment of the present invention further provides a computer-readable storage medium, which stores a plurality of instructions, and the instructions are suitable for a processor to load to execute the steps in any one of the image generation methods provided in the embodiments of the present invention.

此外,本发明实施例还提供一种计算机程序产品,包括计算机程序或指令,所述计算机程序或指令被处理器执行时实现本发明实施例所提供的任一种图像生成方法中的步骤。In addition, an embodiment of the present invention further provides a computer program product, including a computer program or instructions, which, when executed by a processor, implements the steps in any one of the image generating methods provided by the embodiments of the present invention.

有益效果Beneficial Effects

有益效果:与现有技术相比,本发明提供了一种图像生成方法,可以接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息,获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到,通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像,从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像;由于在本发明实施例中,图像生成模型可以根据环境信息进行映射得到内容图像,因此,可以保证图像的内容与环境贴合,而内容图像中的内容特征可以与风格参考图像中的风格特征融合,最终生成目标图像,因此,可以生成内容丰富、风格多样的壁纸图像,提升用户的视觉体验。Beneficial effect: Compared with the prior art, the present invention provides an image generation method, which can receive an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated, obtains environmental information, the environmental information is collected by a display device that displays the target image, performs data mapping on the environmental information through a preset image generation model, generates a content image corresponding to the environmental information, extracts style features from at least one preset style reference image, and extracts content features from the content image, and obtains the target image based on the fusion of the content features and the style features; in an embodiment of the present invention, the image generation model can obtain the content image by mapping according to the environmental information, therefore, it can be ensured that the content of the image fits the environment, and the content features in the content image can be fused with the style features in the style reference image to finally generate the target image, therefore, wallpaper images with rich content and diverse styles can be generated to enhance the user's visual experience.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

图1是本发明实施例提供的图像生成方法的场景示意图;FIG1 is a schematic diagram of a scene of an image generation method provided by an embodiment of the present invention;

图2是本发明实施例提供的图像生成方法的流程图;FIG2 is a flow chart of an image generating method provided by an embodiment of the present invention;

图3是本发明实施例提供的生成目标图像的技术实现示意图;FIG3 is a schematic diagram of a technical implementation of generating a target image provided by an embodiment of the present invention;

图4是本发明实施例提供的在智能电视上的应用示意图;FIG4 is a schematic diagram of an application on a smart TV provided by an embodiment of the present invention;

图5是本发明实施例提供的图像生成装置的结构示意图;5 is a schematic diagram of the structure of an image generating device provided by an embodiment of the present invention;

图6是本发明实施例提供的图像生成装置的另一结构示意图;FIG6 is another schematic diagram of the structure of an image generating device provided by an embodiment of the present invention;

图7是本发明实施例提供的计算机设备的结构示意图。FIG. 7 is a schematic diagram of the structure of a computer device provided in an embodiment of the present invention.

本发明的实施方式Embodiments of the present invention

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

本发明实施例提供一种图像生成方法、装置、计算机设备和计算机可读存储介质。具体地,本发明实施例提供适用于图像生成装置的图像生成方法,该图像生成装置可以集成在计算机设备中。The embodiments of the present invention provide an image generation method, an apparatus, a computer device and a computer-readable storage medium. Specifically, the embodiments of the present invention provide an image generation method applicable to an image generation apparatus, and the image generation apparatus can be integrated in a computer device.

该计算机设备可以为终端等设备,包括但不限于移动终端和固定终端,例如移动终端包括但不限于智能手机、智能手表、平板电脑、笔记本电脑、智能车载等,其中,固定终端包括但不限于台式电脑、智能电视等。The computer device may be a terminal or other device, including but not limited to a mobile terminal and a fixed terminal. For example, a mobile terminal includes but is not limited to a smart phone, a smart watch, a tablet computer, a laptop computer, a smart car-mounted terminal, etc., wherein a fixed terminal includes but is not limited to a desktop computer, a smart TV, etc.

该计算机设备还可以为服务器等设备,该服务器可以是独立的物理服务器,也可以是多个物理服务器构成的服务器集群或者分布式系统,还可以是提供云服务、云数据库、云计算、云函数、云存储、网络服务、云通信、中间件服务、域名服务、安全服务、CDN(Content Delivery Network,内容分发网络)、以及大数据和人工智能平台等基础云计算服务的云服务器,但并不局限于此。The computer device may also be a server or other device. The server may be an independent physical server or a server cluster or distributed system composed of multiple physical servers. It may also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), as well as big data and artificial intelligence platforms, but is not limited to these.

本发明实施例的图像生成方法,可以由服务器实现,也可以由终端和服务器共同实现。The image generating method according to the embodiment of the present invention may be implemented by a server, or may be implemented by a terminal and a server together.

下面以终端和服务器共同实现该图像生成方法为例,对该方法进行说明。The method is described below by taking the example of a terminal and a server jointly implementing the image generation method.

如图1所示,本发明实施例提供的图像生成系统包括终端10和服务器20等;终端10与服务器20之间通过网络连接,比如,通过有线或无线网络连接等,其中,终端10可以作为显示目标图像、向服务器20发送目标图像的图像生成指令的终端存在。As shown in FIG1 , the image generation system provided by the embodiment of the present invention includes a terminal 10 and a server 20, etc. The terminal 10 and the server 20 are connected via a network, such as a wired or wireless network connection, etc., wherein the terminal 10 can exist as a terminal for displaying a target image and sending an image generation instruction of the target image to the server 20.

其中,终端10可以为用户查看目标图像的终端,用于向服务器20发送目标图像的图像生成指令。The terminal 10 may be a terminal for a user to view a target image, and is used to send an image generation instruction for the target image to the server 20 .

服务器20,可以用于接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息,获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到,通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像,从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。The server 20 can be used to receive an image generation instruction, where the image generation instruction includes image attribute information of a target image to be generated, obtain environmental information, where the environmental information is collected through a display device that displays the target image, perform data mapping on the environmental information through a preset image generation model, generate a content image corresponding to the environmental information, extract style features from at least one preset style reference image, and extract content features from the content image, and obtain the target image based on a fusion of the content features and the style features.

服务器20可以将目标图像发送给终端10进行显示。The server 20 may send the target image to the terminal 10 for display.

在一些可选的实施例中,服务器20执行的目标图像的生成步骤,也可以由终端10执行,本发明实施例对此不做限定。In some optional embodiments, the step of generating the target image performed by the server 20 may also be performed by the terminal 10, which is not limited in the embodiment of the present invention.

以下分别进行详细说明。需要说明的是,以下实施例的描述顺序不作为对实施例优选顺序的限定。It should be noted that the description order of the following embodiments is not intended to limit the preferred order of the embodiments.

本发明实施例将从图像生成装置的角度进行描述,该图像生成装置具体可以集成在服务器和/或终端中。The embodiments of the present invention will be described from the perspective of an image generating device, which may be specifically integrated in a server and/or a terminal.

如图2所示,本实施例的图像生成方法的具体流程可以如下:As shown in FIG. 2 , the specific process of the image generation method of this embodiment may be as follows:

201、接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息。201. Receive an image generation instruction, where the image generation instruction includes image attribute information of a target image to be generated.

具体的,图像生成指令为指示生成目标图像的指令。图像生成指令可以是基于用户的操作生成的,也可以是显示设备主动生成的。Specifically, the image generation instruction is an instruction for instructing to generate a target image. The image generation instruction may be generated based on a user's operation or may be actively generated by the display device.

例如,图像生成指令可以是根据用户的开机操作、返回桌面的操作等生成的;或者,图像生成指令可以是在显示设备的运行过程中定时或者不定时生成的,等等。For example, the image generation instruction may be generated according to the user's power-on operation, return to the desktop operation, etc.; or, the image generation instruction may be generated regularly or irregularly during the operation of the display device, and so on.

其中,图像属性信息为与目标图像自身相关的信息。例如,图像属性信息可以包括但不限于目标图像的风格类型、分辨率、图像内容的类别等等。The image attribute information is information related to the target image itself, for example, the image attribute information may include but is not limited to the style type, resolution, category of image content, etc. of the target image.

202、获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到。202. Acquire environmental information, where the environmental information is collected through a display device that displays the target image.

具体的,环境信息可以是显示设备对所处环境的信息进行收集得到的。例如,环境信息可以包括但不限于环境亮度相关信息、环境声音相关信息、环境温度相关信息、环境天气相关信息等等。Specifically, the environmental information may be obtained by collecting information about the environment in which the display device is located. For example, the environmental information may include, but is not limited to, information related to environmental brightness, information related to environmental sound, information related to environmental temperature, information related to environmental weather, and the like.

以环境信息包括环境声音相关信息为例,步骤“获取环境信息”,具体可以包括:Taking the environmental information including the information related to the environmental sound as an example, the step of “obtaining the environmental information” may specifically include:

通过显示设备采集环境声音音频;Collect environmental sound audio through display devices;

将所述环境声音音频转化为所述图像生成模型的模型输入格式,得到环境信息。The environmental sound audio is converted into a model input format of the image generation model to obtain environmental information.

例如,可以在智能电视端通过麦克风设备接受音频信号得到环境声音音频;对音频信息(环境声音音频)进行预处理,从音频中获取声波,再从声波中提取数值如振幅、脉冲,转化为图像生成模型的模型输入格式例如一维数组的格式,作为改变目标图像中的图像内容的环境信息。For example, the audio signal can be received by a microphone device on the smart TV to obtain ambient sound audio; the audio information (ambient sound audio) is preprocessed to obtain sound waves from the audio, and then numerical values such as amplitude and pulse are extracted from the sound waves and converted into a model input format of an image generation model, such as a one-dimensional array format, as environmental information for changing the image content in the target image.

将音频信息转成的一维数值作为输入,生成网络生成与真实图像无差别的内容别致的真实图像,风格迁移网络将其风格化成艺术抽象的图像,并将风格化后16:9的艺术抽象图像放在界面上全屏显示,多线程接收声音数据,不断生成壁纸再不断刷新显示。The one-dimensional numerical value converted from audio information is used as input, and the generative network generates a real image with unique content that is indistinguishable from the real image. The style transfer network stylizes it into an artistic abstract image, and the stylized 16:9 artistic abstract image is displayed in full screen on the interface. Multi-threaded sound data is received, and wallpaper is continuously generated and then refreshed.

可以理解的是,环境信息中还可以包括声音之外的其他信息,例如,步骤“获取环境信息”,具体可以包括:It is understandable that the environmental information may also include other information besides sound. For example, the step of “obtaining environmental information” may specifically include:

通过显示设备采集环境声音音频,得到环境声音信息;Collecting ambient sound audio through the display device to obtain ambient sound information;

获取所述显示设备对应的环境天气信息;Obtaining environmental weather information corresponding to the display device;

对所述环境声音信息和所述环境天气信息进行融合,生成融合后环境信息;Fusing the ambient sound information and the ambient weather information to generate fused ambient information;

将所述融合后环境信息转化为所述图像生成模型的模型输入格式,得到环境信息。The fused environmental information is converted into a model input format of the image generation model to obtain environmental information.

其中,融合环境声音信息和环境天气信息时可以采用加权计算的方法。环境声音信息和环境天气信息的权重可以相同也可以不同,技术人员和用户可以根据实际显示需求进行设置。Among them, a weighted calculation method can be used when integrating the ambient sound information and the ambient weather information. The weights of the ambient sound information and the ambient weather information can be the same or different, and technicians and users can set them according to actual display requirements.

203、通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像。203. Perform data mapping on the environmental information through a preset image generation model to generate a content image corresponding to the environmental information.

在本发明实施例中,图像生成模型为GAN(Generative Adversarial Network,生成对抗网络)中的生成模型。GAN作为深度学习的相关技术,它利用生成模型和判别模型的互相博弈学习产生与实际照片几乎没有区别的照片。In the embodiment of the present invention, the image generation model is a generative model in GAN (Generative Adversarial Network). GAN is a related technology of deep learning. It uses the mutual game learning of the generative model and the discriminative model to generate photos that are almost indistinguishable from the actual photos.

但是,在GAN领域存在对训练数据质量和数量要求高、难训练不稳定且细节易崩坏的问题,艺术图像往往有图像内容抽象、图像内容种类繁多、一幅图像一种风格,数据量有限且质量层次不齐的特点,直接训练艺术图像生成的质量较差。However, in the field of GAN, there are problems such as high requirements on the quality and quantity of training data, difficulty in training, instability, and easy collapse of details. Artistic images often have abstract image content, a wide variety of image content, one style for each image, limited data volume, and uneven quality. The quality of directly training artistic images is poor.

因此,在本发明实施例中,采用真实内容的图像而非艺术图像对GAN进行训练,保证了目标图像中图像内容的真实性,避免了图像内容抽象等问题。且真实图像的质量相较于艺术图像更容易控制,也更容易获得,可以提升目标图像的图像质量。Therefore, in the embodiment of the present invention, images with real content rather than artistic images are used to train GAN, which ensures the authenticity of the image content in the target image and avoids problems such as abstract image content. In addition, the quality of real images is easier to control and obtain than that of artistic images, which can improve the image quality of the target image.

为了使图像生成模型能够达到更好的图像生成性能,可以通过预训练的过程,对图像生成模型的参数等进行调整。也就是说,步骤“通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像”之前,本发明实施例提供的图像生成方法还可以包括:In order to enable the image generation model to achieve better image generation performance, the parameters of the image generation model can be adjusted through the pre-training process. That is, before the step of "data mapping the environmental information through a preset image generation model to generate a content image corresponding to the environmental information", the image generation method provided by the embodiment of the present invention may also include:

获取待训练的生成对抗模型,所述生成对抗模型包括待训练的图像生成模型和待训练的判别模型,所述生成对抗模型设置有至少一张真实内容样本图像;Obtaining a generative adversarial model to be trained, wherein the generative adversarial model includes an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image;

通过所述待训练的图像生成模型对训练输入参数进行数据映射,生成所述训练输入参数对应的训练内容图像;Performing data mapping on the training input parameters through the image generation model to be trained to generate a training content image corresponding to the training input parameters;

通过所述待训练的判别模型计算所述训练内容图像相对于所述真实内容样本图像的真实度参数;Calculating the authenticity parameter of the training content image relative to the real content sample image by using the discriminant model to be trained;

基于所述真实度参数对所述待训练的图像生成模型和所述待训练的判别模型进行调整;Adjusting the image generation model to be trained and the discriminant model to be trained based on the truthfulness parameter;

返回执行所述通过所述待训练的图像生成模型对训练输入参数进行数据映射的步骤,直至满足预设的训练结束条件,得到训练后的图像生成模型。Return to execute the step of performing data mapping on the training input parameters through the image generation model to be trained until a preset training end condition is met, thereby obtaining a trained image generation model.

其中,真实内容样本图像中的图像内容,例如花草、人物等,都是现实环境中存在的。本发明实施例对真实内容样本图像中的内容类型不做限定。The image contents in the real content sample images, such as flowers, plants, people, etc., all exist in the real environment. The embodiment of the present invention does not limit the content type in the real content sample images.

具体的,真实度参数用于描述训练内容图像中图像内容的真实程度,真实程度可以通过训练内容图像与真实内容样本图像之间的相似度确定。比如,可以是判别模型对训练内容图像进行打分,输出训练内容图像对应的一个0-1之间的置信度。Specifically, the authenticity parameter is used to describe the authenticity of the image content in the training content image, and the authenticity can be determined by the similarity between the training content image and the real content sample image. For example, the discriminant model can score the training content image and output a confidence level between 0 and 1 corresponding to the training content image.

在实际的训练中,图像生成模型和判别模型的优化可以不是逐次交替的,而是每训练k次的判别模型后,训练一次图像生成模型,这样能保证图像生成模型的变化足够慢,使总是能判别模型保持在其最佳解附近。In actual training, the optimization of the image generation model and the discriminant model may not be alternating one after another. Instead, the image generation model is trained once after training the discriminant model k times. This ensures that the image generation model changes slowly enough so that the discriminant model can always remain near its optimal solution.

其中,训练结束条件可以是对图像生成模型的模型调整次数达到预设的调整次数阈值,或者,连续N次判别模型输出的真实度参数大于预设的阈值,等等。Among them, the training end condition may be that the number of model adjustments to the image generation model reaches a preset adjustment number threshold, or that the authenticity parameter of the discriminant model output is greater than a preset threshold for N consecutive times, and so on.

在预先训练GAN网络的过程中,如图3所示,可以采集大量高质量分辨率(720p、1080p、2k)的真实图像作为训练集,图像内容大气美观,诸如风景图,选一GAN网络(如具有代表性的StyleGAN[1]、BigGAN[2]),GAN网络默认随机一维输入,训练这一GAN网络,更新模型的参数,网络不断提取图像内容的细节特征,直至在测试时生成与实际图像几乎无区别的图像。In the process of pre-training the GAN network, as shown in Figure 3, a large number of real images with high-quality resolution (720p, 1080p, 2k) can be collected as training sets. The image content is atmospheric and beautiful, such as landscape pictures. A GAN network (such as the representative StyleGAN[1] and BigGAN[2]) is selected. The GAN network defaults to random one-dimensional input. This GAN network is trained and the model parameters are updated. The network continuously extracts detailed features of the image content until an image that is almost indistinguishable from the actual image is generated during testing.

可以理解的是,不同的显示设备的显示参数可能存在差异,可以预先根据显示参数对图像生成模型的模型参数进行调整。即,步骤“通过所述待训练的图像生成模型对训练输入参数进行数据映射,生成所述训练输入参数对应的训练内容图像”之前,本发明实施例提供的图像生成方法还可以包括:It is understandable that the display parameters of different display devices may be different, and the model parameters of the image generation model may be adjusted in advance according to the display parameters. That is, before the step of "data mapping the training input parameters through the image generation model to be trained to generate the training content image corresponding to the training input parameters", the image generation method provided by the embodiment of the present invention may also include:

获取所述显示设备的显示参数;Acquire display parameters of the display device;

基于所述显示参数,对所述待训练的图像生成模型的模型参数进行设置,得到新的待训练的图像生成模型。Based on the display parameters, the model parameters of the image generation model to be trained are set to obtain a new image generation model to be trained.

例如,待训练的图像生成模型的模型参数中卷积核的大小可以为4*4,生成的图像比例为1:1。而显示设备的显示参数可能需要的是16:9比例的壁纸图像,此时,以将卷积核的大小改成3:5,等等。For example, the size of the convolution kernel in the model parameters of the image generation model to be trained can be 4*4, and the generated image ratio is 1:1. However, the display parameters of the display device may require a wallpaper image with a ratio of 16:9. In this case, the size of the convolution kernel can be changed to 3:5, and so on.

如图4所示,图像生成模型可以设置在如智能电视等终端上,智能电视可以在内存中基于环境扰动(即环境信息)、图像生成模型(GAN)等生成目标图像作为智能电视的艺术壁纸。As shown in FIG. 4 , the image generation model can be set on a terminal such as a smart TV, and the smart TV can generate a target image in memory based on environmental disturbances (i.e., environmental information), an image generation model (GAN), etc. as an artistic wallpaper of the smart TV.

204、从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。204. Extract style features from at least one preset style reference image, and extract content features from the content image, and obtain a target image based on a fusion of the content features and the style features.

其中,风格可以理解为图像给观看者带来的主观感受,风格可以通过图像中的颜色、纹理等体现。比如,不同的人创造的图像一般会具有不同的个人特点,这种个人特点通过图像展现出即为风格。Among them, style can be understood as the subjective feeling that an image brings to the viewer, and style can be reflected through the color, texture, etc. in the image. For example, images created by different people generally have different personal characteristics, and this personal characteristic shown through the image is style.

可选的,将风格参考图像中的风格进行迁移,可以是基于深度学习技术实现的。比如,可以通过深度学习技术构建风格迁移模型以提取风格特征和内容特征,进而进行特征融合实现风格迁移。步骤“从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征”,具体可以包括:Optionally, the style transfer in the style reference image can be implemented based on deep learning technology. For example, a style transfer model can be constructed through deep learning technology to extract style features and content features, and then feature fusion can be performed to achieve style transfer. The step of "extracting style features from at least one preset style reference image, and extracting content features from the content image" can specifically include:

根据风格迁移模型中风格提取层的风格特征映射参数,对预设的至少一张风格参考图像进行风格特征提取,得到所述风格参考图像对应的风格特征;Extracting style features from at least one preset style reference image according to style feature mapping parameters of a style extraction layer in a style transfer model to obtain style features corresponding to the style reference image;

根据所述风格迁移模型中内容提取层的内容特征映射参数,对所述内容图像进行内容特征提取,得到所述内容图像对应的内容特征。According to the content feature mapping parameters of the content extraction layer in the style transfer model, content features are extracted from the content image to obtain content features corresponding to the content image.

例如,风格迁移模型中的风格提取层和内容提取层分别可以是以CNN、DNN、GAN等机器学习网络中的其中一种为框架的模型。For example, the style extraction layer and the content extraction layer in the style transfer model can be models with one of the machine learning networks such as CNN, DNN, GAN as the framework.

其中,风格迁移模型为可以对图像的特征进行提取的网络结构,比如,风格迁移模型中可以包括卷积层,卷积层可以通过卷积运算提取图像的特征。The style transfer model is a network structure that can extract features of an image. For example, the style transfer model may include a convolutional layer, and the convolutional layer can extract features of an image through a convolution operation.

在一些可选的实施例中,风格迁移模型是通过预训练得到的。通过预训练的过程,可以对风格迁移模型的参数等进行调整,使风格迁移模型能够达到更好的风格迁移性能。步骤“根据风格迁移模型中风格提取层的风格特征映射参数,对预设的至少一张风格参考图像进行风格特征提取,得到所述风格参考图像对应的风格特征”之前,本发明实施例提供的图像生成方法还可以包括:In some optional embodiments, the style transfer model is obtained through pre-training. Through the pre-training process, the parameters of the style transfer model can be adjusted so that the style transfer model can achieve better style transfer performance. Before the step of "extracting style features from at least one preset style reference image according to the style feature mapping parameters of the style extraction layer in the style transfer model to obtain the style features corresponding to the style reference image", the image generation method provided by the embodiment of the present invention may also include:

通过待训练的风格迁移模型,对样本风格参考图像进行风格特征提取,得到所述样本风格参考图像对应的样本风格特征;By using the style transfer model to be trained, style features are extracted from the sample style reference image to obtain sample style features corresponding to the sample style reference image;

通过所述待训练的风格迁移模型,对样本内容图像进行内容特征提取,得到所述样本内容图像对应的样本内容特征;Extracting content features of the sample content image by using the style transfer model to be trained to obtain sample content features corresponding to the sample content image;

针对所述样本风格特征和所述样本内容特征进行特征融合,得到样本风格迁移图像;Performing feature fusion on the sample style feature and the sample content feature to obtain a sample style transfer image;

基于所述样本风格迁移图像、所述样本风格参考图像和所述样本内容图像,计算所述待训练的风格迁移模型的模型损失;Calculating a model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image;

根据所述模型损失,对所述待训练的风格迁移模型的模型参数进行调整,得到训练后的风格迁移模型。According to the model loss, the model parameters of the style transfer model to be trained are adjusted to obtain a trained style transfer model.

其中,样本风格参考图像可以是具有任意的风格的图像,样本内容图像可以是具有任意的内容的图像。The sample style reference image may be an image with any style, and the sample content image may be an image with any content.

其中,模型参数具体可以包括风格迁移模型中用于提取特征信息的特征提取层的层数、特征提取层的输入通道数量等等。The model parameters may specifically include the number of feature extraction layers used to extract feature information in the style transfer model, the number of input channels of the feature extraction layers, and the like.

例如,在预先训练风格迁移网络时,可选梵高、莫奈风格的任一图像作为风格图像进行训练,训练集可用ImageNet大型真实图像集,选一风格迁移网络(如 Fast style transfer[3])进行训练,更新模型参数,直训练出的模型同时融合了图像内容提取中的特征权重和风格图像中提取的特征权重,测试时风格化后的图像同时保留了真实图像的内容细节和风格图像的风格细节。For example, when pre-training a style transfer network, you can select any image in the style of Van Gogh or Monet as a style image for training. The training set can be the large real image set of ImageNet. Select a style transfer network (such as Fast style transfer[3]) for training and update the model parameters. The trained model combines the feature weights extracted from the image content and the feature weights extracted from the style image. When testing, the stylized image retains both the content details of the real image and the style details of the style image.

在一些可选的示例中,模型损失可以根据样本风格迁移图像与样本风格参考图像之间的风格损失,以及样本内容图像与样本风格迁移图像之间的内容损失计算得到。即,步骤“基于所述样本风格迁移图像、所述样本风格参考图像和所述样本内容图像,计算所述待训练的风格迁移模型的模型损失”具体可以包括:In some optional examples, the model loss can be calculated based on the style loss between the sample style transfer image and the sample style reference image, and the content loss between the sample content image and the sample style transfer image. That is, the step of "calculating the model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image" may specifically include:

计算样本风格迁移图像和样本风格参考图像之间的风格相似度,作为待训练的风格迁移模型的风格损失;Calculate the style similarity between the sample style transfer image and the sample style reference image as the style loss of the style transfer model to be trained;

计算样本风格迁移图像和样本内容图像之间的内容相似度,计算作为待训练的风格迁移模型的内容损失;Calculate the content similarity between the sample style transfer image and the sample content image, and calculate the content loss of the style transfer model to be trained;

基于风格损失和内容损失,计算待训练的风格迁移模型的模型损失。Based on the style loss and content loss, the model loss of the style transfer model to be trained is calculated.

具体的,模型损失可以对风格损失和内容损失进行加权计算,风格损失和内容损失的权重可以由技术人员自行设置。Specifically, the model loss can be calculated by weighting the style loss and the content loss, and the weights of the style loss and the content loss can be set by the technicians themselves.

在实际应用过程中,可以可训练多种风格类型的风格迁移模型备用,可选的,图像属性信息包括图像风格类型,步骤“从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像”,具体可以包括:In actual application, style transfer models of multiple style types may be trained for backup. Optionally, the image attribute information includes the image style type. The step of "extracting style features from at least one preset style reference image, and extracting content features from the content image, and obtaining a target image based on the fusion of the content features and the style features" may specifically include:

从预设的至少一张风格参考图像中,选择至少一张所述图像风格类型对应的目标风格参考图像;Selecting at least one target style reference image corresponding to the image style type from at least one preset style reference image;

针对各所述目标风格参考图像提取风格特征,以及从所述内容图像中提取内容特征;Extracting style features for each of the target style reference images, and extracting content features from the content images;

将所述内容特征和所述风格特征进行加权融合,得到目标图像。The content features and the style features are weightedly fused to obtain a target image.

其中,内容特征和风格特征对应的权重可以相同,也可以不同,本发明实施例对此不做限定。The weights corresponding to the content features and the style features may be the same or different, which is not limited in the embodiment of the present invention.

由上可知,本发明实施例可以接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息,获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到,通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像,从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像;由于在本发明实施例中,图像生成模型可以根据环境信息进行映射得到内容图像,因此,可以保证图像的内容与环境贴合,而内容图像中的内容特征可以与风格参考图像中的风格特征融合,最终生成目标图像,因此,可以生成内容丰富、风格多样的壁纸图像,提升用户的视觉体验。As can be seen from the above, an embodiment of the present invention can receive an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated, obtains environmental information, the environmental information is collected by a display device that displays the target image, performs data mapping on the environmental information through a preset image generation model, generates a content image corresponding to the environmental information, extracts style features from at least one preset style reference image, and extracts content features from the content image, and obtains the target image based on the fusion of the content features and the style features; since in an embodiment of the present invention, the image generation model can obtain the content image by mapping according to the environmental information, it can ensure that the content of the image fits the environment, and the content features in the content image can be fused with the style features in the style reference image to finally generate the target image, therefore, wallpaper images with rich content and diverse styles can be generated to enhance the user's visual experience.

为了更好地实施以上方法,相应的,本发明实施例还提供一种图像生成装置。In order to better implement the above method, accordingly, an embodiment of the present invention further provides an image generating device.

参考图5,该装置可以包括:Referring to FIG5 , the apparatus may include:

指令接收单元501,可以用于接收图像生成指令,所述图像生成指令可以包括需要生成的目标图像的图像属性信息;The instruction receiving unit 501 may be used to receive an image generation instruction, wherein the image generation instruction may include image attribute information of a target image to be generated;

环境信息获取单元502,可以用于获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到;The environment information acquisition unit 502 may be used to acquire environment information, wherein the environment information is collected by a display device that displays the target image;

内容图像生成单元503,可以用于通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像;The content image generation unit 503 may be used to perform data mapping on the environment information through a preset image generation model to generate a content image corresponding to the environment information;

目标图像生成单元504,可以用于从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。The target image generating unit 504 may be configured to extract style features from at least one preset style reference image and content features from the content image, and obtain a target image based on a fusion of the content features and the style features.

在一些可选的实施例中,如图6所示,本发明实施例提供的图像生成装置还可以包括图像生成模型训练单元505,可以用于获取待训练的生成对抗模型,所述生成对抗模型可以包括待训练的图像生成模型和待训练的判别模型,所述生成对抗模型设置有至少一张真实内容样本图像;In some optional embodiments, as shown in FIG6 , the image generation apparatus provided by the embodiment of the present invention may further include an image generation model training unit 505, which may be used to obtain a generative adversarial model to be trained, wherein the generative adversarial model may include an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image;

通过所述待训练的图像生成模型对训练输入参数进行数据映射,生成所述训练输入参数对应的训练内容图像;Performing data mapping on the training input parameters through the image generation model to be trained to generate a training content image corresponding to the training input parameters;

通过所述待训练的判别模型计算所述训练内容图像相对于所述真实内容样本图像的真实度参数;Calculating the authenticity parameter of the training content image relative to the real content sample image by using the discriminant model to be trained;

基于所述真实度参数对所述待训练的图像生成模型和所述待训练的判别模型进行调整;Adjusting the image generation model to be trained and the discriminant model to be trained based on the truthfulness parameter;

返回执行所述通过所述待训练的图像生成模型对训练输入参数进行数据映射的步骤,直至满足预设的训练结束条件,得到训练后的图像生成模型。Return to execute the step of performing data mapping on the training input parameters through the image generation model to be trained until a preset training end condition is met, thereby obtaining a trained image generation model.

在一些可选的实施例中,如图6所示,本发明实施例提供的图像生成装置还可以包括图像生成模型设置单元506,可以用于获取所述显示设备的显示参数;In some optional embodiments, as shown in FIG6 , the image generation apparatus provided by the embodiment of the present invention may further include an image generation model setting unit 506, which may be used to obtain display parameters of the display device;

基于所述显示参数,对所述待训练的图像生成模型的模型参数进行设置,得到新的待训练的图像生成模型。Based on the display parameters, the model parameters of the image generation model to be trained are set to obtain a new image generation model to be trained.

在一些可选的实施例中,目标图像生成单元504,可以用于根据风格迁移模型中风格提取层的风格特征映射参数,对预设的至少一张风格参考图像进行风格特征提取,得到所述风格参考图像对应的风格特征;In some optional embodiments, the target image generation unit 504 may be configured to extract style features from at least one preset style reference image according to style feature mapping parameters of a style extraction layer in a style transfer model, to obtain style features corresponding to the style reference image;

根据所述风格迁移模型中内容提取层的内容特征映射参数,对所述内容图像进行内容特征提取,得到所述内容图像对应的内容特征。According to the content feature mapping parameters of the content extraction layer in the style transfer model, content features are extracted from the content image to obtain content features corresponding to the content image.

在一些可选的实施例中,本发明实施例提供的图像生成装置还可以包括风格迁移模型训练单元507,可以用于通过待训练的风格迁移模型,对样本风格参考图像进行风格特征提取,得到所述样本风格参考图像对应的样本风格特征;In some optional embodiments, the image generation apparatus provided by the embodiment of the present invention may further include a style transfer model training unit 507, which may be used to extract style features of the sample style reference image through the style transfer model to be trained, so as to obtain sample style features corresponding to the sample style reference image;

通过所述待训练的风格迁移模型,对样本内容图像进行内容特征提取,得到所述样本内容图像对应的样本内容特征;Extracting content features of the sample content image by using the style transfer model to be trained to obtain sample content features corresponding to the sample content image;

针对所述样本风格特征和所述样本内容特征进行特征融合,得到样本风格迁移图像;Performing feature fusion on the sample style feature and the sample content feature to obtain a sample style transfer image;

基于所述样本风格迁移图像、所述样本风格参考图像和所述样本内容图像,计算所述待训练的风格迁移模型的模型损失;Calculating a model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image;

根据所述模型损失,对所述待训练的风格迁移模型的模型参数进行调整,得到训练后的风格迁移模型。According to the model loss, the model parameters of the style transfer model to be trained are adjusted to obtain a trained style transfer model.

在一些可选的实施例中,所述环境信息获取单元,可以用于通过显示设备采集环境声音音频;In some optional embodiments, the environment information acquisition unit may be used to collect environment sound audio through a display device;

将所述环境声音音频转化为所述图像生成模型的模型输入格式,得到环境信息。The environmental sound audio is converted into a model input format of the image generation model to obtain environmental information.

在一些可选的实施例中,所述目标图像生成单元,可以用于从预设的至少一张风格参考图像中,选择至少一张所述图像风格类型对应的目标风格参考图像;In some optional embodiments, the target image generation unit may be configured to select at least one target style reference image corresponding to the image style type from at least one preset style reference image;

针对各所述目标风格参考图像提取风格特征,以及从所述内容图像中提取内容特征;Extracting style features for each of the target style reference images, and extracting content features from the content images;

将所述内容特征和所述风格特征进行加权融合,得到目标图像。The content features and the style features are weightedly fused to obtain a target image.

由上可知,通过图像生成装置,可以接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息,获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到,通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像,从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像;由于在本发明实施例中,图像生成模型可以根据环境信息进行映射得到内容图像,因此,可以保证图像的内容与环境贴合,而内容图像中的内容特征可以与风格参考图像中的风格特征融合,最终生成目标图像,因此,可以生成内容丰富、风格多样的壁纸图像,提升用户的视觉体验。As can be seen from the above, through the image generation device, an image generation instruction can be received, the image generation instruction includes image attribute information of a target image to be generated, and environmental information is obtained, the environmental information is collected by a display device that displays the target image, and the environmental information is data mapped by a preset image generation model to generate a content image corresponding to the environmental information, and style features are extracted from at least one preset style reference image, and content features are extracted from the content image, and the target image is obtained based on the fusion of the content features and the style features; because in an embodiment of the present invention, the image generation model can map the content image according to the environmental information, therefore, it can be ensured that the content of the image fits the environment, and the content features in the content image can be fused with the style features in the style reference image to finally generate the target image, therefore, wallpaper images with rich content and diverse styles can be generated to enhance the user's visual experience.

此外,本发明实施例还提供一种计算机设备,该计算机设备可以为终端或者服务器等等,如图7所示,其示出了本发明实施例所涉及的计算机设备的结构示意图,具体来讲:In addition, an embodiment of the present invention further provides a computer device, which may be a terminal or a server, etc. As shown in FIG. 7 , a schematic diagram of the structure of the computer device involved in the embodiment of the present invention is shown. Specifically:

该计算机设备可以包括射频(RF,Radio Frequency)电路701、包括有一个或一个以上计算机可读存储介质的存储器702、输入单元703、显示单元704、传感器705、音频电路706、无线保真(WiFi,Wireless Fidelity)模块707、包括有一个或者一个以上处理核心的处理器708、以及电源709等部件。本领域技术人员可以理解,图7中示出的计算机设备结构并不构成对计算机设备的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。其中:The computer device may include a radio frequency (RF) circuit 701, a memory 702 including one or more computer-readable storage media, an input unit 703, a display unit 704, a sensor 705, an audio circuit 706, a wireless fidelity (WiFi) module 707, a processor 708 including one or more processing cores, and a power supply 709. Those skilled in the art will appreciate that the computer device structure shown in FIG. 7 does not constitute a limitation on the computer device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange components differently. Among them:

RF电路701可用于收发信息或通话过程中,信号的接收和发送,特别地,将基站的下行信息接收后,交由一个或者一个以上处理器708处理;另外,将涉及上行的数据发送给基站。通常,RF电路701包括但不限于天线、至少一个放大器、调谐器、一个或多个振荡器、用户身份模块(SIM, Subscriber Identity Module)卡、收发信机、耦合器、低噪声放大器(LNA,Low Noise Amplifier)、双工器等。此外,RF电路701还可以通过无线通信与网络和其他设备通信。无线通信可以使用任一通信标准或协议,包括但不限于全球移动通讯系统(GSM,Global System of Mobile communication)、通用分组无线服务(GPRS ,General Packet Radio Service)、码分多址(CDMA,Code Division Multiple Access)、宽带码分多址(WCDMA,Wideband Code Division Multiple Access)、长期演进(LTE,Long Term Evolution)、电子邮件、短消息服务(SMS,Short Messaging Service)等。The RF circuit 701 can be used for receiving and sending signals during information transmission or calls. In particular, after receiving the downlink information of the base station, it is handed over to one or more processors 708 for processing; in addition, the data related to the uplink is sent to the base station. Usually, the RF circuit 701 includes but is not limited to an antenna, at least one amplifier, a tuner, one or more oscillators, a subscriber identity module (SIM) card, a transceiver, a coupler, a low noise amplifier (LNA), a duplexer, etc. In addition, the RF circuit 701 can also communicate with the network and other devices through wireless communication. Wireless communication can use any communication standard or protocol, including but not limited to the Global System of Mobile Communication (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (LTE), email, Short Messaging Service (SMS), etc.

存储器702可用于存储软件程序以及模块,处理器708通过运行存储在存储器702的软件程序以及模块,从而执行各种功能应用以及数据处理。存储器702可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据计算机设备的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器702可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。相应地,存储器702还可以包括存储器控制器,以提供处理器708和输入单元703对存储器702的访问。The memory 702 can be used to store software programs and modules. The processor 708 executes various functional applications and data processing by running the software programs and modules stored in the memory 702. The memory 702 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the computer device (such as audio data, a phone book, etc.), etc. In addition, the memory 702 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices. Accordingly, the memory 702 may also include a memory controller to provide the processor 708 and the input unit 703 with access to the memory 702.

输入单元703可用于接收输入的数字或字符信息,以及产生与用户设置以及功能控制有关的键盘、鼠标、操作杆、光学或者轨迹球信号输入。具体地,在一个具体的实施例中,输入单元703可包括触敏表面以及其他输入设备。触敏表面,也称为触摸显示屏或者触控板,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触敏表面上或在触敏表面附近的操作),并根据预先设定的程式驱动相应的连接装置。可选的,触敏表面可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器708,并能接收处理器708发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触敏表面。除了触敏表面,输入单元703还可以包括其他输入设备。具体地,其他输入设备可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆等中的一种或多种。The input unit 703 can be used to receive input digital or character information, and generate keyboard, mouse, joystick, optical or trackball signal input related to user settings and function control. Specifically, in a specific embodiment, the input unit 703 may include a touch-sensitive surface and other input devices. The touch-sensitive surface, also known as a touch display screen or a touch pad, can collect the user's touch operations on or near it (such as the user's operation on or near the touch-sensitive surface using any suitable object or accessory such as a finger, a stylus, etc.), and drive the corresponding connection device according to a pre-set program. Optionally, the touch-sensitive surface may include a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch direction, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into the touch point coordinates, and then sends it to the processor 708, and can receive and execute the command sent by the processor 708. In addition, the touch-sensitive surface can be implemented using multiple types such as resistive, capacitive, infrared and surface acoustic wave. In addition to the touch-sensitive surface, the input unit 703 may also include other input devices. Specifically, other input devices may include, but are not limited to, one or more of a physical keyboard, function keys (such as a volume control key, a switch key, etc.), a trackball, a mouse, a joystick, and the like.

显示单元704可用于显示由用户输入的信息或提供给用户的信息以及计算机设备的各种图形用户接口,这些图形用户接口可以由图形、文本、图标、视频和其任意组合来构成。显示单元704可包括显示面板,可选的,可以采用液晶显示器(LCD,Liquid Crystal Display)、有机发光二极管(OLED,Organic Light-Emitting Diode)等形式来配置显示面板。进一步的,触敏表面可覆盖显示面板,当触敏表面检测到在其上或附近的触摸操作后,传送给处理器708以确定触摸事件的类型,随后处理器708根据触摸事件的类型在显示面板上提供相应的视觉输出。虽然在图7中,触敏表面与显示面板是作为两个独立的部件来实现输入和输入功能,但是在某些实施例中,可以将触敏表面与显示面板集成而实现输入和输出功能。The display unit 704 can be used to display information input by the user or information provided to the user and various graphical user interfaces of the computer device, which can be composed of graphics, text, icons, videos and any combination thereof. The display unit 704 may include a display panel. Optionally, the display panel may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), etc. Further, the touch-sensitive surface may cover the display panel. When the touch-sensitive surface detects a touch operation on or near it, it is transmitted to the processor 708 to determine the type of touch event, and then the processor 708 provides corresponding visual output on the display panel according to the type of touch event. Although in FIG. 7, the touch-sensitive surface and the display panel are implemented as two independent components to implement input and output functions, in some embodiments, the touch-sensitive surface and the display panel can be integrated to implement input and output functions.

计算机设备还可包括至少一种传感器705,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板的亮度,接近传感器可在计算机设备移动到耳边时,关闭显示面板和/或背光。作为运动传感器的一种,重力加速度传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等; 至于计算机设备还可配置的陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器,在此不再赘述。The computer device may also include at least one sensor 705, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel according to the brightness of the ambient light, and the proximity sensor may turn off the display panel and/or backlight when the computer device is moved to the ear. As a type of motion sensor, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally three axes), and can detect the magnitude and direction of gravity when stationary. It can be used for applications that identify the posture of the mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc.; As for other sensors such as gyroscopes, barometers, hygrometers, thermometers, infrared sensors, etc. that can also be configured in the computer device, they will not be repeated here.

音频电路706、扬声器,传声器可提供用户与计算机设备之间的音频接口。音频电路706可将接收到的音频数据转换后的电信号,传输到扬声器,由扬声器转换为声音信号输出;另一方面,传声器将收集的声音信号转换为电信号,由音频电路706接收后转换为音频数据,再将音频数据输出处理器708处理后,经RF电路701以发送给比如另一计算机设备,或者将音频数据输出至存储器702以便进一步处理。音频电路706还可能包括耳塞插孔,以提供外设耳机与计算机设备的通信。The audio circuit 706, the speaker, and the microphone can provide an audio interface between the user and the computer device. The audio circuit 706 can transmit the electrical signal converted from the received audio data to the speaker, which is converted into a sound signal for output; on the other hand, the microphone converts the collected sound signal into an electrical signal, which is received by the audio circuit 706 and converted into audio data, and then the audio data is output to the processor 708 for processing, and then sent to another computer device through the RF circuit 701, or the audio data is output to the memory 702 for further processing. The audio circuit 706 may also include an earphone jack to provide communication between an external headset and the computer device.

WiFi属于短距离无线传输技术,计算机设备通过WiFi模块707可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图7示出了WiFi模块707,但是可以理解的是,其并不属于计算机设备的必须构成,完全可以根据需要在不改变发明的本质的范围内而省略。WiFi is a short-range wireless transmission technology. Computer devices can help users send and receive emails, browse web pages, and access streaming media through WiFi module 707, which provides users with wireless broadband Internet access. Although FIG. 7 shows WiFi module 707, it is understandable that it is not a necessary component of the computer device and can be omitted as needed without changing the essence of the invention.

处理器708是计算机设备的控制中心,利用各种接口和线路连接整个手机的各个部分,通过运行或执行存储在存储器702内的软件程序和/或模块,以及调用存储在存储器702内的数据,执行计算机设备的各种功能和处理数据。可选的,处理器708可包括一个或多个处理核心;优选的,处理器708可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器708中。The processor 708 is the control center of the computer device, which uses various interfaces and lines to connect various parts of the entire mobile phone, and executes various functions of the computer device and processes data by running or executing software programs and/or modules stored in the memory 702, and calling data stored in the memory 702. Optionally, the processor 708 may include one or more processing cores; preferably, the processor 708 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 708.

计算机设备还包括给各个部件供电的电源709(比如电池),优选的,电源可以通过电源管理系统与处理器708逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。电源709还可以包括一个或一个以上的直流或交流电源、再充电系统、电源故障检测电路、电源转换器或者逆变器、电源状态指示器等任意组件。The computer device also includes a power supply 709 (such as a battery) for supplying power to each component. Preferably, the power supply can be logically connected to the processor 708 through a power management system, so that the power management system can manage charging, discharging, and power consumption management. The power supply 709 can also include one or more DC or AC power supplies, recharging systems, power failure detection circuits, power converters or inverters, power status indicators, and other arbitrary components.

尽管未示出,计算机设备还可以包括摄像头、蓝牙模块等,在此不再赘述。具体在本实施例中,计算机设备中的处理器708会按照如下的指令,将一个或一个以上的应用程序的进程对应的可执行文件加载到存储器702中,并由处理器708来运行存储在存储器702中的应用程序,从而实现各种功能,如下:Although not shown, the computer device may also include a camera, a Bluetooth module, etc., which will not be described in detail here. Specifically in this embodiment, the processor 708 in the computer device will load the executable files corresponding to the processes of one or more application programs into the memory 702 according to the following instructions, and the processor 708 will run the application programs stored in the memory 702 to implement various functions, as follows:

接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息;receiving an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated;

获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到;Acquiring environmental information, wherein the environmental information is collected by a display device that displays the target image;

通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像;Performing data mapping on the environmental information through a preset image generation model to generate a content image corresponding to the environmental information;

从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。Style features are extracted from at least one preset style reference image, and content features are extracted from the content image, and a target image is obtained based on the fusion of the content features and the style features.

本领域普通技术人员可以理解,上述实施例的各种方法中的全部或部分步骤可以通过指令来完成,或通过指令控制相关的硬件来完成,该指令可以存储于一计算机可读存储介质中,并由处理器进行加载和执行。A person of ordinary skill in the art will appreciate that all or part of the steps in the various methods of the above embodiments may be completed by instructions, or by controlling related hardware through instructions. The instructions may be stored in a computer-readable storage medium and loaded and executed by a processor.

为此,本发明实施例提供一种计算机可读存储介质,其中存储有多条指令,该指令能够被处理器进行加载,以执行本发明实施例所提供的任一种图像生成方法中的步骤。例如,该指令可以执行如下步骤:To this end, an embodiment of the present invention provides a computer-readable storage medium, in which a plurality of instructions are stored, and the instructions can be loaded by a processor to execute the steps in any one of the image generation methods provided in the embodiments of the present invention. For example, the instructions can execute the following steps:

接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息;receiving an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated;

获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到;Acquiring environmental information, wherein the environmental information is collected by a display device that displays the target image;

通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像;Performing data mapping on the environmental information through a preset image generation model to generate a content image corresponding to the environmental information;

从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。Style features are extracted from at least one preset style reference image, and content features are extracted from the content image, and a target image is obtained based on the fusion of the content features and the style features.

以上各个操作的具体实施可参见前面的实施例,在此不再赘述。The specific implementation of the above operations can be found in the previous embodiments, which will not be described in detail here.

其中,该计算机可读存储介质可以包括:只读存储器(ROM,Read Only Memory)、随机存取记忆体(RAM,Random Access Memory)、磁盘或光盘等。The computer-readable storage medium may include: a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc.

由于该计算机可读存储介质中所存储的指令,可以执行本发明实施例所提供的任一种图像生成方法中的步骤,因此,可以实现本发明实施例所提供的任一种图像生成方法所能实现的有益效果,详见前面的实施例,在此不再赘述。Since the instructions stored in the computer-readable storage medium can execute the steps in any image generation method provided in the embodiments of the present invention, the beneficial effects that can be achieved by any image generation method provided in the embodiments of the present invention can be achieved. Please refer to the previous embodiments for details and will not be repeated here.

根据本申请的一个方面,还提供了一种计算机程序产品或计算机程序,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行上述实施例中的各种可选实现方式中提供的方法。According to one aspect of the present application, a computer program product or a computer program is also provided, the computer program product or the computer program including computer instructions, the computer instructions being stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the methods provided in various optional implementations in the above-mentioned embodiments.

以上对本发明实施例所提供的一种图像生成方法、装置、计算机设备和存储介质进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。The above is a detailed introduction to an image generation method, device, computer equipment and storage medium provided in an embodiment of the present invention. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.

Claims (20)

一种图像生成方法,其特征在于,包括:A method for generating an image, comprising: 接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息;receiving an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated; 获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到;Acquiring environmental information, wherein the environmental information is collected by a display device that displays the target image; 通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像;Performing data mapping on the environmental information through a preset image generation model to generate a content image corresponding to the environmental information; 从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。Style features are extracted from at least one preset style reference image, and content features are extracted from the content image, and a target image is obtained based on the fusion of the content features and the style features. 根据权利要求1所述的图像生成方法,其特征在于,所述通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像之前,所述方法还包括:The image generation method according to claim 1, characterized in that before performing data mapping on the environmental information through a preset image generation model to generate a content image corresponding to the environmental information, the method further comprises: 获取待训练的生成对抗模型,所述生成对抗模型包括待训练的图像生成模型和待训练的判别模型,所述生成对抗模型设置有至少一张真实内容样本图像;Obtaining a generative adversarial model to be trained, wherein the generative adversarial model includes an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image; 通过所述待训练的图像生成模型对训练输入参数进行数据映射,生成所述训练输入参数对应的训练内容图像;Performing data mapping on the training input parameters through the image generation model to be trained to generate a training content image corresponding to the training input parameters; 通过所述待训练的判别模型计算所述训练内容图像相对于所述真实内容样本图像的真实度参数;Calculating the authenticity parameter of the training content image relative to the real content sample image by using the discriminant model to be trained; 基于所述真实度参数对所述待训练的图像生成模型和所述待训练的判别模型进行调整;Adjusting the image generation model to be trained and the discriminant model to be trained based on the truthfulness parameter; 返回执行所述通过所述待训练的图像生成模型对训练输入参数进行数据映射的步骤,直至满足预设的训练结束条件,得到训练后的图像生成模型。Return to execute the step of performing data mapping on the training input parameters through the image generation model to be trained until a preset training end condition is met, thereby obtaining a trained image generation model. 根据权利要求2所述的图像生成方法,其特征在于,所述通过所述待训练的图像生成模型对训练输入参数进行数据映射,生成所述训练输入参数对应的训练内容图像之前,所述方法还包括:The image generation method according to claim 2 is characterized in that, before performing data mapping on the training input parameters through the image generation model to be trained to generate the training content image corresponding to the training input parameters, the method further comprises: 获取所述显示设备的显示参数;Acquire display parameters of the display device; 基于所述显示参数,对所述待训练的图像生成模型的模型参数进行设置,得到新的待训练的图像生成模型。Based on the display parameters, the model parameters of the image generation model to be trained are set to obtain a new image generation model to be trained. 根据权利要求1所述的图像生成方法,其特征在于,所述从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,包括:The image generation method according to claim 1, characterized in that extracting style features from at least one preset style reference image and extracting content features from the content image include: 根据风格迁移模型中风格提取层的风格特征映射参数,对预设的至少一张风格参考图像进行风格特征提取,得到所述风格参考图像对应的风格特征;Extracting style features from at least one preset style reference image according to style feature mapping parameters of a style extraction layer in a style transfer model to obtain style features corresponding to the style reference image; 根据所述风格迁移模型中内容提取层的内容特征映射参数,对所述内容图像进行内容特征提取,得到所述内容图像对应的内容特征。According to the content feature mapping parameters of the content extraction layer in the style transfer model, content features are extracted from the content image to obtain content features corresponding to the content image. 根据权利要求1所述的图像生成方法,其特征在于,所述根据风格迁移模型中风格提取层的风格特征映射参数,对预设的至少一张风格参考图像进行风格特征提取,得到所述风格参考图像对应的风格特征之前,所述方法还包括:The image generation method according to claim 1 is characterized in that, before extracting style features from at least one preset style reference image according to the style feature mapping parameters of the style extraction layer in the style transfer model to obtain the style features corresponding to the style reference image, the method further comprises: 通过待训练的风格迁移模型,对样本风格参考图像进行风格特征提取,得到所述样本风格参考图像对应的样本风格特征;By using the style transfer model to be trained, style features are extracted from the sample style reference image to obtain sample style features corresponding to the sample style reference image; 通过所述待训练的风格迁移模型,对样本内容图像进行内容特征提取,得到所述样本内容图像对应的样本内容特征;Extracting content features of the sample content image by using the style transfer model to be trained to obtain sample content features corresponding to the sample content image; 针对所述样本风格特征和所述样本内容特征进行特征融合,得到样本风格迁移图像;Performing feature fusion on the sample style feature and the sample content feature to obtain a sample style transfer image; 基于所述样本风格迁移图像、所述样本风格参考图像和所述样本内容图像,计算所述待训练的风格迁移模型的模型损失;Calculating a model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image; 根据所述模型损失,对所述待训练的风格迁移模型的模型参数进行调整,得到训练后的风格迁移模型。According to the model loss, the model parameters of the style transfer model to be trained are adjusted to obtain a trained style transfer model. 根据权利要求5所述的图像生成方法,其特征在于,所述基于所述样本风格迁移图像、所述样本风格参考图像和所述样本内容图像,计算所述待训练的风格迁移模型的模型损失,包括:The image generation method according to claim 5, characterized in that the step of calculating the model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image comprises: 计算样本风格迁移图像和样本风格参考图像之间的风格相似度,作为待训练的风格迁移模型的风格损失;Calculate the style similarity between the sample style transfer image and the sample style reference image as the style loss of the style transfer model to be trained; 计算样本风格迁移图像和样本内容图像之间的内容相似度,计算作为待训练的风格迁移模型的内容损失;Calculate the content similarity between the sample style transfer image and the sample content image, and calculate the content loss of the style transfer model to be trained; 基于风格损失和内容损失,计算待训练的风格迁移模型的模型损失。Based on the style loss and content loss, the model loss of the style transfer model to be trained is calculated. 根据权利要求1所述的图像生成方法,其特征在于,所述获取环境信息,包括:The image generation method according to claim 1, characterized in that the obtaining of environmental information comprises: 通过显示设备采集环境声音音频;Collect environmental sound audio through display devices; 将所述环境声音音频转化为所述图像生成模型的模型输入格式,得到环境信息。The environmental sound audio is converted into a model input format of the image generation model to obtain environmental information. 根据权利要求1所述的图像生成方法,其特征在于,所述获取环境信息,包括:The image generation method according to claim 1, characterized in that the obtaining of environmental information comprises: 通过显示设备采集环境声音音频,得到环境声音信息;Collecting ambient sound audio through a display device to obtain ambient sound information; 获取所述显示设备对应的环境天气信息;Obtaining environmental weather information corresponding to the display device; 对所述环境声音信息和所述环境天气信息进行融合,生成融合后环境信息;Fusing the ambient sound information and the ambient weather information to generate fused ambient information; 将所述融合后环境信息转化为所述图像生成模型的模型输入格式,得到环境信息。The fused environmental information is converted into a model input format of the image generation model to obtain environmental information. 根据权利要求1所述的图像生成方法,其特征在于,所述图像属性信息包括图像风格类型,所述从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像,包括:The image generation method according to claim 1, characterized in that the image attribute information includes an image style type, the extracting style features from at least one preset style reference image, and extracting content features from the content image, and obtaining a target image based on a fusion of the content features and the style features, comprises: 从预设的至少一张风格参考图像中,选择至少一张所述图像风格类型对应的目标风格参考图像;Selecting at least one target style reference image corresponding to the image style type from at least one preset style reference image; 针对各所述目标风格参考图像提取风格特征,以及从所述内容图像中提取内容特征;Extracting style features for each of the target style reference images, and extracting content features from the content images; 将所述内容特征和所述风格特征进行加权融合,得到目标图像。The content features and the style features are weightedly fused to obtain a target image. 一种图像生成装置,其特征在于,包括:An image generating device, comprising: 指令接收单元,用于接收图像生成指令,所述图像生成指令包括需要生成的目标图像的图像属性信息;An instruction receiving unit, used for receiving an image generation instruction, wherein the image generation instruction includes image attribute information of a target image to be generated; 环境信息获取单元,用于获取环境信息,所述环境信息通过显示所述目标图像的显示设备进行收集得到;An environmental information acquisition unit, used to acquire environmental information, wherein the environmental information is collected by a display device that displays the target image; 内容图像生成单元,用于通过预设的图像生成模型对所述环境信息进行数据映射,生成所述环境信息对应的内容图像;A content image generating unit, configured to perform data mapping on the environmental information through a preset image generating model, and generate a content image corresponding to the environmental information; 目标图像生成单元,用于从预设的至少一张风格参考图像中提取风格特征,以及从所述内容图像中提取内容特征,基于对所述内容特征和所述风格特征的融合,得到目标图像。The target image generation unit is used to extract style features from at least one preset style reference image and content features from the content image, and obtain the target image based on the fusion of the content features and the style features. 根据权利要求10所述的图像生成装置,其特征在于,所述图像生成装置还包括图像生成模型训练单元,用于获取待训练的生成对抗模型,所述生成对抗模型包括待训练的图像生成模型和待训练的判别模型,所述生成对抗模型设置有至少一张真实内容样本图像;The image generation device according to claim 10, characterized in that the image generation device further comprises an image generation model training unit, which is used to obtain a generative adversarial model to be trained, wherein the generative adversarial model comprises an image generation model to be trained and a discriminant model to be trained, and the generative adversarial model is provided with at least one real content sample image; 通过所述待训练的图像生成模型对训练输入参数进行数据映射,生成所述训练输入参数对应的训练内容图像;Performing data mapping on the training input parameters through the image generation model to be trained to generate a training content image corresponding to the training input parameters; 通过所述待训练的判别模型计算所述训练内容图像相对于所述真实内容样本图像的真实度参数;Calculating the authenticity parameter of the training content image relative to the real content sample image by using the discriminant model to be trained; 基于所述真实度参数对所述待训练的图像生成模型和所述待训练的判别模型进行调整;Adjusting the image generation model to be trained and the discriminant model to be trained based on the truthfulness parameter; 返回执行所述通过所述待训练的图像生成模型对训练输入参数进行数据映射的步骤,直至满足预设的训练结束条件,得到训练后的图像生成模型。Return to execute the step of performing data mapping on the training input parameters through the image generation model to be trained until a preset training end condition is met, thereby obtaining a trained image generation model. 根据权利要求11所述的图像生成装置,其特征在于,所述图像生成装置还包括图像生成模型设置单元,用于获取所述显示设备的显示参数;The image generating device according to claim 11, characterized in that the image generating device further comprises an image generating model setting unit, which is used to obtain display parameters of the display device; 基于所述显示参数,对所述待训练的图像生成模型的模型参数进行设置,得到新的待训练的图像生成模型。Based on the display parameters, the model parameters of the image generation model to be trained are set to obtain a new image generation model to be trained. 根据权利要求10所述的图像生成装置,其特征在于,所述目标图像生成单元,用于根据风格迁移模型中风格提取层的风格特征映射参数,对预设的至少一张风格参考图像进行风格特征提取,得到所述风格参考图像对应的风格特征;The image generation device according to claim 10, characterized in that the target image generation unit is used to extract style features from at least one preset style reference image according to the style feature mapping parameters of the style extraction layer in the style transfer model to obtain the style features corresponding to the style reference image; 根据所述风格迁移模型中内容提取层的内容特征映射参数,对所述内容图像进行内容特征提取,得到所述内容图像对应的内容特征。According to the content feature mapping parameters of the content extraction layer in the style transfer model, content features are extracted from the content image to obtain content features corresponding to the content image. 根据权利要求10所述的图像生成装置,其特征在于,所述图像生成装置还包括风格迁移模型训练单元,用于通过待训练的风格迁移模型,对样本风格参考图像进行风格特征提取,得到所述样本风格参考图像对应的样本风格特征;The image generation device according to claim 10, characterized in that the image generation device further comprises a style transfer model training unit, configured to extract style features from the sample style reference image through the style transfer model to be trained, so as to obtain the sample style features corresponding to the sample style reference image; 通过所述待训练的风格迁移模型,对样本内容图像进行内容特征提取,得到所述样本内容图像对应的样本内容特征;Extracting content features of the sample content image by using the style transfer model to be trained to obtain sample content features corresponding to the sample content image; 针对所述样本风格特征和所述样本内容特征进行特征融合,得到样本风格迁移图像;Performing feature fusion on the sample style feature and the sample content feature to obtain a sample style transfer image; 基于所述样本风格迁移图像、所述样本风格参考图像和所述样本内容图像,计算所述待训练的风格迁移模型的模型损失;Calculating a model loss of the style transfer model to be trained based on the sample style transfer image, the sample style reference image and the sample content image; 根据所述模型损失,对所述待训练的风格迁移模型的模型参数进行调整,得到训练后的风格迁移模型。According to the model loss, the model parameters of the style transfer model to be trained are adjusted to obtain a trained style transfer model. 根据权利要求14所述的图像生成装置,其特征在于,所述风格迁移模型训练单元,用于计算样本风格迁移图像和样本风格参考图像之间的风格相似度,作为待训练的风格迁移模型的风格损失;The image generation device according to claim 14, characterized in that the style transfer model training unit is used to calculate the style similarity between the sample style transfer image and the sample style reference image as the style loss of the style transfer model to be trained; 计算样本风格迁移图像和样本内容图像之间的内容相似度,计算作为待训练的风格迁移模型的内容损失;Calculate the content similarity between the sample style transfer image and the sample content image, and calculate the content loss of the style transfer model to be trained; 基于风格损失和内容损失,计算待训练的风格迁移模型的模型损失。Based on the style loss and content loss, the model loss of the style transfer model to be trained is calculated. 根据权利要求10所述的图像生成装置,其特征在于,所述环境信息获取单元,用于通过显示设备采集环境声音音频;The image generating device according to claim 10, characterized in that the environmental information acquisition unit is used to collect environmental sound audio through a display device; 将所述环境声音音频转化为所述图像生成模型的模型输入格式,得到环境信息。The environmental sound audio is converted into a model input format of the image generation model to obtain environmental information. 根据权利要求10所述的图像生成装置,其特征在于,所述环境信息获取单元,用于通过显示设备采集环境声音音频,得到环境声音信息;The image generation device according to claim 10, characterized in that the environmental information acquisition unit is used to collect environmental sound audio through a display device to obtain environmental sound information; 获取所述显示设备对应的环境天气信息;Obtaining environmental weather information corresponding to the display device; 对所述环境声音信息和所述环境天气信息进行融合,生成融合后环境信息;Fusing the ambient sound information and the ambient weather information to generate fused ambient information; 将所述融合后环境信息转化为所述图像生成模型的模型输入格式,得到环境信息。The fused environmental information is converted into a model input format of the image generation model to obtain environmental information. 根据权利要求10所述的图像生成装置,其特征在于,所述目标图像生成单元,用于从预设的至少一张风格参考图像中,选择至少一张所述图像风格类型对应的目标风格参考图像;The image generation device according to claim 10, characterized in that the target image generation unit is used to select at least one target style reference image corresponding to the image style type from at least one preset style reference image; 针对各所述目标风格参考图像提取风格特征,以及从所述内容图像中提取内容特征;Extracting style features for each of the target style reference images, and extracting content features from the content images; 将所述内容特征和所述风格特征进行加权融合,得到目标图像。The content features and the style features are weightedly fused to obtain a target image. 一种计算机设备,其特征在于,包括存储器和处理器;所述存储器存储有应用程序,所述处理器用于运行所述存储器内的应用程序,以执行权利要求1至9任一项所述的图像生成方法中的步骤。A computer device, characterized in that it includes a memory and a processor; the memory stores an application program, and the processor is used to run the application program in the memory to execute the steps in the image generation method described in any one of claims 1 to 9. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有多条指令,所述指令适于处理器进行加载,以执行权利要求1至9任一项所述的图像生成方法中的步骤。A computer-readable storage medium, characterized in that the computer-readable storage medium stores a plurality of instructions, wherein the instructions are suitable for a processor to load to execute the steps in the image generation method according to any one of claims 1 to 9.
PCT/CN2022/144264 2022-12-30 2022-12-30 Image generation method and apparatus, and computer device and storage medium Ceased WO2024138720A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/144264 WO2024138720A1 (en) 2022-12-30 2022-12-30 Image generation method and apparatus, and computer device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/144264 WO2024138720A1 (en) 2022-12-30 2022-12-30 Image generation method and apparatus, and computer device and storage medium

Publications (1)

Publication Number Publication Date
WO2024138720A1 true WO2024138720A1 (en) 2024-07-04

Family

ID=91716303

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/144264 Ceased WO2024138720A1 (en) 2022-12-30 2022-12-30 Image generation method and apparatus, and computer device and storage medium

Country Status (1)

Country Link
WO (1) WO2024138720A1 (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106847294A (en) * 2017-01-17 2017-06-13 百度在线网络技术(北京)有限公司 Audio-frequency processing method and device based on artificial intelligence
CN112840398A (en) * 2018-10-19 2021-05-25 微软技术许可有限责任公司 Convert audio content to image
CN113724132A (en) * 2021-11-03 2021-11-30 浙江宇视科技有限公司 Image style migration processing method and device, electronic equipment and storage medium
WO2022022001A1 (en) * 2020-07-27 2022-02-03 百果园技术(新加坡)有限公司 Method for compressing style transfer network, and style transfer method, apparatus and system
CN115019269A (en) * 2022-05-30 2022-09-06 广州文远知行科技有限公司 An environment recognition model training method, driving control method and related device
CN115170390A (en) * 2022-08-31 2022-10-11 广州极尚网络技术有限公司 File stylization method, device, equipment and storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106847294A (en) * 2017-01-17 2017-06-13 百度在线网络技术(北京)有限公司 Audio-frequency processing method and device based on artificial intelligence
CN112840398A (en) * 2018-10-19 2021-05-25 微软技术许可有限责任公司 Convert audio content to image
WO2022022001A1 (en) * 2020-07-27 2022-02-03 百果园技术(新加坡)有限公司 Method for compressing style transfer network, and style transfer method, apparatus and system
CN113724132A (en) * 2021-11-03 2021-11-30 浙江宇视科技有限公司 Image style migration processing method and device, electronic equipment and storage medium
CN115019269A (en) * 2022-05-30 2022-09-06 广州文远知行科技有限公司 An environment recognition model training method, driving control method and related device
CN115170390A (en) * 2022-08-31 2022-10-11 广州极尚网络技术有限公司 File stylization method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN107817939B (en) Image processing method and mobile terminal
CN110032309B (en) Screen splitting method and terminal equipment
JP2021516374A (en) Image processing method and flexible screen terminal
US9760998B2 (en) Video processing method and apparatus
CN108668024B (en) Voice processing method and terminal
US10675541B2 (en) Control method of scene sound effect and related products
CN107908765B (en) A game resource processing method, mobile terminal and server
CN111147919A (en) Play adjustment method, electronic equipment and computer readable storage medium
CN109189303B (en) Text editing method and mobile terminal
CN111461985A (en) Image processing method and electronic device
US20220318076A1 (en) Application sharing method, first electronic device, and computer-readable storage medium
CN110913261A (en) Multimedia file generation method and electronic equipment
CN111158815B (en) Dynamic wallpaper blurring method, terminal and computer readable storage medium
CN108495036B (en) An image processing method and mobile terminal
CN108600079A (en) A chat record display method and mobile terminal
CN107729100B (en) A kind of interface display control method and mobile terminal
CN110471895B (en) Sharing method and terminal device
CN109101151A (en) A kind of information display processing method and terminal device
CN114415893B (en) Image display method and device, electronic equipment and storage medium
CN113240779B (en) Method and device for generating text special effects, electronic equipment and storage medium
CN110519544B (en) A video call method and electronic device
CN111324263B (en) Screen capture method, electronic equipment and computer readable storage medium
CN111142759B (en) Information sending method and electronic equipment
CN110213437B (en) An editing method and mobile terminal
CN105320532B (en) Method, device and terminal for displaying interactive interface

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22969862

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE