Grayscale optimization method and device

By using maps to traverse and delete information to be deleted in the application, the problem of low reliability of grayscale optimization is solved, the accuracy and flexibility of grayscale optimization are improved, and the user experience is improved.

CN113778546BActive Publication Date: 2025-05-23BEIJING WODONG TIANJUN INFORMATION TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110298380.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-03-19
Publication Date
2025-05-23
Estimated Expiration
2041-03-19

AI Technical Summary

Technical Problem

In the prior art, the reliability of grayscale optimization is relatively low, resulting in some logic in the application being unable to run and incomplete coverage.

Method used

By receiving the user's startup instructions, use the preset map to traverse the file to be deleted, obtain and delete the corresponding information to be deleted, thereby obtaining the target application and starting it.

Benefits of technology

It improves the accuracy and reliability of grayscale optimization, enhances the flexibility and diversity of grayscale optimization, makes users have a better user experience, and avoids the risk of application packages being crawled.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113778546B_ABST
    Figure CN113778546B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a method and device for grayscale optimization, including: receiving a startup instruction initiated by a user, the startup instruction is used to instruct the startup of an initial application, traversing each file to be deleted according to a preset mapping map corresponding to the initial application, and obtaining the information to be deleted corresponding to each file to be deleted, wherein the mapping map includes a mapping relationship between the files to be deleted and the information to be deleted, deleting the information to be deleted corresponding to each file to be deleted from the initial application, obtaining a target application, starting the target application, obtaining the information to be deleted corresponding to each file to be deleted by traversing based on the mapping map, and deleting each information to be deleted from the initial application, thereby avoiding the problem of low reliability of grayscale optimization in related technologies, improving the accuracy and reliability of grayscale optimization, and improving the flexibility and diversity of grayscale optimization, and the grayscale optimization is imperceptible to users, thereby improving user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of computer technology, and in particular, to a method and device for grayscale optimization. Background Art

[0002] With the development of the Internet and computer technology, the number of applications (APPs) has increased significantly, and users' demand for the effectiveness of application usage has also continued to increase. In order to improve the quality of applications, grayscale optimization can be performed on applications before they are launched.

[0003] In the prior art, a commonly used grayscale optimization method is grayscale testing, specifically: by configuring an upgrade prompt on a server, when a user opens an application, an in-application upgrade can be implemented for the application based on the upgrade prompt.

[0004] However, through the above method, some logic in the application, especially one-time logic, may not be run, resulting in incomplete coverage of grayscale optimization and low reliability of grayscale optimization. Summary of the invention

[0005] The embodiments of the present application provide a grayscale optimization method and device to solve the problem of low reliability of grayscale optimization in the related art.

[0006] In a first aspect, an embodiment of the present application provides a method for grayscale optimization, comprising:

[0007] Receiving a start instruction initiated by a user, wherein the start instruction is used to instruct to start an initial application program;

[0008] According to a preset mapping map corresponding to the initial application, traverse each file to be deleted to obtain information to be deleted corresponding to each file to be deleted, wherein the mapping map includes a mapping relationship between the files to be deleted and the information to be deleted;

[0009] The information to be deleted corresponding to each of the files to be deleted is deleted from the initial application, a target application is obtained, and the target application is started.

[0010] In some embodiments, the mapping graph is a container that associates key objects and value objects; each of the files to be deleted is a key object, and each of the information to be deleted is a value object.

[0011] In some embodiments, according to a preset mapping map corresponding to the initial application, traversing each to-be-deleted file to obtain the to-be-deleted information corresponding to each to-be-deleted file, includes:

[0012] Each key object in the mapping graph is traversed, and based on the association between the key object and the value object, the value object corresponding to each key object is determined, and the value object corresponding to each key object is respectively determined as the information to be deleted.

[0013] In some embodiments, it also includes:

[0014] Calling the initial application according to the startup instruction, and obtaining version attribute information of the initial application;

[0015] If the version attribute information does not include a first identifier, obtaining a mapping map corresponding to the initial application, wherein the first identifier is used to indicate that the version of the initial application is a grayscale optimized version;

[0016] If the version attribute information includes the first identifier, the initial application is started.

[0017] In some embodiments, it also includes:

[0018] Acquire each initial file of the initial application and each initial information stored in each initial file;

[0019] The mapping diagram is constructed based on the preset grayscale optimization requirements, the initial files, and the initial information.

[0020] In some embodiments, based on the preset grayscale optimization requirements, the initial files, and the initial information, the mapping diagram is constructed, including:

[0021] Based on the grayscale optimization requirement, determining each file to be deleted from each of the initial files;

[0022] Based on the grayscale optimization requirement, determining information to be deleted from each of the files to be deleted;

[0023] The mapping diagram is constructed according to each of the files to be deleted and each of the information to be deleted.

[0024] In some embodiments, constructing the mapping diagram according to each of the to-be-deleted files and each of the to-be-deleted information includes:

