Smart card surface pattern customization method, device, electronic device and medium

By using the image style migration model in bank card pattern customization, the user-specified style pictures and content pictures are integrated to generate target patterns, which solves the problem that the existing technology cannot integrate multiple picture styles, and realizes diversified card pattern customization and improves the user experience.

CN114463466BActive Publication Date: 2025-03-18INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210123262.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-02-09
Publication Date
2025-03-18
Estimated Expiration
2042-02-09

AI Technical Summary

Technical Problem

The existing bank card card pattern customization technology cannot integrate the style of multiple pictures, resulting in users being unable to generate diverse card pattern.

Method used

By receiving the user's card pattern customization request, including the style pictures and content pictures specified by the user, input them into the trained picture style migration model, output the target pattern after the style is converted, and create a smart card based on the user's confirmation.

Benefits of technology

It integrates pattern information of multiple pictures, increases the diversity of picture styles, and enables users to intelligently customize their favorite card pattern, improving user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114463466B_ABST
    Figure CN114463466B_ABST
Patent Text Reader

Abstract

The present disclosure provides a method for customizing a smart card face pattern, and relates to the field of artificial intelligence technology. The method comprises: receiving a card face pattern customization request sent by a user, the card face pattern customization request comprising a style picture and a content picture specified by the user; inputting the style picture and the content picture into a trained picture style transfer model, and outputting a target pattern after style conversion of the content picture according to the style picture; and using the target pattern as a card face pattern to make a smart card after confirmation by the user. The present disclosure also provides a smart card face pattern customization device, equipment, storage medium and program product.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of artificial intelligence technology, specifically to the field of image recognition, and more specifically to a method, device, electronic device and medium for customizing a smart card surface pattern. Background Art

[0002] Currently, when a user applies for a bank card, there are two options for the bank card face: one is a fixed pattern; the other is a pattern selected by the user as the bank card face pattern.

[0003] However, in the existing bank card surface pattern customization technology, although users can use their favorite patterns as bank card surface patterns, they cannot merge the styles of multiple patterns to generate a new pattern. For example, a user likes the photography style of a certain photographer and wants to merge one of his own photos into the style of the photographer's photos, so that the customized bank card surface pattern information content is more diverse. The traditional bank card surface pattern customization technology cannot meet user needs and cannot provide users with rich visual information. Summary of the invention

[0004] In order to overcome the deficiency of the existing bank card surface pattern customization technology that is unable to integrate multiple picture style information, the present disclosure provides a smart card surface pattern customization method, device, electronic device and medium.

[0005] According to a first aspect of the present disclosure, a method for customizing a smart card face pattern is provided, comprising: receiving a card face pattern customization request sent by a user, the card face pattern customization request including a style image and a content image specified by the user; inputting the style image and the content image into a trained image style transfer model, and outputting a target pattern after style conversion of the content image according to the style image; and using the target pattern as a card face pattern to produce a smart card after confirmation by the user.

[0006] According to an embodiment of the present disclosure, a picture style transfer model is constructed in sequence by an encoder network model, an adaptive instance normalization layer and a decoder network model, wherein: the encoder network model adopts a VGG-19 convolutional neural network structure and adds three hole convolution structures with different dilation rates to the VGG-19 convolutional neural network structure in parallel; the adaptive instance normalization layer is used to perform instance normalization on features passing through the encoder; the network structure of the decoder network model is symmetrical to that of the encoder network model.

[0007] According to an embodiment of the present disclosure, the encoder network model includes 15 convolutional layers, 5 pooling layers, 3 dilated convolutional layers, 3 fully connected layers and 1 softmax classifier. The 3 dilated convolutional layers are arranged in parallel between the 9th convolutional layer and the 10th convolutional layer. Each convolutional layer, dilated convolutional layer and fully connected layer is followed by a ReLU activation function.

[0008] According to an embodiment of the present disclosure, the encoder network model is trained in the following manner: obtaining a first image data set including multiple first style pictures and first content pictures, preprocessing the first image data set, and randomly splitting the preprocessed first image data set into a training set and a verification set; converting the training set to a preset format and inputting it into the encoder network model for feature encoding, and using the Adam gradient descent algorithm to train the encoder network model to obtain a trained encoder network model.