[0025] For any information to be deleted stored in any file to be deleted, if a key object corresponding to the file to be deleted has been constructed, a value object corresponding to the key object corresponding to the file to be deleted is constructed, and the information to be deleted is stored in the value object corresponding to the key object corresponding to the file to be deleted.

[0026] In some embodiments, it also includes:

[0027] If a key object corresponding to any of the files to be deleted is not constructed, a key object corresponding to any of the files to be deleted is constructed, and a value object corresponding to the key object corresponding to any of the files to be deleted is constructed, and any information to be deleted is stored in the value object corresponding to the key object corresponding to any of the files to be deleted.

[0028] In some embodiments, one key object may correspond to a plurality of the information to be deleted, and one piece of information to be deleted corresponds to one key object.

[0029] In some embodiments, the second identifier is used to indicate that the version of the target application is a grayscale optimized version.

[0030] In a second aspect, an embodiment of the present application provides a grayscale optimization device, comprising:

[0031] A receiving unit, configured to receive a start instruction initiated by a user, wherein the start instruction is used to instruct to start an initial application program;

[0032] A traversal unit, configured to traverse each to-be-deleted file according to a preset mapping map corresponding to the initial application program, and obtain to-be-deleted information corresponding to each to-be-deleted file, wherein the mapping map includes a mapping relationship between the to-be-deleted file and the to-be-deleted information;

[0033] A deleting unit, used for deleting the to-be-deleted information corresponding to each of the to-be-deleted files from the initial application to obtain a target application;

[0034] The first starting unit is used to start the target application.

[0035] In some embodiments, the mapping graph is a container that associates key objects and value objects; each of the files to be deleted is a key object, and each of the information to be deleted is a value object.

[0036] In some embodiments, the traversal unit includes:

[0037] A traversal subunit, used for traversing each key object in the mapping graph;

[0038] The first determining subunit is used to determine the value object corresponding to each key object based on the association between the key object and the value object, and determine the value object corresponding to each key object as the information to be deleted.

[0039] In some embodiments, it also includes:

[0040] A calling unit, configured to call the initial application according to the startup instruction;

[0041] A first acquisition unit, used to acquire version attribute information of the initial application;

[0042] A second acquisition unit is configured to acquire a mapping map corresponding to the initial application program if the version attribute information does not include a first identifier, wherein the first identifier is used to indicate that the version of the initial application program is a grayscale optimized version;

[0043] The second starting unit is configured to start the initial application program if the version attribute information includes the first identifier.

[0044] In some embodiments, it also includes:

[0045] A third acquisition unit, used for acquiring each initial file of the initial application and each initial information stored in each initial file;

[0046] The construction unit is used to construct the mapping diagram based on the preset grayscale optimization requirements, the initial files, and the initial information.

[0047] In some embodiments, the building block comprises:

[0048] A second determining subunit is used to determine each file to be deleted from each of the initial files based on the grayscale optimization requirement;

[0049] A third determining subunit is used to determine the information to be deleted from each of the files to be deleted based on the grayscale optimization requirement;

[0050] The construction subunit is used to construct the mapping diagram according to each of the files to be deleted and each of the information to be deleted.

[0051] In some embodiments, the construction subunit is used to, for any information to be deleted stored in any file to be deleted, if a key object corresponding to any file to be deleted has been constructed, then construct a value object corresponding to the key object corresponding to any file to be deleted, and store any information to be deleted in the value object corresponding to the key object corresponding to any file to be deleted.

[0052] In some embodiments, the construction subunit is used to, if a key object corresponding to any file to be deleted is not constructed, construct a key object corresponding to any file to be deleted, and construct a value object corresponding to the key object corresponding to any file to be deleted, and store any information to be deleted in the value object corresponding to the key object corresponding to any file to be deleted.

[0053] In some embodiments, one key object may correspond to a plurality of the information to be deleted, and one piece of information to be deleted corresponds to one key object.

[0054] In some embodiments, it also includes:

[0055] An allocating unit is used to allocate a second identifier to the target application, wherein the second identifier is used to indicate that the version of the target application is a grayscale optimized version.

[0056] In a third aspect, an embodiment of the present application provides an electronic device, including: a memory, a processor;

[0057] Memory; Memory for storing instructions executable by the processor;

[0058] Wherein, the processor is configured to execute the method described in the first aspect above.

[0059] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and when the computer-executable instructions are executed by a processor, they are used to implement the method described in the first aspect above.

[0060] In a fifth aspect, an embodiment of the present application provides a computer program product, including a computer program, which implements the method described in the first aspect above when executed by a processor.

[0061] The embodiment of the present application provides: receiving a startup instruction initiated by a user, wherein the startup instruction is used to instruct the startup of an initial application, traversing each file to be deleted according to a preset mapping map corresponding to the initial application, obtaining the information to be deleted corresponding to each file to be deleted, wherein the mapping map includes a mapping relationship between the files to be deleted and the information to be deleted, deleting the information to be deleted corresponding to each file to be deleted from the initial application, obtaining a target application, and starting a technical solution for the target application. By traversing the mapping map to obtain the information to be deleted corresponding to each file to be deleted, and deleting each information to be deleted from the initial application, the problem of low reliability of grayscale optimization in related technologies can be avoided, the accuracy and reliability of grayscale optimization are improved, and the flexibility and diversity of grayscale optimization are improved. The grayscale optimization is imperceptible to the user, and the technical effect of improving the user's usage experience is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0062] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0063] Figure 1 A schematic flow chart of a grayscale optimization method according to an embodiment of the present application;

[0064] Figure 2A schematic diagram of an application scenario of the grayscale optimization method of an embodiment of the present application;

[0065] Figure 3 A schematic flow chart of a grayscale optimization method according to another embodiment of the present application;

[0066] Figure 4 A schematic diagram of a grayscale optimization device according to an embodiment of the present application;

[0067] Figure 5 A schematic diagram of a grayscale optimization device according to another embodiment of the present application;

[0068] Figure 6 Block diagram of an electronic device for the grayscale optimization method of an embodiment of the present application

[0069] The above drawings show clear embodiments of the present disclosure, which will be described in more detail below. These drawings and text descriptions are not intended to limit the scope of the present disclosure in any way, but to illustrate the concepts of the present disclosure to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0070] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0071] The nouns involved in the embodiments of the present application are explained as follows:

[0072] Grayscale optimization: also known as grayscale testing, refers to selecting a specific group of people to try out a product or application before it is officially released, and gradually expanding the number of trial users so that problems can be discovered and corrected in a timely manner.

[0073] Application: The full name of Application in English, abbreviated as APP, refers to a computer program for completing one or more specific tasks. It runs in user mode, can interact with users, and has a visual user interface.

[0074] Version: used to distinguish objects such as operating systems, applications, and products at different stages. Generally speaking, the same object has different functions or performances in different versions.

[0075] As the number of applications increases, users have higher and higher requirements for the quality of applications. In order to meet the needs of users, application providers can use technical means to grayscale optimize applications before the application goes online, that is, before the provider publishes the application to the application store (online virtual store) and other platforms for users to download the application. Through grayscale optimization, the application can determine possible problems that may exist during the use of the application, so that by timely discovering and correcting problems, the application used by users is a relatively high-quality application, thereby improving the user experience.

[0076] In the related art, two methods are usually used to perform grayscale optimization on an application. One method is to configure an upgrade prompt through a server so that users can upgrade directly within the application.

[0077] For example, the user may send a command to open an application to the terminal device by touching the screen or by voice control.

[0078] The terminal device sends a request to start the application to the server (or backend server) corresponding to the application according to the instruction to start the application.

[0079] The application server may send a pre-configured upgrade reminder message to the terminal device.

[0080] The terminal device can display the upgrade prompt message, and can send corresponding interactive messages to the application server based on the user's related operations on the upgrade prompt message (such as clicking a virtual confirmation button, etc.), thereby completely optimizing the local grayscale of the application.

[0081] Among them, the terminal equipment can be a mobile terminal, such as a mobile phone (or "cellular" phone) and a computer with a mobile terminal, for example, it can be a portable, pocket-sized, handheld, computer-built-in or vehicle-mounted mobile device, which exchanges language and / or data with the wireless access network; the terminal equipment can also be a personal communication service (Personal Communication Service, PCS) phone, a cordless phone, a session initiation protocol (Session Initiation Protocol, SIP) phone, a wireless local loop (Wireless Local Loop, WLL) station, a personal digital assistant (Personal Digital Assistant, PDA), a tablet computer, a wireless modem (modem), a handheld device (handset), a laptop computer (laptop computer), a machine type communication (Machine Type Communication, MTC) terminal and other equipment; the terminal equipment can also be called a system, a subscriber unit (Subscriber Unit), a subscriber station (Subscriber Station), a mobile station (Mobile Station), a mobile station (Mobile), a remote station (Remote Station), a remote terminal (Remote Terminal), an access terminal (Access Terminal), a user terminal (User Terminal), a user agent (User Agent), User Device or User Equipment, etc., are not limited here.

[0082] However, through this grayscale optimization method, some logic in the application, especially one-time logic, may not be run, such as user guidance logic, activation reporting logic, login logic, etc., resulting in incomplete coverage of grayscale optimization and low reliability of grayscale optimization.

[0083] Another method of grayscale optimization is to generate an application package (Android application package, APK) corresponding to the application and publish the application package to the application store. Users can download the application package and grayscale optimize the application based on the application package.

[0084] However, when adopting this medium-grayscale optimization method, since the application store may have the function of "mutual package grabbing", that is, the application package may be grabbed and used by other merchants, on the one hand, it is not conducive to the protection of the labor results of the provider, and on the other hand, it is very likely that the application package will be modified, causing losses to users, etc.

[0085] In order to solve at least one of the problems arising from the above-mentioned related technologies, the inventor of the present application has obtained the inventive concept of the present application through creative work: based on a pre-constructed mapping graph including the mapping relationship between the files to be deleted and the information to be deleted, each file to be deleted is traversed to obtain and delete the information to be deleted from the application.