[0009] According to an embodiment of the present disclosure, preprocessing the first image data set includes: scaling the first image data set to a preset size; and performing blur processing, lighting adjustment, or rotation operations on the first image data set of the preset size.

[0010] According to an embodiment of the present disclosure, the ReLU activation function attached to the 12th convolutional layer in the encoder network model is connected to an adaptive instance normalization layer.

[0011] According to an embodiment of the present disclosure, the decoder network model adopts a symmetrical network structure before the ReLU activation function attached to the 12th convolutional layer in the encoder network model, and replaces the pooling layers in the encoder network model with upsampling layers.

[0012] According to an embodiment of the present disclosure, a picture style transfer model is trained in the following manner: obtaining a second image data set including multiple second style pictures and second content pictures, preprocessing the second image data set, and randomly splitting the preprocessed second image data set into a training set and a validation set; converting the training set to a preset format and inputting it into an encoder network model for feature encoding, and using the Adam gradient descent algorithm to train the encoder network model to obtain a trained encoder network model.

[0013] According to an embodiment of the present disclosure, the number of content pictures specified by the user is multiple.

[0014] A second aspect of the present disclosure provides a device for customizing a smart card face pattern, comprising: a customization request module, used to receive a card face pattern customization request sent by a user, the card face pattern customization request including a style image and a content image specified by the user; a style conversion module, used to input the style image and the content image into a trained image style transfer model, and output a target pattern after the content image is style-converted according to the style image; and a pattern production module, used to use the target pattern as a card face pattern to produce a smart card after confirmation by the user.

[0015] The third aspect of the present disclosure provides an electronic device, comprising: one or more processors; a memory for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the above-mentioned smart card face pattern customization method.

[0016] The fourth aspect of the present disclosure further provides a computer-readable storage medium having executable instructions stored thereon, which, when executed by a processor, causes the processor to execute the above-mentioned smart card surface pattern customization method.

[0017] The fifth aspect of the present disclosure also provides a computer program product, including a computer program, which implements the above-mentioned smart card surface pattern customization method when executed by a processor.

[0018] Compared with the prior art, the method, device, electronic device and medium for customizing the smart card surface pattern provided by the present disclosure have at least the following beneficial effects:

[0019] (1) The present invention can integrate the pattern information of multiple pictures, increase the diversity of picture styles, enable users to intelligently customize their favorite card surface patterns, and enhance the user experience.

[0020] (2) This paper builds and trains a deep learning image style transfer network model. The model only needs to be trained once to transfer images of various styles. The image style transfer network model merges the content image with the style image, so that the style of the final generated image is no longer a single style. The image presents a diversified image style to meet the image needs of different people. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] The above contents and other objects, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:

[0022] Figure 1 A diagram schematically shows an application scenario of a method and device for customizing a smart card face pattern according to an embodiment of the present disclosure;

[0023] Figure 2A flowchart of a method for customizing a smart card surface pattern according to an embodiment of the present disclosure is schematically shown;

[0024] Figure 3 The following schematically shows a flow chart of building a picture style transfer model according to an embodiment of the present disclosure;

[0025] Figure 4 A network structure diagram of an encoder network model according to an embodiment of the present disclosure is schematically shown;

[0026] Figure 5 The flowchart of the training method of the encoder network model according to the embodiment of the present disclosure is schematically shown;

[0027] Figure 6 A flowchart of image data set preprocessing according to an embodiment of the present disclosure is schematically shown;

[0028] Figure 7 A network structure diagram of a decoder network model according to an embodiment of the present disclosure is schematically shown;

[0029] Figure 8 A flowchart of a method for training a picture style transfer model according to an embodiment of the present disclosure is schematically shown;

[0030] Fig. 9 The structure block diagram of the device for customizing the card surface pattern of a smart card according to an embodiment of the present disclosure is schematically shown;

[0031] Fig.10 A block diagram of an electronic device suitable for implementing a method for customizing a smart card surface pattern according to an embodiment of the present disclosure is schematically shown. DETAILED DESCRIPTION

[0032] Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present disclosure. In the following detailed description, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of the embodiments of the present disclosure. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, descriptions of known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present disclosure.

[0033] The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The terms "comprise", "include", etc. used herein indicate the existence of the features, steps, operations and / or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.

[0034] All terms (including technical and scientific terms) used herein have the meanings commonly understood by those skilled in the art unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification and should not be interpreted in an idealized or overly rigid manner.