[0086] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0087] See also Figure 1 , Figure 1 A flowchart of a grayscale optimization method according to an embodiment of the present application is shown.

[0088] like Figure 1 As shown, the method includes:

[0089] S101: receiving a start instruction initiated by a user.

[0090] The startup instruction is used to instruct the startup of an initial application program.

[0091] Exemplarily, the execution subject of this embodiment may be a grayscale optimization device, and the grayscale optimization device may be a terminal device. For the description of the terminal device, please refer to the above embodiment, which will not be repeated here. The grayscale optimization device may be a processor provided in the terminal device, or a chip provided in the terminal device, etc., which is not limited in this embodiment.

[0092] It should be understood that the "initial" in the "initial application" in this embodiment is used to distinguish it from the "target application" in the following text, that is, the initial application can be understood as the application before grayscale optimization, and the target application can be understood as the application after grayscale optimization, and it cannot be understood as a limitation on the application itself.

[0093] The grayscale optimization method of this embodiment can be applied to Figure 2 The application scenarios shown are as follows: Figure 2 As shown, the terminal device 201 can download multiple applications, such as Figure 2 Application A and Application B are shown in the figure.

[0094] For example, application A may be a shopping-related application, that is, user 202 may use application A to shop; application B may be a reading-related application, that is, user 202 may use application B to read.

[0095] It is worth mentioning that Figure 2 It is only used to exemplarily show two different applications (ie, application A and application B) and should not be construed as a limitation on the types and number of applications.

[0096] Combination Figure 2 In the application scenario shown, this embodiment can be understood as: user 202 can initiate a startup instruction to terminal device 201 by touching the screen, such as clicking on application A, and the startup instruction is used to instruct terminal device 201 to start application A.

[0097] Of course, user 202 can also issue a start command to the user by voice, such as Figure 2 , as shown in "Open Application A".

[0098] Specifically, the terminal device 201 can be provided with a sound collector and an analysis processor. The terminal device 201 can collect the user 202's "open application A" through the sound collector, and perform semantic analysis and other operations on "open application A" through the analysis processor, thereby completing the startup of application A.

[0099] S102: traversing each to-be-deleted file according to a preset mapping map corresponding to the initial application program to obtain to-be-deleted information corresponding to each to-be-deleted file.

[0100] The mapping diagram includes the mapping relationship between the files to be deleted and the information to be deleted.

[0101] This embodiment introduces a mapping graph, and the mapping graph includes the feature of the mapping relationship between the files to be deleted and the information to be deleted. By introducing this feature, this embodiment can traverse each file to be deleted when performing grayscale optimization, and obtain the information to be deleted corresponding to each file to be deleted, thereby obtaining all the information to be deleted, so that the obtained information to be deleted can be deleted from the initial application subsequently, thereby achieving grayscale optimization of the initial application.

[0102] It is worth noting that, in the present embodiment, a mapping map is introduced, and the information to be deleted is determined based on the mapping map, so that the grayscale optimization of the initial application is achieved by deleting the information to be deleted in the initial application, thereby avoiding the problem of incomplete coverage of grayscale optimization and low reliability of grayscale optimization caused by the first grayscale optimization scheme in the above-mentioned related technology, thereby improving the accuracy and reliability of grayscale optimization, thereby satisfying the user experience of the application, and avoiding the disadvantage of the second grayscale optimization scheme in the above-mentioned related technology that the application package is captured, causing unnecessary losses to the provider and the user, and realizing the grayscale optimization directly based on the terminal device, thereby achieving the flexibility and convenience of grayscale optimization.

[0103] S103: deleting the to-be-deleted information corresponding to each to-be-deleted file from the initial application, obtaining a target application, and starting the target application.

[0104] Combining the above embodiments and Figure 1 In the application scenario shown, when the terminal device determines the information to be deleted corresponding to each file to be deleted, it can delete the determined information to be deleted from the initial application program, and obtain and start the target application program.

[0105] Based on the above analysis, it can be known that the present embodiment provides a method for grayscale optimization, including: receiving a startup instruction initiated by a user, wherein the startup instruction is used to instruct the startup of an initial application, according to a preset mapping map corresponding to the initial application, the mapping map includes a mapping relationship between files to be deleted and information to be deleted, traversing each file to be deleted, obtaining the information to be deleted corresponding to each file to be deleted, deleting the information to be deleted corresponding to each file to be deleted from the initial application, obtaining a target application, and starting the target application, by traversing based on the mapping map to obtain the information to be deleted corresponding to each file to be deleted, deleting each information to be deleted from the initial application, the problem of low reliability of grayscale optimization in related technologies can be avoided, the accuracy and reliability of grayscale optimization are improved, and the flexibility and diversity of grayscale optimization are improved, and the grayscale optimization is imperceptible to the user, thereby improving the technical effect of the user's usage experience.

[0106] See also Figure 3 , Figure 3 It is a flowchart of a grayscale optimization method according to another embodiment of the present application.

[0107] like Figure 3 As shown, the method includes:

[0108] S301: Acquire each initial file of the initial application program and each initial information stored in each initial file.

[0109] Similarly, the "initial" in the "initial file" in this embodiment is used to distinguish it from the "file to be deleted", and the "initial information" is used to distinguish it from (information to be transmitted), and it cannot be understood as a limitation on the file content or information content.

[0110] It should be understood that there may be multiple initial files, and one initial file may include multiple initial information, and the initial information may be understood as parameter information.

[0111] S302: constructing a mapping diagram based on preset grayscale optimization requirements, various initial files, and various initial information.

[0112] Exemplarily, the grayscale optimization requirement may be determined based on experience, historical records, and experiments, etc., and this embodiment does not limit this.

[0113] It is worth noting that, in this embodiment, by constructing a mapping map based on grayscale optimization requirements, initial files, and initial information, the mapping map can meet the requirements of grayscale optimization, thereby improving the technical effect of reliability and accuracy of grayscale optimization.

[0114] It should be understood that the execution subject of constructing the mapping diagram may be other devices connected to the terminal device, such as a server (including a cloud server and a local server), and this embodiment does not limit this.

[0115] For example, when the server is connected to the terminal device, the server can collect the running attribute information of the initial application (which may include relevant information during the running process of the initial application itself, and may also include relevant information such as evaluations generated by users for the running of the initial application).

[0116] The server determines the grayscale optimization requirements based on the operation attribute information.

[0117] The server constructs a mapping map according to the grayscale optimization requirements, the initial file, and the initial information, and sends the mapping map to the terminal device.

[0118] In some embodiments, S302 may include the following steps:

[0119] Step 1: Based on the grayscale optimization requirements, determine the files to be deleted from the initial files.

[0120] Step 2: Based on the grayscale optimization requirements, determine the information to be deleted from each file to be deleted.

[0121] Exemplarily, in combination with the above-mentioned embodiments, the server can select files that need to be deleted from the initial application (i.e., files to be deleted) from a large number of initial files according to the grayscale optimization requirements. After selecting each file to be deleted, for any file to be deleted, the information to be deleted can be determined from any file to be deleted based on the grayscale optimization requirements.

[0122] Step 3: Construct a mapping graph based on each file to be deleted and each information to be deleted.

[0123] It is worth noting that, in this embodiment, by first determining each file to be deleted based on the grayscale optimization requirement, and then determining each information to be deleted based on the grayscale optimization requirement, the constructed mapping diagram can have a technical effect of high integrity and comprehensiveness.

[0124] In some embodiments, the mapping graph is a container that associates key objects and value objects; each file to be deleted is a key object, and each information to be deleted is a value object.

[0125] In this embodiment, the mapping diagram can be understood as a container for storing information based on key-value pairs. The file to be deleted can be the key object in the key-value pair, the information to be deleted can be the value object in the key-value pair, and one file to be deleted can be a key object, and one information to be deleted can be a value object.

[0126] It is worth noting that by associating and storing the object to be deleted with the information to be deleted in the form of key-value pairs, the storage efficiency can be improved, and especially when the corresponding value object is subsequently queried based on the object to be stored, the query efficiency can be improved, and the technical effect of improving the accuracy and reliability of the query can be improved.

[0127] In some embodiments, one key object may correspond to multiple pieces of information to be deleted, and one piece of information to be deleted corresponds to one key object.

[0128] It is worth noting that one file to be deleted may correspond to multiple information to be deleted, therefore, one key object may correspond to multiple information to be deleted, and conversely, one information to be deleted corresponds to only one key object.

[0129] By constructing each piece of information to be deleted belonging to a file to be deleted as a value object corresponding to the key object of the file to be deleted, it is possible to more conveniently and quickly determine all value objects corresponding to the key object when querying the value object based on the key object, thereby improving the technical effect of improving the efficiency of grayscale optimization.

[0130] On this basis, step 3 may include the following sub-steps:

[0131] Sub-step 1: for any information to be deleted stored in any file to be deleted, determine whether a key object corresponding to any file to be deleted has been constructed, if so, execute sub-step 2, if not, execute sub-step 3.

[0132] Sub-step 2: construct a value object corresponding to the key object corresponding to any file to be deleted, and store any information to be deleted in the value object corresponding to the key object corresponding to any file to be deleted.

[0133] Sub-step 3: construct a key object corresponding to any file to be deleted, and construct a value object corresponding to the key object corresponding to any file to be deleted, and store any information to be deleted in the value object corresponding to the key object corresponding to any file to be deleted.

[0134] Exemplarily, in general, if any file to be deleted is the first file to be deleted, a key object corresponding to the file to be deleted can be directly constructed, and a value object corresponding to the key object corresponding to the file to be deleted can be constructed, and the to-be-deleted information of the file to be deleted can be stored in the corresponding value object; if any file to be deleted is not the first file to be deleted, in order to avoid repeatedly constructing the key object of the same file to be deleted, the non-first file to be deleted can be compared with the previous object to be deleted. If the file to be deleted is included in the previous file to be deleted, there is no need to construct the key object again. Instead, a value object can be constructed again based on the key object, and the to-be-deleted information can be stored in the re-constructed value object.