[0035] When using expressions such as "at least one of A, B, and C, etc.", they should generally be interpreted according to the meaning of the expression commonly understood by those skilled in the art (for example, "a system having at least one of A, B, and C" should include but is not limited to a system having A alone, B alone, C alone, A and B, A and C, B and C, and / or A, B, C, etc.).

[0036] In the technical solution disclosed in the present invention, the acquisition, storage and application of user personal information involved are in compliance with the provisions of relevant laws and regulations, necessary confidentiality measures are taken, and do not violate public order and good morals.

[0037] The embodiments of the present disclosure provide a method, device, electronic device and medium for customizing the card face pattern of a smart card, which relates to the field of artificial intelligence technology. The method includes: receiving a card face pattern customization request sent by a user, the card face pattern customization request includes a style picture and a content picture specified by the user; inputting the style picture and the content picture into a trained picture style transfer model, outputting a target pattern after the content picture is style-converted according to the style picture; and using the target pattern as the card face pattern to make a smart card after confirmation by the user.

[0038] Figure 1 The following schematically shows an application scenario of the method and device for customizing the smart card surface pattern according to an embodiment of the present disclosure.

[0039] like Figure 1 As shown, the application scenario 100 according to this embodiment may include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 is used to provide a medium for a communication link between the terminal devices 101, 102, 103 and the server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0040] Users can use terminal devices 101, 102, 103 to interact with server 105 through network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, 103, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only examples).

[0041] The terminal devices 101 , 102 , and 103 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers.

[0042] The server 105 may be a server that provides various services, such as a background management server (only as an example) that provides support for websites browsed by users using the terminal devices 101, 102, and 103. The background management server may analyze and process the received data such as user requests, and feed back the processing results (such as web pages, information, or data obtained or generated according to user requests) to the terminal device.

[0043] It should be noted that the smart card face pattern customization method provided in the embodiment of the present disclosure can generally be executed by the server 105. Accordingly, the smart card face pattern customization device provided in the embodiment of the present disclosure can generally be set in the server 105. The smart card face pattern customization method provided in the embodiment of the present disclosure can also be executed by a server or server cluster that is different from the server 105 and can communicate with the terminal devices 101, 102, 103 and / or the server 105. Accordingly, the smart card face pattern customization device provided in the embodiment of the present disclosure can also be set in a server or server cluster that is different from the server 105 and can communicate with the terminal devices 101, 102, 103 and / or the server 105.

[0044] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.

[0045] The following will be based on Figure 1 The application scenario described by Figure 2~Figure 8 The method for customizing the smart card surface pattern of the disclosed embodiment is described in detail.

[0046] Figure 2 The flowchart of the method for customizing the smart card surface pattern according to the embodiment of the present disclosure is schematically shown.

[0047] like Figure 2 As shown, the method for customizing the smart card surface pattern of this embodiment may include operations S210 to S230, and the smart card may include, for example, a bank card or a membership card.

[0048] In operation S210, a card surface pattern customization request sent by a user is received, where the card surface pattern customization request includes a style picture and a content picture specified by the user.

[0049] The card face pattern customization request may be pattern customization information uploaded by the user on the customization client. At this time, the style picture and content picture may be built into the customization client, and the customization client may provide a picture library containing a variety of pictures for the user to choose from, or the user may customize the card face pattern and upload it to the customization client to customize the card face pattern in a personalized manner.

[0050] In operation S220, the style image and the content image are input into a trained image style transfer model, and a target pattern is outputted after the style of the content image is converted according to the style image.

[0051] The image style transfer model can convert the original image into a preset style to generate the target pattern required by the user.

[0052] In operation S230, the target pattern is used as a card surface pattern to produce a smart card after confirmation by the user.

[0053] The image output by the model is transferred to the customized client. The user needs to review and confirm the target pattern generated by the image style transfer model. After successful confirmation, the customized client will use the target pattern as the card surface pattern of the smart card.

[0054] Through the embodiments of the present disclosure, the pattern information of multiple pictures can be integrated to increase the diversity of picture styles, so that users can intelligently customize their favorite card surface patterns, thereby improving the user experience.

[0055] Figure 3 The following schematically shows a flow chart for building a picture style transfer model according to an embodiment of the present disclosure. Figure 4 The network structure diagram of the encoder network model according to an embodiment of the present disclosure is schematically shown.