[0135] It is worth noting that, by storing each piece of information to be stored separately through the above method, it is possible to avoid repeatedly constructing the key object of the same file to be deleted, saving storage space and resources, and providing a technical effect of construction efficiency.

[0136] S303: receiving a start instruction initiated by a user, wherein the start instruction is used to instruct to start an initial application program.

[0137] For example, the description of S303 may refer to S101, which will not be repeated here.

[0138] S304: Calling the initial application according to the startup instruction, and obtaining version attribute information of the initial application.

[0139] S305: Determine whether the version attribute information includes the first identifier, if not, execute S306, if not, execute S310.

[0140] The first identifier is used to indicate that the version of the initial application is a grayscale optimized version.

[0141] S306: Acquire a mapping map corresponding to the initial application.

[0142] S307: traverse each key object in the mapping graph, determine the value object corresponding to each key object based on the association between the key object and the value object, and determine the value object corresponding to each key object as the information to be deleted.

[0143] Based on the above analysis, it can be known that there is an association between the key object and the value object, and one key object can correspond to multiple value objects. In this embodiment, one or more value objects corresponding to each key object can be determined in sequence by traversal, and each value object determined in sequence can be determined as information to be deleted.

[0144] It is worth noting that, in this embodiment, by determining each piece of information to be deleted in a traversal manner, the efficiency of determining each piece of information to be deleted can be improved, and the accuracy and reliability of the determined information to be deleted can be improved.

[0145] S308: deleting the to-be-deleted information corresponding to each to-be-deleted file from the initial application, obtaining a target application, and starting the target application.

[0146] For example, for the description of S308, reference may be made to the description of S303, which will not be repeated here.

[0147] S309: Allocate a second identifier for the target application, wherein the second identifier is used to indicate that the version of the target application is a grayscale optimized version.

[0148] The second identifier may be the same as the first identifier, or may be different from the first identifier, which is not limited in this embodiment.

[0149] It is worth noting that, in this embodiment, a second identifier is assigned to the target application, so that the second identifier is used to indicate that the version of the target application is a grayscale optimized version, so that the target application can be directly started subsequently to avoid repeated grayscale optimization, thereby achieving the technical effect of saving resources and costs and improving user experience.

[0150] S310: Start the initial application.

[0151] Based on the above analysis, it can be known that in this embodiment, the identifier can represent different version attributes of the initial application. If there is no first identifier, it means that the initial application is a grayscale optimized version. If there is a first identifier, it means that the initial application is a version that has not been grayscale optimized.

[0152] Accordingly, for a version of the initial application that has not been grayscale optimized, the terminal device can perform grayscale optimization, and for a version of the initial application that has been grayscale optimized, the terminal device can directly launch the initial application without grayscale optimization again.

[0153] It is worth noting that in this embodiment, by determining different methods through version attribute information, or performing grayscale optimization, or performing startup, flexibility and diversity can be improved, and repeated grayscale optimization can be avoided, achieving the technical effect of saving resources.

[0154] See also Figure 4 , Figure 4 A schematic diagram of a grayscale optimization device according to an embodiment of the present application.

[0155] like Figure 4 As shown, the grayscale optimization device 400 includes:

[0156] The receiving unit 401 is used to receive a start instruction initiated by a user, wherein the start instruction is used to instruct to start an initial application program.

[0157] The traversal unit 402 is used to traverse each to-be-deleted file according to a preset mapping map corresponding to the initial application program to obtain the to-be-deleted information corresponding to each to-be-deleted file, wherein the mapping map includes a mapping relationship between the to-be-deleted file and the to-be-deleted information.

[0158] The deleting unit 403 is used to delete the to-be-deleted information corresponding to each to-be-deleted file from the initial application program to obtain a target application program.

[0159] The first starting unit 404 is used to start the target application.

[0160] See also Figure 5 , Figure 5 FIG. 1 is a schematic diagram of a grayscale optimization device according to another embodiment of the present application.

[0161] like Figure 5 As shown, the grayscale optimization device 500 includes:

[0162] The third acquisition unit 501 is used to acquire each initial file of the initial application program and each initial information stored in each of the initial files.

[0163] The construction unit 502 is used to construct a mapping diagram based on the preset grayscale optimization requirements, various initial files, and various initial information.

[0164] Combination Figure 5 It can be seen that, in some embodiments, the construction unit 502 includes:

[0165] The second determining subunit 5021 is used to determine each file to be deleted from each initial file based on the grayscale optimization requirement.

[0166] The third determining subunit 5022 is used to determine the information to be deleted from each file to be deleted based on the grayscale optimization requirement.

[0167] The construction subunit 5023 is used to construct a mapping diagram according to each file to be deleted and each information to be deleted.

[0168] In some embodiments, the mapping graph is a container that associates key objects and value objects; each file to be deleted is a key object, and each information to be deleted is a value object.