[0056] like Figure 3 and Figure 4 As shown in the figure, the image style transfer model is built by the encoder network model, the adaptive instance normalization layer and the decoder network model in sequence. The encoder network model encodes the input style image and content image, and then inputs the encoded style features and content features into the adaptive instance normalization layer for instance normalization. The decoder network model uses a symmetrical network structure similar to the encoder network model to convert the feature space into the image space and generate a stylized feature image.

[0057] Among them, the encoder network model adopts the VGG-19 convolutional neural network structure and adds three dilated convolution structures with different expansion rates to the VGG-19 convolutional neural network structure in parallel. Therefore, the encoder network model is built based on the VGG-19 convolutional neural network, and three dilated convolution structures with different expansion rates are added to the VGG-19 convolutional neural network. The feature maps obtained by the three different dilated convolutions are fused with the upper layer output, which can increase context information and improve the network's feature learning ability.

[0058] The adaptive instance normalization layer is used to perform instance normalization on the features passed through the encoder. The network structure of the decoder network model is symmetrical to that of the encoder network model.

[0059] Continue as Figure 4 As shown in the figure, the encoder network model includes 15 convolutional layers, 5 pooling layers, 3 dilated convolutional layers, 3 fully connected layers and 1 softmax classifier. The 3 dilated convolutional layers are set in parallel between the 9th convolutional layer and the 10th convolutional layer. Each convolutional layer, dilated convolutional layer and fully connected layer is followed by a ReLU activation function.

[0060] Specifically, first, the convolutional layers are arranged in the order of sequence, the first convolutional layer is attached with the first ReLU activation function, the second convolutional layer is attached with the second ReLU activation function and the first pooling layer is attached after the second ReLU activation function, the third convolutional layer is attached with the third ReLU activation function, the fourth convolutional layer is attached with the fourth ReLU activation function and the second pooling layer is attached after the fourth ReLU activation function, the fifth convolutional layer is attached with the fifth ReLU activation function, the sixth convolutional layer is attached with the sixth ReLU activation function, the seventh convolutional layer is attached with the seventh ReLU activation function, the eighth convolutional layer is attached with the eighth ReLU activation function and the third pooling layer is attached after the eighth ReLU activation function, and the ninth convolutional layer is attached with the ninth ReLU activation function. In particular, the 1st atrous convolution layer, the 2nd atrous convolution layer and the 3rd atrous convolution layer are added in parallel between the 9th ReLU activation function and the 10th convolution layer, the 10th ReLU activation function is attached to the back of the 1st atrous convolution layer, the 11th ReLU activation function is attached to the back of the 2nd atrous convolution layer, and the 12th ReLU activation function is attached to the back of the 3rd atrous convolution layer. Then, the 13th ReLU activation function is attached to the 10th convolution layer, the 14th ReLU activation function is attached to the 11th convolution layer and the 4th pooling layer is attached to the 14th ReLU activation function, the 15th ReLU activation function is attached to the 12th convolution layer, the 16th ReLU activation function is attached to the 13th convolution layer, the 17th ReLU activation function is attached to the 14th convolution layer, the 18th ReLU activation function is attached to the 15th convolution layer and the 5th pooling layer is attached to the 18th ReLU activation function. Finally, the 5th pooling layer is connected to the 1st fully connected layer and the 19th ReLU activation function is attached to the 1st fully connected layer, the 20th ReLU activation function is attached to the 2nd fully connected layer, the 21st ReLU activation function is attached to the 3rd fully connected layer, and finally connected to a softmax classifier, thus forming a complete encoder network model.

[0061] Optionally, the dilation rates of the dilated convolution structure can be set to 1, 2, and 5, for example, respectively.

[0062] Therefore, this embodiment changes a convolutional layer of the VGG-19 convolutional neural network into a dilated convolution structure with three dilation rates, uses dilated convolutions with three dilation rates of 1, 2, and 5 to operate in parallel, and fuses the feature maps obtained by the dilated convolution layers with these three different dilation rates with the upper layer output, which can further increase the contextual information and improve the feature learning ability of the network.

[0063] After building the encoder network model, start training the model. Figure 5 A flow chart of a training method for an encoder network model according to an embodiment of the present disclosure is schematically shown.

[0064] like Figure 5 As shown, the training method of the encoder network model of this embodiment may include operations S510 to S520.

[0065] In operation S510, a first image data set including a plurality of first style images and first content images is obtained, the first image data set is preprocessed, and the preprocessed first image data set is randomly split into a training set and a validation set.

[0066] In operation S520, the training set is converted into a preset format and then input into the encoder network model for feature encoding. The encoder network model is trained using the Adam gradient descent algorithm to obtain a trained encoder network model.

[0067] Through the embodiments of the present disclosure, the constructed model is trained by using a public data set for collecting image classification to obtain a trained encoder network model.

[0068] Figure 6 The flowchart of image dataset preprocessing according to an embodiment of the present disclosure is schematically shown.

[0069] like Figure 6 As shown, the preprocessing of the first image data set in the above operation S510 may include operations S5101 to S5102.

[0070] In operation S5101, the first image data set is scaled to a preset size.

[0071] Optionally, the preset size is 256×256. Therefore, the image size of the collected first image data set is normalized to 256×256.

[0072] In operation S5102, blur processing, illumination adjustment or rotation operation is performed on the first image data set of a preset size.

[0073] Blurring, illumination adjustment or rotation operations are all considered as image data enhancement operations, and one or more combinations thereof may be used according to actual needs.

[0074] Optionally, the preset format is a tfrecord file format. The images in the first image data set are converted into a tfrecord file format, which can be quickly loaded into the memory, thereby saving the training time of the encoder network model.

[0075] In the disclosed embodiment, the 15th ReLU activation function attached to the 12th convolutional layer in the encoder network model is connected to an adaptive instance normalization layer. Specifically, the adaptive instance normalization layer performs instance normalization according to the following formula:

[0076]

[0077] Wherein, x represents the feature map of the first content image after feature encoding; y represents the feature map of the first style image after feature encoding; A mean value of a feature map representing the first content image; represents the mean of the feature map of the first style image; A variance of a feature map representing a first content picture; The variance of the feature map representing the first style image; Represents a target feature for instance normalization of the first content image and the first style image.

[0078] It can be seen that after the encoder network model training is completed, this embodiment transfers both the style image and the content image from the image space to the feature space, and connects the feature map output by the 15th ReLU activation function to the adaptive instance normalization layer. The adaptive instance normalization layer can normalize the content image, and the input is the feature map x of the content image output by the 15th ReLU activation function and the feature map y of the style image, and the mean and variance of the feature map of each channel of the content image are matched with the mean and variance of the feature map of each channel of the style image.

[0079] Figure 7 The network structure diagram of the decoder network model according to an embodiment of the present disclosure is schematically shown.

[0080] like Figure 7 As shown, in the embodiment of the present disclosure, the decoder network model adopts a symmetrical network structure before the 15th ReLU activation function attached to the 12th convolutional layer in the encoder network model, and the pooling layers in the encoder network model are all replaced by upsampling layers.

[0081] Specifically, the decoder network model includes 12 convolutional layers, 4 upsampling layers, and 3 dilated convolutional layers. Each convolutional layer and dilated convolutional layer is followed by a ReLU activation function, thus forming 15 ReLU activation functions. Among them, the 3 dilated convolutional layers are set in parallel between the 3rd ReLU activation function and the 4th convolutional layer. For the specific network structure, see Figure 7 , can be derived according to the encoder network model, which will not be repeated here.

[0082] Based on the above public content, a built image style transfer model can be obtained. Figure 8A flowchart of a method for training a picture style transfer model according to an embodiment of the present disclosure is schematically shown.

[0083] like Figure 8 As shown, in the embodiment of the present disclosure, the training method of the picture style transfer model may include operations S810 to S820.

[0084] In operation S810, a second image data set including a plurality of second style images and second content images is obtained, the second image data set is preprocessed, and the preprocessed second image data set is randomly split into a training set and a validation set.

[0085] Specifically, referring to the above operation S510, the public image dataset required by the picture style transfer model can be normalized to 256×256 in size, and then the image dataset can be randomly divided into a training set and a validation set according to a ratio.

[0086] In operation S820, the training set is converted into a preset format and then input into the encoder network model for feature encoding. The encoder network model is trained using the Adam gradient descent algorithm to obtain a trained encoder network model.

[0087] Next, referring to the above operation S520, the images in the image dataset can be converted into tfrecord file format. The above preprocessed image dataset is sent to the picture style transfer network model, and the Adam gradient descent algorithm is used to train and optimize the picture style transfer network model to obtain a trained picture style transfer network model.