[0169] In some embodiments, one key object may correspond to multiple pieces of information to be deleted, and one piece of information to be deleted corresponds to one key object.

[0170] In some embodiments, the construction sub-unit 5023 is used to, for any information to be deleted stored in any file to be deleted, if a key object corresponding to any file to be deleted has been constructed, then construct a value object corresponding to the key object corresponding to any file to be deleted, and store any information to be deleted in the value object corresponding to the key object corresponding to any file to be deleted.

[0171] In some embodiments, the construction subunit 5023 is used to, if a key object corresponding to any file to be deleted is not constructed, construct a key object corresponding to any file to be deleted, and construct a value object corresponding to the key object corresponding to any file to be deleted, and store any information to be deleted in the value object corresponding to the key object corresponding to any file to be deleted.

[0172] The receiving unit 503 is used to receive a start instruction initiated by a user, wherein the start instruction is used to instruct to start an initial application program.

[0173] The calling unit 504 is used to call the initial application program according to the startup instruction.

[0174] The first acquisition unit 505 is used to acquire version attribute information of the initial application.

[0175] The second acquisition unit 506 is configured to acquire a mapping map corresponding to the initial application program if the version attribute information does not include the first identifier, wherein the first identifier is used to indicate that the version of the initial application program is a grayscale optimized version.

[0176] The traversal unit 507 is used to traverse each file to be deleted according to a preset mapping map corresponding to the initial application, wherein the mapping map includes a mapping relationship between the files to be deleted and the information to be deleted, and obtain the information to be deleted corresponding to each file to be deleted.

[0177] In some embodiments, the traversal unit 507 includes:

[0178] The traversal subunit 5071 is used to traverse each key object in the mapping graph.

[0179] The first determining subunit 5072 is used to determine the value object corresponding to each key object based on the association between the key object and the value object, and determine the value object corresponding to each key object as the information to be deleted.

[0180] The deleting unit 508 is used to delete the to-be-deleted information corresponding to each to-be-deleted file from the initial application program to obtain a target application program.

[0181] The allocating unit 509 is configured to allocate a second identifier to the target application, wherein the second identifier is used to indicate that the version of the target application is a grayscale optimized version.

[0182] The first starting unit 510 is used to start the target application.

[0183] The second starting unit 511 is configured to start the initial application program if the version attribute information includes the first identifier.

[0184] According to an embodiment of the present application, the present application also provides an electronic device and a readable storage medium.

[0185] According to an embodiment of the present application, the present application also provides a computer program product, the program product includes: a computer program, the computer program is stored in a readable storage medium, at least one processor of an electronic device can read the computer program from the readable storage medium, and at least one processor executes the computer program so that the electronic device executes the solution provided by any of the above embodiments.

[0186] like Figure 6 , is a block diagram of an electronic device according to the grayscale optimization method of an embodiment of the present application. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workbenches, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples, and are not intended to limit the implementation of the present application described and / or required herein.

[0187] like Figure 6As shown, the electronic device includes: one or more processors 601, a memory 602, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. The various components are connected to each other using different buses, and can be installed on a common mainboard or installed in other ways as needed. The processor can process instructions executed in the electronic device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as a display device coupled to the interface). In other embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple electronic devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 6 A processor 601 is taken as an example.

[0188] The memory 602 is a non-transient computer-readable storage medium provided in the present application. The memory stores instructions executable by at least one processor to enable the at least one processor to perform the grayscale optimization method provided in the present application. The non-transient computer-readable storage medium of the present application stores computer instructions, which are used to enable a computer to perform the grayscale optimization method provided in the present application.

[0189] The memory 602 is a non-transient computer-readable storage medium that can be used to store non-transient software programs, non-transient computer executable programs and modules, such as program instructions / modules corresponding to the grayscale optimization method in the embodiment of the present application. The processor 601 executes various functional applications and data processing of the server by running the non-transient software programs, instructions and modules stored in the memory 602, that is, the grayscale optimization method in the above method embodiment is implemented.

[0190] The memory 602 may 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; the data storage area may store data created by the use of the electronic device according to the grayscale optimization method, etc. In addition, the memory 602 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory 602 may optionally include a memory remotely arranged relative to the processor 601, and these remote memories may be connected to the electronic device of the grayscale optimization method via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0191] The electronic device of the grayscale optimization method may further include: an input device 603 and an output device 604. The processor 601, the memory 602, the input device 603 and the output device 604 may be connected via a bus or other means. Figure 6 The example of connecting through bus is taken in the following.

[0192] The input device 603 can receive input digital or character information, and generate key signal input related to user settings and function control of the electronic device of the grayscale optimization method, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, an indicator rod, one or more mouse buttons, a trackball, a joystick and other input devices. The output device 604 may include a display device, an auxiliary lighting device (e.g., an LED) and a tactile feedback device (e.g., a vibration motor), etc. The display device may include, but is not limited to, a liquid crystal display (LCD), a light emitting diode (LED) display and a plasma display. In some embodiments, the display device may be a touch screen.

[0193] Various implementations of the systems and techniques described herein can be realized in digital electronic circuit systems, integrated circuit systems, dedicated ASICs (application specific integrated circuits), computer hardware, firmware, software, and / or combinations thereof. These various implementations may include being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0194] These computer programs (also referred to as programs, software, software applications, or code) include machine instructions for programmable processors and can be implemented using high-level procedural and / or object-oriented programming languages, and / or assembly / machine languages. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, device, and / or means (e.g., disk, optical disk, memory, programmable logic device (PLD)) for providing machine instructions and / or data to a programmable processor, including a machine-readable medium that receives machine instructions as machine-readable signals. The term "machine-readable signal" refers to any signal for providing machine instructions and / or data to a programmable processor.

[0195] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0196] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0197] A computer system may include clients and servers. Clients and servers are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship to each other.

[0198] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the following claims.

[0199] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims

1. A grayscale optimization method, include: Receiving a start instruction initiated by a user, wherein the start instruction is used to instruct to start an initial application program; According to a preset mapping map corresponding to the initial application, traverse each file to be deleted to obtain information to be deleted corresponding to each file to be deleted, wherein the mapping map includes a mapping relationship between the files to be deleted and the information to be deleted; The information to be deleted corresponding to each of the files to be deleted is deleted from the initial application, a target application is obtained, and the target application is started.

2. The method according to claim 1, in, The mapping graph is a container that associates key objects with value objects; each of the files to be deleted is a key object, and each of the information to be deleted is a value object.

3. The method according to claim 2, in, According to the preset mapping map corresponding to the initial application, each to-be-deleted file is traversed to obtain the to-be-deleted information corresponding to each to-be-deleted file, including: Each key object in the mapping graph is traversed, and based on the association between the key object and the value object, the value object corresponding to each key object is determined, and the value object corresponding to each key object is respectively determined as the information to be deleted.

4. The method according to any one of claims 1 to 3, further comprising: include: Calling the initial application according to the startup instruction, and obtaining version attribute information of the initial application; If the version attribute information does not include a first identifier, obtaining a mapping map corresponding to the initial application, wherein the first identifier is used to indicate that the version of the initial application is a grayscale optimized version; If the version attribute information includes the first identifier, the initial application is started.

5. The method according to claim 2 or 3, further comprising: include: Acquire each initial file of the initial application and each initial information stored in each initial file; The mapping diagram is constructed based on the preset grayscale optimization requirements, the initial files, and the initial information.

6. The method according to claim 5, in, Based on the preset grayscale optimization requirements, the initial files, and the initial information, the mapping diagram is constructed, including: Based on the grayscale optimization requirement, determining each file to be deleted from each of the initial files; Based on the grayscale optimization requirement, determining information to be deleted from each of the files to be deleted; The mapping diagram is constructed according to each of the files to be deleted and each of the information to be deleted.

7. The method according to claim 6, in, According to each of the files to be deleted and each of the information to be deleted, constructing the mapping diagram includes: For any information to be deleted stored in any file to be deleted, if a key object corresponding to the file to be deleted has been constructed, a value object corresponding to the key object corresponding to the file to be deleted is constructed, and the information to be deleted is stored in the value object corresponding to the key object corresponding to the file to be deleted.

8. The method according to claim 7, further comprising: include: If a key object corresponding to any of the files to be deleted is not constructed, a key object corresponding to any of the files to be deleted is constructed, and a value object corresponding to the key object corresponding to any of the files to be deleted is constructed, and any information to be deleted is stored in the value object corresponding to the key object corresponding to any of the files to be deleted.

9. The method according to claim 2 or 3, in, One key object may correspond to a plurality of the information to be deleted, and one piece of information to be deleted corresponds to one key object.

10. The method according to any one of claims 1 to 3, further comprising: include: A second identifier is allocated to the target application, wherein the second identifier is used to indicate that the version of the target application is a grayscale optimized version.

11. A grayscale optimization device, include: A receiving unit, configured to receive a start instruction initiated by a user, wherein the start instruction is used to instruct to start an initial application program; A traversal unit, configured to traverse each to-be-deleted file according to a preset mapping map corresponding to the initial application program, and obtain to-be-deleted information corresponding to each to-be-deleted file, wherein the mapping map includes a mapping relationship between the to-be-deleted file and the to-be-deleted information; A deleting unit, used for deleting the to-be-deleted information corresponding to each of the to-be-deleted files from the initial application to obtain a target application; The first starting unit is used to start the target application.

12. An electronic device, include: Memory, processor; Memory; a memory for storing instructions executable by the processor; The processor is configured to execute the method according to any one of claims 1 to 10.

13. A computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, wherein the computer-executable instructions are used to implement the method according to any one of claims 1 to 10 when executed by a processor.

14. A computer program product comprising a computer program, which, when executed by a processor, implements the method according to any one of claims 1 to 10.

Citation Information

Patent Citations

  • Software upgrading method, apparatus, and system of terminal

    CN106293793A

  • Application upgrade method and device

    CN108008970A