[0088] In the disclosed embodiment, the picture style transfer model is optimized by minimizing the loss function, and the total loss function is calculated according to the following formula:

[0089]

[0090] In the formula, Represents the total loss function during training; Indicates content loss, represents style loss; is the weight hyperparameter.

[0091] In the disclosed embodiment, the user specifies multiple content images. Therefore, multiple content images can be merged according to the style images according to the actual needs of the user, so that the user can intelligently customize the desired smart card surface pattern.

[0092] It should be noted that in the disclosed embodiment, when the user customizes the picture, there are two options. In the first option, the user does not upload a picture of a specified style, and directly uses the content picture as the picture of the card surface of the final smart card. After the user uploads the content picture, it directly enters operation S230 and waits for the user to confirm the picture. In the second option, the user uploads a picture of a specified style and wants to perform style conversion on the content picture. After the user uploads the style picture and the content picture, the customization client will send the user's uploaded picture to the picture style transfer model in operation S220 to perform style conversion on the content picture.

[0093] In the case of the first solution, the customization client prompts the user to confirm whether to directly use the content image as the final card surface pattern of the smart card. In the case of the second solution, the customization client prompts the user to confirm whether to use the image output by the model in operation S220 as the final card surface pattern of the smart card. After the user confirms successfully, the customization client uses the confirmed image as the card surface pattern.

[0094] Based on the above disclosed content, the method for customizing the smart card face pattern provided by the embodiment of the present disclosure can integrate the pattern information of multiple pictures, increase the diversity of picture styles, enable users to intelligently customize the card face pattern they like, and enhance the user experience. The present disclosure builds and trains a deep learning picture style transfer network model, and the model only needs to be trained once to transfer pictures of various styles. The picture style transfer network model integrates the content picture with the style picture, so that the style of the finally generated picture is no longer a single style, and the picture presents a diversified image style to meet the image needs of different people.

[0095] Based on the above-mentioned smart card surface pattern customization method, the present disclosure also provides a smart card surface pattern customization device. Fig. 9 The device is described in detail.

[0096] Fig. 9 The block diagram of the apparatus for customizing the card surface pattern of a smart card according to an embodiment of the present disclosure is schematically shown.

[0097] like Fig. 9 As shown, the smart card surface pattern customization device 900 of this embodiment includes a customization request module 910 , a style conversion module 920 and a pattern making module 930 .

[0098] The customization request module 910 is used to receive a card surface pattern customization request sent by a user, and the card surface pattern customization request includes a style image and a content image specified by the user. In one embodiment, the customization request module 910 can be used to perform the operation S210 described above, which will not be repeated here.

[0099] The style conversion module 920 is used to input the style image and the content image into the trained image style transfer model, and output the target pattern after the content image is style-converted according to the style image. In one embodiment, the style conversion module 920 can be used to perform the operation S220 described above, which will not be repeated here.

[0100] The pattern making module 930 is used to make a smart card using the target pattern as the card surface pattern after confirmation by the user. In one embodiment, the pattern making module 930 can be used to perform the operation S230 described above, which will not be described in detail here.

[0101] Through the embodiments of the present disclosure, the present disclosure builds and trains a deep learning image style transfer network model, and the model only needs to be trained once to transfer images of various styles. The image style transfer network model merges the content image with the style image, so that the style of the final generated image is no longer a single style, and the image presents a diversified image style to meet the image needs of different people.

[0102] According to an embodiment of the present disclosure, any multiple modules of the customization request module 910, the style conversion module 920, and the pattern making module 930 can be combined into one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the customization request module 910, the style conversion module 920, and the pattern making module 930 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application-specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware, and firmware, or in any appropriate combination of any of them. Alternatively, at least one of the customization request module 910, the style conversion module 920, and the pattern making module 930 can be at least partially implemented as a computer program module, and when the computer program module is run, the corresponding function can be executed.

[0103] Fig.10 A block diagram of an electronic device suitable for implementing a method for customizing a smart card surface pattern according to an embodiment of the present disclosure is schematically shown.

[0104] like Fig.10As shown, the electronic device 1000 according to an embodiment of the present disclosure includes a processor 1001, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1002 or a program loaded from a storage part 1008 to a random access memory (RAM) 1003. The processor 1001 may include, for example, a general-purpose microprocessor (such as a CPU), an instruction set processor and / or a related chipset and / or a special-purpose microprocessor (for example, an application-specific integrated circuit (ASIC)), etc. The processor 1001 may also include an onboard memory for caching purposes. The processor 1001 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.

[0105] In RAM 1003, various programs and data required for the operation of electronic device 1000 are stored. Processor 1001, ROM 1002 and RAM 1003 are connected to each other via bus 1004. Processor 1001 performs various operations of the method flow according to the embodiment of the present disclosure by executing the program in ROM 1002 and / or RAM 1003. It should be noted that the program can also be stored in one or more memories other than ROM 1002 and RAM 1003. Processor 1001 can also perform various operations of the method flow according to the embodiment of the present disclosure by executing the program stored in the one or more memories.

[0106] According to an embodiment of the present disclosure, the electronic device 1000 may further include an input / output (I / O) interface 1005, which is also connected to the bus 1004. The electronic device 1000 may further include one or more of the following components connected to the I / O interface 1005: an input portion 1006 including a keyboard, a mouse, etc.; an output portion 1007 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage portion 1008 including a hard disk, etc.; and a communication portion 1009 including a network interface card such as a LAN card, a modem, etc. The communication portion 1009 performs communication processing via a network such as the Internet. A drive 1010 is also connected to the I / O interface 1005 as needed. A removable medium 1011, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 1010 as needed, so that a computer program read therefrom is installed into the storage portion 1008 as needed.

[0107] The present disclosure also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiment; or may exist independently without being assembled into the device / apparatus / system. The above computer-readable storage medium carries one or more programs, and when the above one or more programs are executed, the smart card face pattern customization method according to the embodiment of the present disclosure is implemented.

[0108] According to an embodiment of the present disclosure, a computer-readable storage medium may be a non-volatile computer-readable storage medium, for example, may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, an apparatus or a device. For example, according to an embodiment of the present disclosure, a computer-readable storage medium may include the ROM 1002 and / or RAM 1003 described above and / or one or more memories other than ROM 1002 and RAM 1003.

[0109] The embodiment of the present disclosure also includes a computer program product, which includes a computer program, and the computer program contains program code for executing the method shown in the flowchart. When the computer program product is run in a computer system, the program code is used to enable the computer system to implement the smart card surface pattern customization method provided by the embodiment of the present disclosure.

[0110] The above functions defined in the system / device of the embodiment of the present disclosure are performed when the computer program is executed by the processor 1001. According to the embodiment of the present disclosure, the system, device, module, unit, etc. described above can be implemented by a computer program module.

[0111] In one embodiment, the computer program may rely on tangible storage media such as optical storage devices, magnetic storage devices, etc. In another embodiment, the computer program may also be transmitted and distributed in the form of signals on a network medium, and downloaded and installed through the communication part 1009, and / or installed from the removable medium 1011. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.

[0112] In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 1009, and / or installed from the removable medium 1011. When the computer program is executed by the processor 1001, the above functions defined in the system of the embodiment of the present disclosure are performed. According to the embodiment of the present disclosure, the system, device, means, module, unit, etc. described above can be implemented by a computer program module.

[0113] According to an embodiment of the present disclosure, the program code for executing the computer program provided by the embodiment of the present disclosure can be written in any combination of one or more programming languages. Specifically, these computing programs can be implemented using high-level process and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages ​​include, but are not limited to, Java, C++, python, "C" language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on the remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (for example, using an Internet service provider to connect through the Internet).

[0114] The flow charts and block diagrams in the accompanying drawings illustrate the possible architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0115] It will be appreciated by those skilled in the art that the features described in the various embodiments and / or claims of the present disclosure may be combined and / or combined in a variety of ways, even if such combinations and / or combinations are not explicitly described in the present disclosure. In particular, the features described in the various embodiments and / or claims of the present disclosure may be combined and / or combined in a variety of ways without departing from the spirit and teachings of the present disclosure. All of these combinations and / or combinations fall within the scope of the present disclosure.

[0116] The embodiments of the present disclosure are described above. However, these embodiments are only for illustrative purposes and are not intended to limit the scope of the present disclosure. Although the embodiments are described above separately, this does not mean that the measures in the various embodiments cannot be used in combination to advantage. The scope of the present disclosure is defined by the attached claims and their equivalents. Without departing from the scope of the present disclosure, those skilled in the art may make a variety of substitutions and modifications, which should all fall within the scope of the present disclosure.

Claims

1. A method for customizing a smart card surface pattern, comprising: Receiving a card surface pattern customization request sent by a user, wherein the card surface pattern customization request includes a style picture and a content picture specified by the user; Inputting the style image and the content image into a trained image style transfer model, and outputting a target pattern after style conversion of the content image according to the style image; as well as The target pattern is used as a card surface pattern to make a smart card after being confirmed by the user; The picture style transfer model is constructed by an encoder network model, an adaptive instance normalization layer, and a decoder network model in sequence, wherein: The encoder network model adopts a VGG-19 convolutional neural network structure and adds three hole convolution structures with different dilation rates to the VGG-19 convolutional neural network structure in parallel; The adaptive instance normalization layer is used to perform instance normalization on the features passing through the encoder network model; The network structure of the decoder network model is symmetrical to that of the encoder network model; The encoder network model includes 15 convolutional layers, 5 pooling layers, 3 dilated convolutional layers, 3 fully connected layers and 1 softmax classifier. The 3 dilated convolutional layers are arranged in parallel between the 9th convolutional layer and the 10th convolutional layer. Each convolutional layer, dilated convolutional layer and fully connected layer is followed by a ReLU activation function.

2. The method according to claim 1, wherein: The encoder network model is trained in the following way: Acquire a first image data set including a plurality of first style images and first content images, preprocess the first image data set, and randomly split the preprocessed first image data set into a training set and a validation set; The training set is converted into a preset format and then input into the encoder network model for feature encoding. The encoder network model is trained using the Adam gradient descent algorithm to obtain a trained encoder network model.

3. The method according to claim 2, wherein: The preprocessing of the first image data set includes: scaling the first image data set to a preset size; A blur processing, a lighting adjustment or a rotation operation is performed on the first image data set of a preset size.

4. The method according to claim 1, wherein: The ReLU activation function attached to the 12th convolutional layer in the encoder network model is connected to the adaptive instance normalization layer.

5. The method according to claim 1, wherein: The decoder network model adopts a symmetrical network structure before the ReLU activation function attached to the 12th convolutional layer in the encoder network model, and replaces the pooling layers in the encoder network model with upsampling layers.

6. The method according to claim 1, wherein: The image style transfer model is trained in the following way: Acquire a second image dataset including a plurality of second style images and a second content image, preprocess the second image dataset, and randomly split the preprocessed second image dataset into a training set and a validation set; The training set is converted into a preset format and then input into the encoder network model for feature encoding. The encoder network model is trained using the Adam gradient descent algorithm to obtain a trained encoder network model.

7. The method according to claim 1, wherein: The user specifies multiple content images.

8. A device for customizing a smart card surface pattern, comprising: A customization request module, used to receive a card surface pattern customization request sent by a user, wherein the card surface pattern customization request includes a style picture and a content picture specified by the user; A style conversion module, used to input the style image and the content image into a trained image style transfer model, and output a target pattern after the content image is style converted according to the style image; as well as A pattern making module, used to make a smart card using the target pattern as a card surface pattern after confirmation by the user; The picture style transfer model is constructed by an encoder network model, an adaptive instance normalization layer, and a decoder network model in sequence, wherein: The encoder network model adopts a VGG-19 convolutional neural network structure and adds three hole convolution structures with different dilation rates to the VGG-19 convolutional neural network structure in parallel; The adaptive instance normalization layer is used to perform instance normalization on the features passing through the encoder network model; The network structure of the decoder network model is symmetrical to that of the encoder network model; The encoder network model includes 15 convolutional layers, 5 pooling layers, 3 dilated convolutional layers, 3 fully connected layers and 1 softmax classifier. The 3 dilated convolutional layers are arranged in parallel between the 9th convolutional layer and the 10th convolutional layer. Each convolutional layer, dilated convolutional layer and fully connected layer is followed by a ReLU activation function.

9. An electronic device, comprising: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors execute the method according to any one of claims 1 to 7.

10. A computer-readable storage medium having executable instructions stored thereon, which, when executed by a processor, causes the processor to execute the method according to any one of claims 1 to 7.

11. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Pattern generation method and system

    CN111210487A