WO2020224215A1 - Artificial intelligence-based image compression method and apparatus, device, and storage medium - Google Patents

Artificial intelligence-based image compression method and apparatus, device, and storage medium Download PDF

Info

Publication number
WO2020224215A1
WO2020224215A1 PCT/CN2019/117738 CN2019117738W WO2020224215A1 WO 2020224215 A1 WO2020224215 A1 WO 2020224215A1 CN 2019117738 W CN2019117738 W CN 2019117738W WO 2020224215 A1 WO2020224215 A1 WO 2020224215A1
Authority
WO
WIPO (PCT)
Prior art keywords
compression
user
picture
compressed
parameter
Prior art date
Application number
PCT/CN2019/117738
Other languages
French (fr)
Chinese (zh)
Inventor
郭勇
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from CN201910383813.6A external-priority patent/CN110298895B/en
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2020224215A1 publication Critical patent/WO2020224215A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/174Redundancy elimination performed by the file system
    • G06F16/1744Redundancy elimination performed by the file system using compression, e.g. sparse files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T9/00Image coding

Definitions

  • the embodiments of the present application belong to the technical field of image compression, and in particular, relate to an artificial intelligence-based image compression method, device, device, and storage medium.
  • the picture compression software in the prior art adapts to a single scene. For example, some scenes require high picture quality, some scenes require a small picture size, some scenes require a small picture memory, and some scenes are due to uploaded pictures. The size of the uploaded picture is not suitable for the need to zoom.
  • the inventor realizes that the existing implementation at least has the following problem: for the aforementioned multiple different scenarios, only a variety of different compression software or Technology to adapt to various different scenarios, user operation is very inconvenient, and can only be compressed once, even if the compression effect is not good, it is impossible to change the parameters for compression, which cannot well meet the personal needs of users.
  • the embodiments of the present application provide an artificial intelligence-based image compression method, device, equipment, and storage medium to solve the problem that the prior art requires a variety of compression software to compress images for a variety of different scenarios. Convenience and inability to change parameters to better meet the needs of users.
  • an embodiment of the present application provides an artificial intelligence-based image compression method, including:
  • the instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
  • the compressed image confirmed by the user is uploaded to the target location.
  • an artificial intelligence-based image compression device including:
  • An instruction receiving module configured to receive a picture compression instruction input by a user, the instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
  • a compression module configured to compress the original picture according to the compression mode and at least one compression parameter to obtain a compressed picture to be reviewed
  • the presentation module is used to present the compressed picture to be reviewed to the user, so that the user can review the compressed picture
  • the adjustment parameter recompression module is used to readjust the compression parameters when the user's review failure instruction is received, and recompress the original picture with the newly adjusted compression parameters and present it to the user for review;
  • the image upload module is used to upload the compressed image confirmed by the user to the target location when the user's approval instruction is received.
  • Some embodiments of the present application also disclose a computer device in which computer-readable instructions are stored in the memory, and when the processor executes the computer-readable instructions, it implements the aforementioned artificial intelligence-based image compression method. step.
  • Some embodiments of the present application also disclose a computer nonvolatile readable storage medium, the computer nonvolatile readable storage medium stores computer readable instructions, and the computer readable instructions are executed by a processor When realizing the steps of the image compression method based on artificial intelligence as described above.
  • the user inputs a picture compression instruction matching the target scene, and the compression instruction carries the original picture and compression mode information; this application compresses the original picture according to the compression mode information; presents the compressed picture to the user, In order to allow users to review the compressed pictures; in this way, users can check whether the compression effect is what they want. If it is not what the user wants, they can automatically adjust the compression parameters to recompress and review, so as to meet the user's personal needs and realize the user
  • the original picture is compressed by selecting the compression mode and compression parameters suitable for the target scene to adapt to a variety of different target scenes, avoiding the single defect of the existing compression software compression function, and convenient operation.
  • FIG. 1 is a flowchart of a picture compression method provided by an embodiment of the application
  • FIG. 2 is a flowchart of an embodiment of a picture compression method provided by this application.
  • FIG. 3 is a flowchart of another embodiment of a picture compression method provided by this application.
  • FIG. 4 is a structural block diagram of an artificial intelligence-based image compression device provided by an embodiment of the application.
  • FIG. 5 is a structural block diagram of another embodiment of the image compression device based on artificial intelligence in this application.
  • Fig. 6 is a block diagram of the hardware structure of a computer device provided by an embodiment of the application.
  • a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes unlisted steps or units, or optionally also includes Other steps or units inherent to these processes, methods, products or equipment.
  • FIG. 1 is a flowchart of the image compression method provided by an embodiment of the application
  • the method includes:
  • S101 Receive a picture compression instruction input by a user, where the picture compression instruction carries an original picture and compression mode information, and the compression mode information includes a compression mode and at least one compression parameter in the compression mode.
  • the compression mode information includes a compression mode
  • the compression mode includes at least one compression parameter
  • the compression mode information is stored for use
  • the user can input the compression mode information that matches the target scene in a selective input mode or a manual input mode.
  • the compression parameters are set with priority levels.
  • the priority levels of the first parameter, the second parameter, and the third parameter may be successively increased or decreased.
  • the compression mode set in this embodiment includes but is not limited to the following modes:
  • compression ratio actual size of space occupied / size of space occupied before compression
  • the compression mode contains at least one compression parameter.
  • One or more compression parameters can be set according to the needs and experience of the corresponding target scene. When there is only one compression parameter, it is called the default parameter. When multiple compression parameters are set, The compression parameter has a priority level, for example, the first parameter has the highest priority, the second parameter has the second priority, and the third parameter has the lowest priority.
  • Applicable target scenarios In some scenarios, such as uploading some small icons of avatars in QQ, WeChat, Weibo and APP on some websites, the pictures are only used for distinguishing and identifying, so that people can know the avatar at a glance. Who does not need to know the specific content information of the picture at all, and can scale the size of the picture;
  • the compression parameters in the compression mode include the scaling ratio (size after compression/size before compression), such as 80%, 70%, 50%, 20%, and so on.
  • the compression mode contains at least one compression parameter.
  • One or more compression parameters can be set according to the needs and experience of the corresponding target scene. When there is only one compression parameter, it is called the default parameter. When multiple compression parameters are set, The compression parameters are provided with priority levels, for example, the priority levels of the first parameter, the second parameter, and the third parameter are sequentially increased or decreased.
  • the compressed image to be reviewed is presented to the user through an interface, so that the user can review the compressed image.
  • the target scenes corresponding to different websites require different compression parameters, or the size of the images uploaded each time may vary. There is a big difference. Some photos are only a few megabytes, and some photos are tens of megabytes. Using the same compression parameter to compress in the same mode may not meet the needs of users (such as sharpness requirements, etc.) or cause abnormalities.
  • Target website for example, in some scenarios where the size of the image is small, because the size of the image required by the target website is different each time or because the size of the image to be uploaded is different each time, Using the same compression parameter in the same mode may not meet the needs of the user or cause the upload to the target location not to be normal; in the case of the user being dissatisfied or unable to upload to the target location normally, the user can follow the preset operating instructions to indicate I am dissatisfied with the current compressed picture, and the review fails.
  • S104 When receiving the user's disapproval instruction, readjust the compression parameter, and recompress the original picture with the newly adjusted compression parameter and present it to the user for review.
  • the user inputs a picture compression instruction matching the target scene, and the compression instruction carries the original picture and compression mode information; this application compresses the original picture according to the compression mode information; presents the compressed picture to the user, In order to allow users to review the compressed pictures; in this way, users can check whether the compression effect is what they want. If it is not what the user wants, they can automatically adjust the compression parameters to recompress and review, so as to meet the user's personal needs and realize the user
  • the original picture is compressed by selecting the compression mode and compression parameters suitable for the target scene to adapt to a variety of different target scenes, avoiding the single defect of the existing compression software compression function, and convenient operation.
  • FIG. 2 is a flowchart of an embodiment of an artificial intelligence-based image compression method provided by this application.
  • S201 Receive a picture compression instruction input by a user, where the instruction carries an original picture and compression mode information, and the compression mode information includes a compression mode and at least two compression parameters with priority levels in the compression mode.
  • S202 Compress the original picture according to the compression mode and the compression parameter with the highest priority.
  • S203 Present the compressed picture to be reviewed to the user, so that the user can review the compressed picture.
  • the original picture is compressed according to the compression mode and the compression parameter with the highest priority, such as the first parameter, and the recompressed picture is re-presented to the user, so that the user can feel the compressed picture Re-audit, when receiving the user's failed audit instruction, because there are still parameters, according to the order of priority, select the second parameter in the picture compression instruction as the newly adjusted compression parameter, and use the newly adjusted compression parameter to
  • the original picture is recompressed, and the recompressed picture is re-presented to the user so that the user can review the compressed picture again.
  • FIG. 3 is a flowchart of another embodiment of the picture compression method provided by this application.
  • S302 Use the compression parameters that are gradually increased and/or decreased as the newly adjusted compression parameters, and recompress the original pictures respectively to obtain the compressed pictures to be selected;
  • the simultaneous presentation of the compressed pictures to be selected to the user means that the compressed pictures to be selected are presented to the user in the order of gradually increasing and/or decreasing compression parameters;
  • the preset interval may be to increase the value of the compression parameter or An interval formed by floating down a certain range, such as [compression parameter value*(1-10%), compression parameter value*(1+10%)], [compression parameter value*(1-10%) , Compression parameter value], [Compression parameter value, compression parameter value*(1+10%)], etc.;
  • the value of the preset step size can be divided into several small segments evenly, such as the preset interval 1%, 2%, 5% of, can be the preset step size and so on.
  • step S306 Return to step S305 when receiving the user's disapproval instruction.
  • the value of the compression parameter with the highest priority level is gradually increased and/or decreased according to the preset interval and preset step length; the compression parameter gradually increased and/or decreased as the newly adjusted compression parameter, Recompress and review the original pictures separately, and you can compress more pictures with different effects for users to choose the one that best meets their needs.
  • only one compression parameter is included in the compression mode, which is also called a default parameter; the step S102 of compressing the original picture according to the compression mode and the at least one compression parameter includes:
  • the original picture is compressed according to the compression mode and the default parameters in the compression mode.
  • the step of re-adjusting compression parameters when receiving a user's disapproval instruction, and recompressing the original picture with the newly adjusted compression parameters and presenting it to the user for review includes:
  • the original pictures are respectively recompressed to obtain the compressed pictures to be selected.
  • the user If the user is not satisfied with all the compressed pictures and issues a deselection instruction, after the step of presenting the compressed pictures to be selected to the user at the same time to obtain the user's selection of the compressed pictures, it also includes: when the user's deselection is received When instructing, issue a user-defined compression parameter instruction to the user, receive the user-defined compression parameter input, and re-compress the original image according to the user-defined compression parameter input and present it to the user for review; when the user’s review is received When the instruction is passed, upload the compressed picture confirmed by the user to the target location.
  • receiving the user's disapproval instruction return to the step to receive the custom compression parameter input by the user, and recompress the original picture according to the custom compression parameter input by the user and present it to the user for review.
  • the value of the default parameter is gradually increased and/or decreased according to a preset interval and a preset step; Using the gradually increasing and decreasing compression parameters as the newly adjusted compression parameters, the original pictures are recompressed separately, and more pictures with different effects can also be compressed for users to choose the pictures that best meet their needs.
  • FIG. 4 is a structural block diagram of the picture compression device provided by an embodiment of the application.
  • the device includes:
  • the instruction receiving module 1 is configured to receive a picture compression instruction input by a user, the instruction carrying an original picture and compression mode information, and the compression mode information includes a compression mode and at least one compression parameter in the compression mode;
  • the compression module 2 is configured to compress the original picture according to the compression mode and at least one compression parameter to obtain the compressed picture to be reviewed;
  • the presentation module 3 is used to present the compressed picture to be reviewed to the user, so that the user can review the compressed picture;
  • the adjustment parameter recompression module 5 is used to readjust the compression parameters when receiving a user's unapproved instruction, and recompress the original picture with the newly adjusted compression parameters and present it to the user for review;
  • the picture upload module 4 is used to upload the compressed picture confirmed by the user to the target location when the user's approval instruction is received.
  • the instruction receiving module 1 receives a picture compression instruction carrying compression mode information input by the user, and the compression module 2 responds to the picture compression instruction and compresses the original picture according to the compression mode and at least one compression parameter to obtain Compressed pictures to be reviewed; in this way, the user can input picture compression instructions that match the target scene, compress the original pictures according to the compression mode information, and get compressed pictures to be reviewed; the presentation module 3 presents the compressed pictures to be reviewed to the user, so that the user Review the compressed image; so that the user can check whether the compression effect is what they want, and if it is what the user wants, then confirm it.
  • the image upload module 4 receives the user’s approval instruction and uploads the compressed image confirmed by the user to the target Position, realize user-defined selection of compression mode suitable for the target scene and compression parameters to compress the original picture.
  • the target scenes corresponding to different websites require different compression parameters, or the size of the images uploaded each time may vary. There is a big difference. Some photos are only a few megabytes, and some photos are tens of megabytes. In the same mode, using the highest priority parameters for compression may not meet the needs of users (such as sharpness requirements, etc.) or may result in failure Normally upload to the target location such as the target website.
  • the priority level is adopted in the same mode Compression with the highest parameter may not meet the needs of users or may result in failure to upload to the target location normally.
  • the user can follow the preset operation instructions to indicate that the review is not passed.
  • the adjustment parameter recompression module 5 is used to re-adjust the compression parameters when receiving a user’s unapproved instruction, and recompress the original picture with the newly adjusted compression parameters; the presentation module 3 is used to recompress the recompressed picture It is presented to the user to enable the user to review the compressed image again, and then the image upload module 4 uploads the compressed image confirmed by the user to the target location when the user’s approval instruction is received.
  • different compression parameters can be changed and compressed to meet the requirements of users and satisfy users.
  • the compression mode carried in the image compression instruction input by the user received by the instruction receiving module 1 includes at least two compression parameters with priority levels;
  • the compression module 2 is configured to compress the original picture according to the compression mode and the compression parameter with the highest priority
  • the adjustment parameter recompression module 5 is configured to select the compression parameter of the next level as the newly adjusted compression parameter in the order of priority level, and recompress the original picture with the newly adjusted compression parameter and present it to the user for review.
  • the compression module 2 compresses the original picture according to the compression mode and the compression parameter with the highest priority, such as the first parameter; the adjustment parameter recompression module 5 receives the user’s review and does not When the instruction is passed, the second parameter can be replaced as a new compression parameter to recompress the original picture.
  • the image upload module 4 is used to upload the compressed image confirmed by the user to the target location when the user's approval instruction is received.
  • the device is based on the embodiment of FIG. 4, and the adjustment parameter recompression module 5 is also used to adjust the priority level when all the pictures compressed by the compression parameter in the picture compression instruction fail to pass the user's review.
  • the value of the highest compression parameter is gradually increased and/or decreased according to the preset interval and preset step length; the compression parameter after the gradual increase and/or decrease is used as the newly adjusted compression parameter, and the original image is recompressed respectively to obtain The compressed picture to be selected; the presentation module 3 is also used to present the compressed picture to be selected to the user at the same time, so as to obtain the user's choice of the compressed picture to be selected; the picture upload module 4 is also used to send the user a selection instruction confirmed by the user The selected compressed image is uploaded to the target location.
  • presenting the compressed pictures to be selected to the user at the same time means that the compressed pictures to be selected are arranged and presented to the user in the order of the size of the compression parameter after gradually increasing and/or decreasing.
  • FIG. 5 is a structural block diagram of an embodiment of a picture compression apparatus of this application.
  • This embodiment further includes a custom parameter acquisition and recompression module 6 on the basis of the embodiment in FIG. 4.
  • the custom parameter acquisition and recompression module 6 is used to issue a custom compression parameter acquisition instruction to the user when receiving a user's deselection instruction, receive the custom compression parameter instruction input by the user, and compress according to the custom compression input by the user The parameters recompress the original picture and present it to the user for review.
  • the picture upload module 4 is also used to upload the compressed picture confirmed by the user to the target location when the user's approval instruction is received.
  • the user can input the custom parameters by himself when the user is not satisfied with the audit once or after re-adjusting the parameters for many times, so that the compression is more in line with the target scene and the needs of the user.
  • the compression module 2 includes:
  • a priority compression unit configured to compress the original picture according to the compression mode and the compression parameter with the highest priority
  • the recompression unit is configured to select the compression parameter of the next level as the newly adjusted compression parameter in the order of priority level, and recompress the original picture with the newly adjusted compression parameter and present it to the user for review.
  • the image compression device based on artificial intelligence further includes:
  • the dynamic parameter adjustment module is used to gradually increase and/or decrease the value of the compression parameter with the highest priority according to the preset interval and preset step length if the image compressed by all the compression parameters fails to pass the user's review ;
  • the to-be-selected compressed picture determining module is used to use the gradually increasing and/or decreasing compression parameters as the newly adjusted compression parameters to re-compress the original pictures to obtain the to-be-selected compressed pictures;
  • the picture display module is used to present the compressed pictures to be selected to the user at the same time, so as to obtain the user's choice of the compressed pictures to be selected;
  • the picture transmission module is used to upload the compressed picture selected by the user to the target location when the selection instruction confirmed by the user is received.
  • FIG. 6 is a block diagram of the basic structure of the computer device 100 in the embodiment of the application.
  • the computer device 100 includes a memory 101, a processor 102, and a network interface 103 that are communicatively connected to each other through a system bus. It should be pointed out that FIG. 6 only shows the computer device 100 with the components 101-103, but it should be understood that it is not required to implement all the components shown, and more or fewer components may be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculation and/or information processing in accordance with pre-set or stored instructions.
  • Its hardware includes but is not limited to microprocessors, dedicated Integrated Circuit (Application Specific Integrated Circuit, ASIC), Programmable Gate Array (Field-Programmable Gate Array, FPGA), Digital Processor (Digital Signal Processor, DSP), embedded devices, etc.
  • ASIC Application Specific Integrated Circuit
  • ASIC Application Specific Integrated Circuit
  • FPGA Field-Programmable Gate Array
  • DSP Digital Processor
  • the computer device may be a computing device such as a desktop computer, a notebook, a palmtop computer, and a cloud server.
  • the computer device can interact with the user through a keyboard, a mouse, a remote control, a touch panel, or a voice control device.
  • the memory 101 includes at least one type of non-volatile readable storage medium, and the non-volatile readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), Random access memory (RAM), static random access memory (SRAM), read only memory (ROM), electrically erasable programmable read only memory (EEPROM), programmable read only memory (PROM), magnetic memory, magnetic disk, optical disk Wait.
  • the memory 101 may be an internal storage unit of the computer device 100, such as a hard disk or memory of the computer device 100.
  • the memory 101 may also be an external storage device of the computer device 100, such as a plug-in hard disk, a smart media card (SMC), and a secure digital device equipped on the computer device 100. (Secure Digital, SD) card, Flash Card, etc.
  • the memory 101 may also include both an internal storage unit of the computer device 100 and an external storage device thereof.
  • the memory 101 is generally used to store an operating system and various application software installed in the computer device 100, such as the above-mentioned artificial intelligence-based image compression method.
  • the memory 101 can also be used to temporarily store various types of data that have been output or will be output.
  • the processor 102 may be a central processing unit (Central Processing Unit, CPU), a controller, a microcontroller, a microprocessor, or other data processing chips in some embodiments.
  • the processor 102 is generally used to control the overall operation of the computer device 100.
  • the processor 102 is configured to execute computer-readable instructions or process data stored in the memory 101, such as computer-readable instructions for executing the above-mentioned artificial intelligence-based image compression method.
  • the network interface 103 may include a wireless network interface or a wired network interface.
  • the network interface 103 is generally used to establish a communication connection between the computer device 100 and other electronic devices.
  • This application also provides another embodiment, that is, to provide a computer non-volatile readable storage medium, the computer non-volatile readable storage medium stores computer readable instructions, and the computer readable instructions can Is executed by at least one processor, so that the at least one processor executes the steps of any one of the foregoing artificial intelligence-based image compression methods.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

An artificial intelligence-based image compression method and apparatus, a device, and a storage medium, the method comprising: receiving an image compression instruction inputted by a user (S101); compressing an original image according to a compression mode and at least one compression parameter to obtain a compressed image to be reviewed (S102); presenting the compressed image to be reviewed to the user such that the user reviews the compressed image (S103); when an instruction that review is not passed is received from the user, readjusting the compression parameter, re-compressing the original image using the newly adjusted compression parameter, and presenting the image to the user for review (S104); and when an instruction that review is passed is received from the user, uploading the compressed image confirmed by the user to a target location (S105). The described method allows a user to select a compression mode and compression parameter that match a target scene so as to compress an image to adapt to multiple different target scenes, and operation is easy; moreover, a parameter can be adjusted multiple times for re-compression, which can better meet the personal requirements of users.

Description

基于人工智能的图片压缩方法、装置、设备及存储介质Artificial intelligence-based image compression method, device, equipment and storage medium
本申请以2019年5月8日提交的申请号为201910383813.6,名称为“基于人工智能的图片压缩方法、装置、设备及存储介质”的中国发明专利申请为基础,并要求其优先权。This application is based on the Chinese invention patent application filed on May 8, 2019 with the application number 201910383813.6, titled "artificial intelligence-based image compression method, device, equipment and storage medium", and claims its priority.
技术领域Technical field
本申请实施例属于图片压缩技术领域,尤其涉及一种基于人工智能的图片压缩方法、装置、设备及存储介质。The embodiments of the present application belong to the technical field of image compression, and in particular, relate to an artificial intelligence-based image compression method, device, device, and storage medium.
背景技术Background technique
现有技术中的图片压缩软件适应的场景比较单一,例如说有的场景对图片质量要求高,有的场景需要图片尺寸很小,有的场景需要图片的内存很小,有些场景由于上传的图片尺寸不合需要对上传的图片进行缩放,在实现本申请的过程中,发明人意识到现有的实现方式至少存入如下问题:针对前述多种不同的场景只能寻找各种不同的压缩软件或者技术来适应各种不同的场景,用户操作非常不方便,而且只能一次压缩即使压缩的效果不好也无法再换参数进行压缩,无法很好的满足用户的个人需求。The picture compression software in the prior art adapts to a single scene. For example, some scenes require high picture quality, some scenes require a small picture size, some scenes require a small picture memory, and some scenes are due to uploaded pictures. The size of the uploaded picture is not suitable for the need to zoom. In the process of implementing this application, the inventor realizes that the existing implementation at least has the following problem: for the aforementioned multiple different scenarios, only a variety of different compression software or Technology to adapt to various different scenarios, user operation is very inconvenient, and can only be compressed once, even if the compression effect is not good, it is impossible to change the parameters for compression, which cannot well meet the personal needs of users.
发明内容Summary of the invention
为了解决上述问题,本申请实施例提供一种基于人工智能的图片压缩方法、装置、设备及存储介质,以解决现有技术中针对多种不同的场景需要多种压缩软件进行压缩图片导致操作不方便以及无法更换参数更好的满足用户的需求的问题。In order to solve the above problems, the embodiments of the present application provide an artificial intelligence-based image compression method, device, equipment, and storage medium to solve the problem that the prior art requires a variety of compression software to compress images for a variety of different scenarios. Convenience and inability to change parameters to better meet the needs of users.
第一方面,本申请实施例提供一种基于人工智能的图片压缩方法,包括:In the first aspect, an embodiment of the present application provides an artificial intelligence-based image compression method, including:
接收用户输入的图片压缩指令,所述指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数;Receiving a picture compression instruction input by a user, the instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片;Compress the original picture according to the compression mode and at least one compression parameter to obtain the compressed picture to be reviewed;
将待审核压缩图片呈现给用户,以使用户对压缩图片进行审核;Present the compressed image to be reviewed to the user so that the user can review the compressed image;
当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核;When receiving the user's approval failure instruction, readjust the compression parameters, recompress the original picture with the newly adjusted compression parameters and present it to the user for approval;
当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。When the user's approval instruction is received, the compressed image confirmed by the user is uploaded to the target location.
第二方面,本申请实施例提供一种基于人工智能的图片压缩装置,包括:In the second aspect, an embodiment of the present application provides an artificial intelligence-based image compression device, including:
指令接收模块,用于接收用户输入的图片压缩指令,所述指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数;An instruction receiving module, configured to receive a picture compression instruction input by a user, the instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
压缩模块,用于根据所述压缩模式以及至少一个压缩参数对原始图片进行 压缩,得到待审核压缩图片;A compression module, configured to compress the original picture according to the compression mode and at least one compression parameter to obtain a compressed picture to be reviewed;
呈现模块,用于将待审核压缩图片呈现给用户,以使用户对压缩得到的图片进行审核;The presentation module is used to present the compressed picture to be reviewed to the user, so that the user can review the compressed picture;
调整参数重压缩模块,用于当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核;The adjustment parameter recompression module is used to readjust the compression parameters when the user's review failure instruction is received, and recompress the original picture with the newly adjusted compression parameters and present it to the user for review;
图片上传模块,用于当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。The image upload module is used to upload the compressed image confirmed by the user to the target location when the user's approval instruction is received.
本申请的一些实施例还公开了一种计算机设备,所述存储器中存储有计算机可读指令,所述处理器执行所述计算机可读指令时实现如前所述基于人工智能的图片压缩方法的步骤。Some embodiments of the present application also disclose a computer device in which computer-readable instructions are stored in the memory, and when the processor executes the computer-readable instructions, it implements the aforementioned artificial intelligence-based image compression method. step.
本申请的一些实施例还公开了一种计算机非易失性可读存储介质,所述计算机非易失性可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如前所述基于人工智能的图片压缩方法的步骤。Some embodiments of the present application also disclose a computer nonvolatile readable storage medium, the computer nonvolatile readable storage medium stores computer readable instructions, and the computer readable instructions are executed by a processor When realizing the steps of the image compression method based on artificial intelligence as described above.
与现有技术相比,本申请公开的技术方案主要有以下有益效果:Compared with the prior art, the technical solution disclosed in this application mainly has the following beneficial effects:
本申请实施例中,用户通过输入与目标场景相匹配的图片压缩指令,该压缩指令携带有原始图片和压缩模式信息;本申请根据压缩模式信息对原始图片进行压缩;将压缩图片呈现给用户,以使用户对压缩图片进行审核;这样用户可以查看压缩效果是否是自己想要的,如果不是用户想要的,可以自动调整压缩参数重新压缩和审核,更大的满足用户的个人需求,实现用户在一个软件中通过选择适合目标场景的压缩模式以及压缩参数对原始图片进行压缩来适应多种不同的目标场景,避免现有的压缩软件压缩功能单一的缺陷,操作方便。In the embodiment of this application, the user inputs a picture compression instruction matching the target scene, and the compression instruction carries the original picture and compression mode information; this application compresses the original picture according to the compression mode information; presents the compressed picture to the user, In order to allow users to review the compressed pictures; in this way, users can check whether the compression effect is what they want. If it is not what the user wants, they can automatically adjust the compression parameters to recompress and review, so as to meet the user's personal needs and realize the user In one software, the original picture is compressed by selecting the compression mode and compression parameters suitable for the target scene to adapt to a variety of different target scenes, avoiding the single defect of the existing compression software compression function, and convenient operation.
附图说明Description of the drawings
为了更清楚地说明本申请的方案,下面将对实施例描述中所需要使用的附图作一个简单介绍,显而易见地,下面描述中的附图是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to explain the solution of the present application more clearly, the following will briefly introduce the drawings used in the description of the embodiments. Obviously, the drawings in the following description are some embodiments of the present application. As far as personnel are concerned, they can obtain other drawings based on these drawings without creative work.
图1为本申请实施例提供的图片压缩方法的流程框图;FIG. 1 is a flowchart of a picture compression method provided by an embodiment of the application;
图2为本申请提供的图片压缩方法的一种实施例的流程框图;FIG. 2 is a flowchart of an embodiment of a picture compression method provided by this application;
图3为本申请提供的图片压缩方法的另一种实施例的流程框图;FIG. 3 is a flowchart of another embodiment of a picture compression method provided by this application;
图4为本申请实施例提供的基于人工智能的图片压缩装置的结构框图;4 is a structural block diagram of an artificial intelligence-based image compression device provided by an embodiment of the application;
图5为本申请的基于人工智能的图片压缩装置的另一种实施例的结构框图;FIG. 5 is a structural block diagram of another embodiment of the image compression device based on artificial intelligence in this application;
图6为本申请实施例提供的计算机设备的硬件结构框图。Fig. 6 is a block diagram of the hardware structure of a computer device provided by an embodiment of the application.
具体实施方式Detailed ways
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述。除非另有定义,本文所使用的所有的技术和科学术语与属于本申请的技术领域的技术人员通常理解的含义相同。本文中在本申请的说明书中所使用的术语只是为了描 述具体的实施例的目的,不是旨在于限制本申请。本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别不同对象,而不是用于描述特定顺序。此外,术语“包括”和“具有”以及它们任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或单元的过程、方法、系统、产品或设备没有限定于已列出的步骤或单元,而是可选地还包括没有列出的步骤或单元,或可选地还包括对于这些过程、方法、产品或设备固有的其他步骤或单元。In order to enable those skilled in the art to better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the technical field of this application. The terms used in the specification of the application herein are only for the purpose of describing specific embodiments, and are not intended to limit the application. The terms "first", "second", etc. in the specification and claims of this application and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific sequence. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes unlisted steps or units, or optionally also includes Other steps or units inherent to these processes, methods, products or equipment.
在本文中提及“实施例”意味着,结合实施例描述的特定特征、结构或特性可以包含在本申请的至少一个实施例中。在说明书中的各个位置出现该短语并不一定均是指相同的实施例,也不是与其它实施例互斥的独立的或备选的实施例。本领域技术人员显式地和隐式地理解的是,本文所描述的实施例可以与其它实施例相结合。Reference to "embodiments" herein means that a specific feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. Those skilled in the art clearly and implicitly understand that the embodiments described herein can be combined with other embodiments.
本申请一实施例提供一种基于人工智能的图片压缩方法,如图1所示,图1为本申请实施例提供的图片压缩方法的流程框图;An embodiment of the present application provides an artificial intelligence-based image compression method, as shown in FIG. 1, which is a flowchart of the image compression method provided by an embodiment of the application;
所述方法包括:The method includes:
S101、接收用户输入的图片压缩指令,所述图片压缩指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数。S101. Receive a picture compression instruction input by a user, where the picture compression instruction carries an original picture and compression mode information, and the compression mode information includes a compression mode and at least one compression parameter in the compression mode.
具体的,预先设置多种适应不同的目标场景的图片压缩的压缩模式信息,压缩模式信息包含有压缩模式,在压缩模式下包含有至少一个压缩参数,并将这些压缩模式信息进行存储,以供用户在遇到不同的目标场景时可以以选择输入的方式或者手动输入的方式输入与目标场景相匹配的压缩模式信息。Specifically, a variety of compression mode information for picture compression adapted to different target scenes are preset, the compression mode information includes a compression mode, and the compression mode includes at least one compression parameter, and the compression mode information is stored for use When encountering different target scenes, the user can input the compression mode information that matches the target scene in a selective input mode or a manual input mode.
当压缩模式下只包含有一个压缩参数时,称为默认参数;When only one compression parameter is included in the compression mode, it is called the default parameter;
当所述压缩模式下包含至少两个压缩参数时,将压缩参数设置有优先等级。例如可以为第一参数、第二参数、第三参数优先级别依次递或者递减等等。When the compression mode includes at least two compression parameters, the compression parameters are set with priority levels. For example, the priority levels of the first parameter, the second parameter, and the third parameter may be successively increased or decreased.
其中,针对多种不同的目标场景,本实施例中设置的压缩模式包括但不限于以下模式:Among them, for a variety of different target scenarios, the compression mode set in this embodiment includes but is not limited to the following modes:
a.预设压缩比(压缩比=实际所占空间大小/压缩前所占空间大小)模式:a. Preset compression ratio (compression ratio = actual size of space occupied / size of space occupied before compression) mode:
适用的目标场景:现在很多网站几乎都可以上传图片,手机拍摄出来照片一般像素都比较高的高清图片,占用的存储空间也就大,每个用户都上传个3M的图片会导致占据很大的存储空间,所需要的硬盘、存储盘成本就会增加;另一方面,图片内存太大,同样的网速条件下会导致用户加载网页等待时间过长,降低用户的体验度,为了避免用户加载网页等待时间过长,要么提高网速要么减少图片内存,而网速成本过高,因此最好的方式是减少图片内存,可以将图片进行压缩,通过设置不同的压缩比,例如压缩比可以是但不限于1.0、0.5、0.3、0.1,该压缩模式下的压缩参数包含预设压缩比。该压缩模式下包含至少一个压缩参数,根据对应的目标场景的需要以及经验可以设置一个或者多个压缩参数,当只有一个压缩参数时,称为默认参数,当设有多个压缩参数的时候,所述压缩参数设有优先等级,例如第一参数优先等级最高,第二参数优先等级次之,第三参数优先等级最低。Applicable target scenarios: Nowadays, almost all websites can upload pictures. Photos taken by mobile phones are generally high-definition pictures with relatively high pixels, which take up a lot of storage space. Every user uploading a 3M picture will occupy a lot of space. Storage space, the cost of hard disks and storage disks will increase; on the other hand, the picture memory is too large, and the same network speed will cause users to wait too long to load web pages, reducing user experience, in order to avoid users loading Webpage waiting time is too long, either increase the network speed or reduce the image memory, and the cost of the network speed is too high, so the best way is to reduce the image memory, you can compress the image, by setting a different compression ratio, for example, the compression ratio can be But not limited to 1.0, 0.5, 0.3, 0.1, the compression parameters in this compression mode include a preset compression ratio. The compression mode contains at least one compression parameter. One or more compression parameters can be set according to the needs and experience of the corresponding target scene. When there is only one compression parameter, it is called the default parameter. When multiple compression parameters are set, The compression parameter has a priority level, for example, the first parameter has the highest priority, the second parameter has the second priority, and the third parameter has the lowest priority.
b.缩放模式:b. Zoom mode:
适用的目标场景:在某些场景例如说在一些网站上传一些像QQ、微信、微博以及APP中的一些头像小图标时,图片只是为了起到区分标识作用,使人一眼就知道这个头像是谁,根本不需要知道图片的具体内容信息,可以对图片进行尺寸的缩放;Applicable target scenarios: In some scenarios, such as uploading some small icons of avatars in QQ, WeChat, Weibo and APP on some websites, the pictures are only used for distinguishing and identifying, so that people can know the avatar at a glance. Who does not need to know the specific content information of the picture at all, and can scale the size of the picture;
包括等比缩放,非等比缩放。Including proportional zoom and non-constant zoom.
该压缩模式下的压缩参数包含缩放比例(压缩后的尺寸/压缩前的尺寸),例如80%、70%、50%、20%等等。The compression parameters in the compression mode include the scaling ratio (size after compression/size before compression), such as 80%, 70%, 50%, 20%, and so on.
该压缩模式下包含至少一个压缩参数,根据对应的目标场景的需要以及经验可以设置一个或者多个压缩参数,当只有一个压缩参数时,称为默认参数,当设有多个压缩参数的时候,所述压缩参数设有优先等级,例如第一参数、第二参数、第三参数优先等级依次递增或者递减。The compression mode contains at least one compression parameter. One or more compression parameters can be set according to the needs and experience of the corresponding target scene. When there is only one compression parameter, it is called the default parameter. When multiple compression parameters are set, The compression parameters are provided with priority levels, for example, the priority levels of the first parameter, the second parameter, and the third parameter are sequentially increased or decreased.
S102、根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片。S102. Compress the original picture according to the compression mode and at least one compression parameter to obtain a compressed picture to be reviewed.
S103、将待审核压缩图片呈现给用户,以使用户对压缩图片进行审核。S103. Present the compressed picture to be reviewed to the user, so that the user can review the compressed picture.
具体的,将待审核压缩图片通过界面形式呈现给用户,以使用户对压缩图片进行审核。Specifically, the compressed image to be reviewed is presented to the user through an interface, so that the user can review the compressed image.
在一些需要较小内存的场景中,由于不同的网站允许上传的图片的内存大小不一样,导致不同的网站所对应的目标场景需要的压缩参数不同,或者由于每次上传的图片大小可能会有较大差异,有的照片才几兆,而有的照片几十兆,在同一个模式下都采用同一个压缩参数进行压缩可能无法满足用户的需求(例如清晰度需求等)或者会导致无法正常上传至目标位置(目标网站);又例如在一些需要的图片尺寸较小的场景中,由于每次涉及的目标网站要求的图片尺寸的不同或者由于每次待上传的图片尺寸大小差别较大,在同一个模式下都采用同一个压缩参数可能无法满足用户的需求或者会导致无法正常上传至目标位置;在用户不满意或者无法正常上传至目标位置情况下,用户可以按照预设的操作指令表明自己对当前的压缩图片不满意,审核不通过。In some scenes that require smaller memory, because different websites allow different image memory sizes to be uploaded, the target scenes corresponding to different websites require different compression parameters, or the size of the images uploaded each time may vary. There is a big difference. Some photos are only a few megabytes, and some photos are tens of megabytes. Using the same compression parameter to compress in the same mode may not meet the needs of users (such as sharpness requirements, etc.) or cause abnormalities. Upload to the target location (target website); for example, in some scenarios where the size of the image is small, because the size of the image required by the target website is different each time or because the size of the image to be uploaded is different each time, Using the same compression parameter in the same mode may not meet the needs of the user or cause the upload to the target location not to be normal; in the case of the user being dissatisfied or unable to upload to the target location normally, the user can follow the preset operating instructions to indicate I am dissatisfied with the current compressed picture, and the review fails.
S104、当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。S104: When receiving the user's disapproval instruction, readjust the compression parameter, and recompress the original picture with the newly adjusted compression parameter and present it to the user for review.
S105、当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。S105: When the user's approval instruction is received, upload the compressed picture confirmed by the user to the target location.
本申请实施例中,用户通过输入与目标场景相匹配的图片压缩指令,该压缩指令携带有原始图片和压缩模式信息;本申请根据压缩模式信息对原始图片进行压缩;将压缩图片呈现给用户,以使用户对压缩图片进行审核;这样用户可以查看压缩效果是否是自己想要的,如果不是用户想要的,可以自动调整压缩参数重新压缩和审核,更大的满足用户的个人需求,实现用户在一个软件中通过选择适合目标场景的压缩模式以及压缩参数对原始图片进行压缩来适应多种不同的目标场景,避免现有的压缩软件压缩功能单一的缺陷,操作方便。In the embodiment of this application, the user inputs a picture compression instruction matching the target scene, and the compression instruction carries the original picture and compression mode information; this application compresses the original picture according to the compression mode information; presents the compressed picture to the user, In order to allow users to review the compressed pictures; in this way, users can check whether the compression effect is what they want. If it is not what the user wants, they can automatically adjust the compression parameters to recompress and review, so as to meet the user's personal needs and realize the user In one software, the original picture is compressed by selecting the compression mode and compression parameters suitable for the target scene to adapt to a variety of different target scenes, avoiding the single defect of the existing compression software compression function, and convenient operation.
参考图2,图2为本申请提供的基于人工智能的图片压缩方法的一种实施例的流程框图;Referring to FIG. 2, FIG. 2 is a flowchart of an embodiment of an artificial intelligence-based image compression method provided by this application;
在本实施例中,In this embodiment,
S201、接收用户输入的图片压缩指令,所述指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少两个具有优先级别的压缩参数。S201. Receive a picture compression instruction input by a user, where the instruction carries an original picture and compression mode information, and the compression mode information includes a compression mode and at least two compression parameters with priority levels in the compression mode.
S202、根据所述压缩模式以及优先级别最高的压缩参数对原始图片进行压缩。S202: Compress the original picture according to the compression mode and the compression parameter with the highest priority.
S203、将待审核压缩图片呈现给用户,以使用户对压缩图片进行审核。S203. Present the compressed picture to be reviewed to the user, so that the user can review the compressed picture.
S204、当接收到用户的审核不通过指令时,按优先级别的顺序选择下一级别的压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。S204. When receiving the user's disapproval instruction, select the compression parameter of the next level in the order of priority as the newly adjusted compression parameter, and recompress the original picture with the newly adjusted compression parameter and present it to the user Audit.
具体的,以压缩参数有两个为例,根据所述压缩模式以及优先级别最高的压缩参数例如第一参数对原始图片进行压缩,将重新压缩的图片重新呈现给用户,以使用户对压缩图片重新进行审核,当接收到用户的审核不通过的指令时,由于还有参数,按优先级别的顺序重新在图片压缩指令中选择第二参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩,将重新压缩的图片重新呈现给用户,以使用户对压缩图片重新进行审核。Specifically, taking two compression parameters as an example, the original picture is compressed according to the compression mode and the compression parameter with the highest priority, such as the first parameter, and the recompressed picture is re-presented to the user, so that the user can feel the compressed picture Re-audit, when receiving the user's failed audit instruction, because there are still parameters, according to the order of priority, select the second parameter in the picture compression instruction as the newly adjusted compression parameter, and use the newly adjusted compression parameter to The original picture is recompressed, and the recompressed picture is re-presented to the user so that the user can review the compressed picture again.
S205、当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。这样设置的好处是当采用优先级别最高的压缩参数原始图片进行压缩不能通过用户的审核时,更换压缩参数中的其他参数进行重新压缩,增加满足用户需求的机会。S205: When the user's approval instruction is received, upload the compressed picture confirmed by the user to the target location. The advantage of this setting is that when the original picture with the highest priority compression parameter is used for compression and cannot pass the user's review, other parameters in the compression parameter are replaced for recompression, which increases the chance of meeting user needs.
进一步的,请参阅图3,图3为本申请提供的图片压缩方法的另一种实施例的流程框图;Further, please refer to FIG. 3, which is a flowchart of another embodiment of the picture compression method provided by this application;
如果更换完所有的压缩参数仍然不能满足用户的需求,此时又没有其他参数可以更换,即按优先级别的顺序重新在图片压缩指令中选择压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩,将重新压缩的图片重新呈现给用户,以使用户对压缩图片重新进行审核的步骤之后,还包括:If all the compression parameters still cannot meet the needs of the user after replacing all the compression parameters, and there are no other parameters to replace at this time, that is, in the order of priority level, select the compression parameters as the newly adjusted compression parameters in the picture compression command, and use the newly adjusted compression After the parameter recompresses the original picture and re-presents the recompressed picture to the user so that the user can review the compressed picture again, it also includes:
S301、若采用所有的压缩参数所压缩的图片均无法通过用户的审核,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;S301: If the pictures compressed using all the compression parameters fail to pass the user's review, the value of the compression parameter with the highest priority level is gradually increased and/or decreased according to the preset interval and preset step length;
S302、以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;S302: Use the compression parameters that are gradually increased and/or decreased as the newly adjusted compression parameters, and recompress the original pictures respectively to obtain the compressed pictures to be selected;
S303、将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择。其中,所述将待选取压缩图片同时呈现给用户是将待选取压缩图片按照逐渐增加和/或递减后的压缩参数的大小顺序排列呈现给用户;预设区间可以为将压缩参数的值向上或者向下浮动一定的范围所形成的区间,例如[压缩参数的值*(1-10%),压缩参数的值*(1+10%)]、[压缩参数的值*(1-10%),压缩参数的值]、[压缩参数的值,压缩参数的值*(1+10%)]等等;预设步长的值可以为将预设区间平均分成若干个小段,例如预设区间的1%、2%、5%都可以为预设步长等等。S303: Present the compressed picture to be selected to the user at the same time, so as to obtain the user's choice of the compressed picture to be selected. Wherein, the simultaneous presentation of the compressed pictures to be selected to the user means that the compressed pictures to be selected are presented to the user in the order of gradually increasing and/or decreasing compression parameters; the preset interval may be to increase the value of the compression parameter or An interval formed by floating down a certain range, such as [compression parameter value*(1-10%), compression parameter value*(1+10%)], [compression parameter value*(1-10%) , Compression parameter value], [Compression parameter value, compression parameter value*(1+10%)], etc.; the value of the preset step size can be divided into several small segments evenly, such as the preset interval 1%, 2%, 5% of, can be the preset step size and so on.
假如用户对所有压缩图片均不满意发出取消选取指令,则If the user is dissatisfied with all compressed pictures and issues a deselect command, then
S304、当接收到用户取消选取指令时,向用户发出获取自定义压缩参数指令;S304: When the user cancels the selection instruction, issue an instruction to acquire the custom compression parameter to the user;
S305、接收用户输入的自定义压缩参数,根据用户输入的自定义压缩参数对原始图片重新进行压缩并呈现给所述用户审核。S305. Receive the custom compression parameter input by the user, and recompress the original picture according to the custom compression parameter input by the user and present it to the user for review.
S306、当接收到用户的审核不通过指令时返回步骤S305;S306: Return to step S305 when receiving the user's disapproval instruction.
S105、当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。S105: When the user's approval instruction is received, upload the compressed picture confirmed by the user to the target location.
假如用户发出确认选取的指令时,则If the user issues an instruction to confirm the selection, then
S307、当接收到用户确认的选取指令时,将用户选取的压缩图片上传至目标位置。S307: When receiving the selection instruction confirmed by the user, upload the compressed picture selected by the user to the target location.
在本实施例中,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩和审核,可以压缩出更多效果不同的图片供用户选择出最符合自己需要的。In this embodiment, the value of the compression parameter with the highest priority level is gradually increased and/or decreased according to the preset interval and preset step length; the compression parameter gradually increased and/or decreased as the newly adjusted compression parameter, Recompress and review the original pictures separately, and you can compress more pictures with different effects for users to choose the one that best meets their needs.
可选的,在一些其他实施例中,压缩模式下只包含有一个压缩参数,也称为默认参数;所述根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩的步骤S102包括:Optionally, in some other embodiments, only one compression parameter is included in the compression mode, which is also called a default parameter; the step S102 of compressing the original picture according to the compression mode and the at least one compression parameter includes:
根据所述压缩模式以及所述压缩模式下的默认参数对原始图片进行压缩。The original picture is compressed according to the compression mode and the default parameters in the compression mode.
所述当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤包括:The step of re-adjusting compression parameters when receiving a user's disapproval instruction, and recompressing the original picture with the newly adjusted compression parameters and presenting it to the user for review includes:
将所述默认参数的值按照预设区间和预设步长进行逐渐增加和/或递减;Gradually increasing and/or decreasing the value of the default parameter according to the preset interval and the preset step length;
以逐渐增加和递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片。Taking the gradually increasing and decreasing compression parameters as the newly adjusted compression parameters, the original pictures are respectively recompressed to obtain the compressed pictures to be selected.
将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择。Present the compressed pictures to be selected to the user at the same time to obtain the user's choice of compressed pictures to be selected.
当接收到用户的确认选取指令时,将用户选取的压缩图片上传至目标位置。When receiving the user's confirmation selection instruction, upload the compressed picture selected by the user to the target location.
假如用户对所有压缩图片均不满意发出取消选取指令,则所述将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择的步骤之后,还包括:当接收到用户的取消选取指令时,向用户发出获取自定义压缩参数指令,接收用户输入的自定义压缩参数,根据用户输入的自定义压缩参数对原始图片重新进行压缩并呈现给所述用户审核;当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。当接收到用户的审核不通过指令时返回步骤接收用户输入的自定义压缩参数,根据用户输入的自定义压缩参数对原始图片重新进行压缩并呈现给所述用户审核。If the user is not satisfied with all the compressed pictures and issues a deselection instruction, after the step of presenting the compressed pictures to be selected to the user at the same time to obtain the user's selection of the compressed pictures, it also includes: when the user's deselection is received When instructing, issue a user-defined compression parameter instruction to the user, receive the user-defined compression parameter input, and re-compress the original image according to the user-defined compression parameter input and present it to the user for review; when the user’s review is received When the instruction is passed, upload the compressed picture confirmed by the user to the target location. When receiving the user's disapproval instruction, return to the step to receive the custom compression parameter input by the user, and recompress the original picture according to the custom compression parameter input by the user and present it to the user for review.
在本实施例中,压缩模式下只包含有一个压缩参数时当接收到用户的审核不通过指令时,通过将默认参数的值按照预设区间和预设步长进行逐渐增加和/或递减;以逐渐增加和递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,同样可以压缩出更多效果不同的图片供用户选择出最符合自己需要的图片。In this embodiment, when only one compression parameter is included in the compression mode, when a user's review failure instruction is received, the value of the default parameter is gradually increased and/or decreased according to a preset interval and a preset step; Using the gradually increasing and decreasing compression parameters as the newly adjusted compression parameters, the original pictures are recompressed separately, and more pictures with different effects can also be compressed for users to choose the pictures that best meet their needs.
当接收到用户取消选取指令时,即用户对所有压缩图片均不满意发出取消选取指令时,向用户发出获取自定义压缩参数指令;When a user cancel selection instruction is received, that is, when the user is not satisfied with all the compressed pictures and the cancel selection instruction is issued, the user is issued an instruction to obtain custom compression parameters;
接收用户输入的自定义压缩参数指令,根据用户输入的自定义压缩参数对原始图片重新进行压缩并呈现给所述用户审核;Receiving a custom compression parameter instruction input by the user, and recompressing the original image according to the custom compression parameter input by the user and presenting it to the user for review;
当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置;When receiving the user's approval instruction, upload the compressed image confirmed by the user to the target location;
当用户对压缩模式本身预设的压缩参数压缩出来的效果不满意时,可以选择自己输入压缩参数,这样设置的好处可以更好的适应用户的需求,提升用户获取到合格的压缩图片的概率。When the user is not satisfied with the compression effect of the preset compression parameters of the compression mode itself, they can choose to input the compression parameters by themselves. The benefits of this setting can better adapt to the user's needs and increase the probability of the user obtaining qualified compressed pictures.
本申请一实施例还提供一种基于人工智能的图片压缩装置,如图4所示,图4为本申请实施例提供的图片压缩装置的结构框图。所述装置包括:An embodiment of the present application also provides a picture compression device based on artificial intelligence, as shown in FIG. 4, which is a structural block diagram of the picture compression device provided by an embodiment of the application. The device includes:
指令接收模块1,用于接收用户输入的图片压缩指令,所述指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数;The instruction receiving module 1 is configured to receive a picture compression instruction input by a user, the instruction carrying an original picture and compression mode information, and the compression mode information includes a compression mode and at least one compression parameter in the compression mode;
压缩模块2,用于根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片;The compression module 2 is configured to compress the original picture according to the compression mode and at least one compression parameter to obtain the compressed picture to be reviewed;
呈现模块3,用于将待审核压缩图片呈现给用户,以使用户对压缩得到的图片进行审核;The presentation module 3 is used to present the compressed picture to be reviewed to the user, so that the user can review the compressed picture;
调整参数重压缩模块5,用于当接收到用户的审核不通过的指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核;The adjustment parameter recompression module 5 is used to readjust the compression parameters when receiving a user's unapproved instruction, and recompress the original picture with the newly adjusted compression parameters and present it to the user for review;
图片上传模块4,用于当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。The picture upload module 4 is used to upload the compressed picture confirmed by the user to the target location when the user's approval instruction is received.
本申请实施例中指令接收模块1接收用户输入的携带有压缩模式信息的图片压缩指令,压缩模块2响应所述图片压缩指令,根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片;这样用户可以输入与目标场景相匹配的图片压缩指令,根据压缩模式信息对原始图片进行压缩,得到待审核压缩图片;呈现模块3将待审核压缩图片呈现给用户,以使用户对压缩图片进行审核;这样用户可以查看压缩效果是否是自己想要的,如果是用户想要的则确认通过,图片上传模块4接收到用户的审核通过指令后将用户确认的压缩图片上传至目标位置,实现用户自定义选择适合目标场景的压缩模式以及压缩参数对原始图片进行压缩。In the embodiment of the present application, the instruction receiving module 1 receives a picture compression instruction carrying compression mode information input by the user, and the compression module 2 responds to the picture compression instruction and compresses the original picture according to the compression mode and at least one compression parameter to obtain Compressed pictures to be reviewed; in this way, the user can input picture compression instructions that match the target scene, compress the original pictures according to the compression mode information, and get compressed pictures to be reviewed; the presentation module 3 presents the compressed pictures to be reviewed to the user, so that the user Review the compressed image; so that the user can check whether the compression effect is what they want, and if it is what the user wants, then confirm it. The image upload module 4 receives the user’s approval instruction and uploads the compressed image confirmed by the user to the target Position, realize user-defined selection of compression mode suitable for the target scene and compression parameters to compress the original picture.
在一些需要较小内存的场景中,由于不同的网站允许上传的图片的内存大小不一样,导致不同的网站所对应的目标场景需要的压缩参数不同,或者由于每次上传的图片大小可能会有较大差异,有的照片才几兆,而有的照片几十兆,在同一个模式下都采用优先级别最高的参数进行压缩可能无法满足用户的需求(例如清晰度需求等)或者会导致无法正常上传至目标位置例如目标网站。又或者在一些需要的图片尺寸较小的场景中,由于每次涉及的目标网站要求的图片尺寸的不同或者由于每次待上传的图片尺寸大小差别较大,在同一个模式下都采用优先级别最高的参数进行压缩可能无法满足用户的需求或者会导致无法正常上传至目标位置。在用户不满意或者无法正常上传至目标位置的情况下,用户可以按照预设的操作指令表示审核不通过。In some scenes that require smaller memory, because different websites allow different image memory sizes to be uploaded, the target scenes corresponding to different websites require different compression parameters, or the size of the images uploaded each time may vary. There is a big difference. Some photos are only a few megabytes, and some photos are tens of megabytes. In the same mode, using the highest priority parameters for compression may not meet the needs of users (such as sharpness requirements, etc.) or may result in failure Normally upload to the target location such as the target website. Or in some scenes where the size of the image required is small, due to the difference in the size of the image required by the target website each time or because the size of the image to be uploaded each time is different, the priority level is adopted in the same mode Compression with the highest parameter may not meet the needs of users or may result in failure to upload to the target location normally. In the case that the user is not satisfied or cannot upload to the target location normally, the user can follow the preset operation instructions to indicate that the review is not passed.
调整参数重压缩模块5用于当接收到用户的审核不通过的指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩;呈现模块3,用于将重新压缩的图片重新呈现给用户,以使用户对压缩图片重新进行审核,然后由图片上传模块4在接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。通过设置调整参数重压缩模块5,实现更换不同的压缩参数进行压缩达到符合用户的要求,使用户满意的目的。The adjustment parameter recompression module 5 is used to re-adjust the compression parameters when receiving a user’s unapproved instruction, and recompress the original picture with the newly adjusted compression parameters; the presentation module 3 is used to recompress the recompressed picture It is presented to the user to enable the user to review the compressed image again, and then the image upload module 4 uploads the compressed image confirmed by the user to the target location when the user’s approval instruction is received. By setting the adjustment parameter re-compression module 5, different compression parameters can be changed and compressed to meet the requirements of users and satisfy users.
具体的,在一些可行的实施例中,指令接收模块1接收到的用户输入的图片压缩指令中携带的压缩模式下包含至少两个具有优先级别的压缩参数;Specifically, in some feasible embodiments, the compression mode carried in the image compression instruction input by the user received by the instruction receiving module 1 includes at least two compression parameters with priority levels;
此时,压缩模块2用于根据所述压缩模式以及优先级别最高的压缩参数对原始图片进行压缩;At this time, the compression module 2 is configured to compress the original picture according to the compression mode and the compression parameter with the highest priority;
调整参数重压缩模块5用于按优先级别的顺序选择下一级别的压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The adjustment parameter recompression module 5 is configured to select the compression parameter of the next level as the newly adjusted compression parameter in the order of priority level, and recompress the original picture with the newly adjusted compression parameter and present it to the user for review.
更具体的,以压缩参数有两个为例,压缩模块2根据所述压缩模式以及优先级别最高的压缩参数例如第一参数对原始图片进行压缩;调整参数重压缩模块5接收到用户的审核不通过的指令时,可以更换第二参数作为新的压缩参数对原始图片进行重新压缩。More specifically, taking two compression parameters as an example, the compression module 2 compresses the original picture according to the compression mode and the compression parameter with the highest priority, such as the first parameter; the adjustment parameter recompression module 5 receives the user’s review and does not When the instruction is passed, the second parameter can be replaced as a new compression parameter to recompress the original picture.
可能出现的一种情况,用户审核通过并发出审核通过的指令,图片上传模块4用于当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。There may be a situation where the user has passed the review and issued an instruction for approval, and the image upload module 4 is used to upload the compressed image confirmed by the user to the target location when the user's approval instruction is received.
本申请的基于人工智能的图片压缩装置由于压缩模式下的压缩参数个数有限,可能会出现一直更换参数直到所有的压缩参数都被使用过但是所有压缩图片都无法通过用户的审核,因此在本实施例中,所述装置在图4的实施例的基础上,调整参数重压缩模块5还用于在采用图片压缩指令中的压缩参数所压缩的图片均无法通过用户的审核时,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;呈现模块3还用于将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择;图片上传模块4还用于当接收到用户确认的选取指令时,将用户选取的压缩图片上传至目标位置。Due to the limited number of compression parameters in the compression mode of the artificial intelligence-based image compression device of this application, it may happen that the parameters are changed until all the compression parameters have been used, but all the compressed images cannot pass the user’s review. In the embodiment, the device is based on the embodiment of FIG. 4, and the adjustment parameter recompression module 5 is also used to adjust the priority level when all the pictures compressed by the compression parameter in the picture compression instruction fail to pass the user's review. The value of the highest compression parameter is gradually increased and/or decreased according to the preset interval and preset step length; the compression parameter after the gradual increase and/or decrease is used as the newly adjusted compression parameter, and the original image is recompressed respectively to obtain The compressed picture to be selected; the presentation module 3 is also used to present the compressed picture to be selected to the user at the same time, so as to obtain the user's choice of the compressed picture to be selected; the picture upload module 4 is also used to send the user a selection instruction confirmed by the user The selected compressed image is uploaded to the target location.
其中,将待选取压缩图片同时呈现给用户是将待选取压缩图片按照逐渐增加和/或递减后的压缩参数的大小顺序排列呈现给用户。Wherein, presenting the compressed pictures to be selected to the user at the same time means that the compressed pictures to be selected are arranged and presented to the user in the order of the size of the compression parameter after gradually increasing and/or decreasing.
请参阅图5,图5为本申请的图片压缩装置的一种实施例的结构框图。Please refer to FIG. 5. FIG. 5 is a structural block diagram of an embodiment of a picture compression apparatus of this application.
本实施例在图4的实施例的基础上还进一步包括自定义参数获取重压缩模块6。This embodiment further includes a custom parameter acquisition and recompression module 6 on the basis of the embodiment in FIG. 4.
具体的,自定义参数获取重压缩模块6用于当接收到用户的取消选取指令时,向用户发出获取自定义压缩参数指令,接收用户输入的自定义压缩参数指令,根据用户输入的自定义压缩参数对原始图片进行重新压缩并呈现给所述用户审核。Specifically, the custom parameter acquisition and recompression module 6 is used to issue a custom compression parameter acquisition instruction to the user when receiving a user's deselection instruction, receive the custom compression parameter instruction input by the user, and compress according to the custom compression input by the user The parameters recompress the original picture and present it to the user for review.
图片上传模块4还用于当接收到用户的审核通过指令时,将用户确认的压 缩图片上传至目标位置。The picture upload module 4 is also used to upload the compressed picture confirmed by the user to the target location when the user's approval instruction is received.
本实施例使用户在一次审核不满意或者多次重新调整参数后仍然审核不满意时可以自行输入自定义参数,使得压缩更符合目标场景和用户的需求。In this embodiment, the user can input the custom parameters by himself when the user is not satisfied with the audit once or after re-adjusting the parameters for many times, so that the compression is more in line with the target scene and the needs of the user.
进一步地,压缩模块2包括:Further, the compression module 2 includes:
优先压缩单元,用于根据所述压缩模式以及优先级别最高的压缩参数对原始图片进行压缩;A priority compression unit, configured to compress the original picture according to the compression mode and the compression parameter with the highest priority;
重新压缩单元,用于按优先级别的顺序选择下一级别的压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The recompression unit is configured to select the compression parameter of the next level as the newly adjusted compression parameter in the order of priority level, and recompress the original picture with the newly adjusted compression parameter and present it to the user for review.
进一步地,该基于人工智能的图片压缩装置还包括:Further, the image compression device based on artificial intelligence further includes:
动态调参模块,用于若采用所有的压缩参数所压缩的图片均无法通过用户的审核时,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;The dynamic parameter adjustment module is used to gradually increase and/or decrease the value of the compression parameter with the highest priority according to the preset interval and preset step length if the image compressed by all the compression parameters fails to pass the user's review ;
待选取压缩图片确定模块,用于以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;The to-be-selected compressed picture determining module is used to use the gradually increasing and/or decreasing compression parameters as the newly adjusted compression parameters to re-compress the original pictures to obtain the to-be-selected compressed pictures;
图片展示模块,用于将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择;The picture display module is used to present the compressed pictures to be selected to the user at the same time, so as to obtain the user's choice of the compressed pictures to be selected;
图片传输模块,用于当接收到用户确认的选取指令时,将用户选取的压缩图片上传至目标位置。The picture transmission module is used to upload the compressed picture selected by the user to the target location when the selection instruction confirmed by the user is received.
为了解决上述技术问题,本申请的一实施例还公开了一种计算机设备。具体请参阅图6,为本申请实施例中计算机设备100基本结构框图。In order to solve the above technical problems, an embodiment of the present application also discloses a computer device. For details, please refer to FIG. 6, which is a block diagram of the basic structure of the computer device 100 in the embodiment of the application.
如图6中所示意的,所述计算机设备100包括通过系统总线相互通信连接存储器101、处理器102、网络接口103。需要指出的是,图6中仅示出了具有组件101-103的计算机设备100,但是应理解的是,并不要求实施所有示出的组件,可以替代的实施更多或者更少的组件。其中,本技术领域技术人员可以理解,这里的计算机设备是一种能够按照事先设定或存储的指令,自动进行数值计算和/或信息处理的设备,其硬件包括但不限于微处理器、专用集成电路(Application Specific Integrated Circuit,ASIC)、可编程门阵列(Field-Programmable Gate Array,FPGA)、数字处理器(Digital Signal Processor,DSP)、嵌入式设备等。As shown in FIG. 6, the computer device 100 includes a memory 101, a processor 102, and a network interface 103 that are communicatively connected to each other through a system bus. It should be pointed out that FIG. 6 only shows the computer device 100 with the components 101-103, but it should be understood that it is not required to implement all the components shown, and more or fewer components may be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculation and/or information processing in accordance with pre-set or stored instructions. Its hardware includes but is not limited to microprocessors, dedicated Integrated Circuit (Application Specific Integrated Circuit, ASIC), Programmable Gate Array (Field-Programmable Gate Array, FPGA), Digital Processor (Digital Signal Processor, DSP), embedded devices, etc.
所述计算机设备可以是桌上型计算机、笔记本、掌上电脑及云端服务器等计算设备。所述计算机设备可以与用户通过键盘、鼠标、遥控器、触摸板或声控设备等方式进行人机交互。The computer device may be a computing device such as a desktop computer, a notebook, a palmtop computer, and a cloud server. The computer device can interact with the user through a keyboard, a mouse, a remote control, a touch panel, or a voice control device.
所述存储器101至少包括一种类型的非易失性可读存储介质,所述非易失性可读存储介质包括闪存、硬盘、多媒体卡、卡型存储器(例如,SD或DX存储器等)、随机访问存储器(RAM)、静态随机访问存储器(SRAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、可编程只读存储器(PROM)、磁性存储器、磁盘、光盘等。在一些实施例中,所述存储器101可以是所述计算机设备100的内部存储单元,例如该计算机设备100的硬盘或内存。在另一些实施例中,所述存储器101也可以是所述计算机设备100的外部存储设备,例如该计算机 设备100上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。当然,所述存储器101还可以既包括所述计算机设备100的内部存储单元也包括其外部存储设备。本实施例中,所述存储器101通常用于存储安装于所述计算机设备100的操作系统和各类应用软件,例如上述基于人工智能的图片压缩方法等。此外,所述存储器101还可以用于暂时地存储已经输出或者将要输出的各类数据。The memory 101 includes at least one type of non-volatile readable storage medium, and the non-volatile readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), Random access memory (RAM), static random access memory (SRAM), read only memory (ROM), electrically erasable programmable read only memory (EEPROM), programmable read only memory (PROM), magnetic memory, magnetic disk, optical disk Wait. In some embodiments, the memory 101 may be an internal storage unit of the computer device 100, such as a hard disk or memory of the computer device 100. In other embodiments, the memory 101 may also be an external storage device of the computer device 100, such as a plug-in hard disk, a smart media card (SMC), and a secure digital device equipped on the computer device 100. (Secure Digital, SD) card, Flash Card, etc. Of course, the memory 101 may also include both an internal storage unit of the computer device 100 and an external storage device thereof. In this embodiment, the memory 101 is generally used to store an operating system and various application software installed in the computer device 100, such as the above-mentioned artificial intelligence-based image compression method. In addition, the memory 101 can also be used to temporarily store various types of data that have been output or will be output.
所述处理器102在一些实施例中可以是中央处理器(Central Processing Unit,CPU)、控制器、微控制器、微处理器、或其他数据处理芯片。该处理器102通常用于控制所述计算机设备100的总体操作。本实施例中,所述处理器102用于运行所述存储器101中存储的计算机可读指令或者处理数据,例如运行上述基于人工智能的图片压缩方法的计算机可读指令。The processor 102 may be a central processing unit (Central Processing Unit, CPU), a controller, a microcontroller, a microprocessor, or other data processing chips in some embodiments. The processor 102 is generally used to control the overall operation of the computer device 100. In this embodiment, the processor 102 is configured to execute computer-readable instructions or process data stored in the memory 101, such as computer-readable instructions for executing the above-mentioned artificial intelligence-based image compression method.
所述网络接口103可包括无线网络接口或有线网络接口,该网络接口103通常用于在所述计算机设备100与其他电子设备之间建立通信连接。The network interface 103 may include a wireless network interface or a wired network interface. The network interface 103 is generally used to establish a communication connection between the computer device 100 and other electronic devices.
本申请还提供了另一种实施例,即提供一种计算机非易失性可读存储介质,所述计算机非易失性可读存储介质存储有计算机可读指令,所述计算机可读指令可被至少一个处理器执行,以使所述至少一个处理器执行上述任意一种基于人工智能的图片压缩方法的步骤。This application also provides another embodiment, that is, to provide a computer non-volatile readable storage medium, the computer non-volatile readable storage medium stores computer readable instructions, and the computer readable instructions can Is executed by at least one processor, so that the at least one processor executes the steps of any one of the foregoing artificial intelligence-based image compression methods.
通过以上的实施例的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施例。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the method of the above embodiments can be implemented by means of software plus the necessary general hardware platform, of course, through hardware, but in many cases the former is better.的实施例。 Example. Based on this understanding, the technical solution of this application essentially or the part that contributes to the existing technology can be embodied in the form of a software product, and the computer software product is stored in a storage medium (such as ROM/RAM, magnetic disk, The optical disc) includes several instructions to enable a terminal device (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the method described in each embodiment of the present application.
显然,以上所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例,附图中给出了本申请的较佳实施例,但并不限制本申请的专利范围。本申请可以以许多不同的形式来实现,相反地,提供这些实施例的目的是使对本申请的公开内容的理解更加透彻全面。尽管参照前述实施例对本申请进行了详细的说明,对于本领域的技术人员来而言,其依然可以对前述各具体实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等效替换。凡是利用本申请说明书及附图内容所做的等效结构,直接或间接运用在其他相关的技术领域,均同理在本申请专利保护范围之内。Obviously, the embodiments described above are only a part of the embodiments of the present application, rather than all of the embodiments. The drawings show preferred embodiments of the present application, but do not limit the patent scope of the present application. This application can be implemented in many different forms. On the contrary, the purpose of providing these examples is to make the understanding of the disclosure of this application more thorough and comprehensive. Although the application has been described in detail with reference to the foregoing embodiments, for those skilled in the art, they can still modify the technical solutions described in the foregoing specific embodiments, or equivalently replace some of the technical features. . All equivalent structures made using the contents of the description and drawings of this application, directly or indirectly used in other related technical fields, are similarly within the scope of patent protection of this application.

Claims (20)

  1. 一种基于人工智能的图片压缩方法,其特征在于,包括:An artificial intelligence-based image compression method, characterized in that it includes:
    接收用户输入的图片压缩指令,所述图片压缩指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数;Receiving a picture compression instruction input by a user, the picture compression instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
    根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片;Compress the original picture according to the compression mode and at least one compression parameter to obtain the compressed picture to be reviewed;
    将待审核压缩图片呈现给用户,以使用户对压缩图片进行审核;Present the compressed image to be reviewed to the user so that the user can review the compressed image;
    当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核;When receiving the user's approval failure instruction, readjust the compression parameters, recompress the original picture with the newly adjusted compression parameters and present it to the user for approval;
    当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。When the user's approval instruction is received, the compressed image confirmed by the user is uploaded to the target location.
  2. 根据权利要求1所述的基于人工智能的图片压缩方法,其特征在于,所述压缩模式下包含至少两个具有优先级别的压缩参数;所述根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩的步骤包括:The artificial intelligence-based image compression method according to claim 1, wherein the compression mode includes at least two compression parameters with priority levels; the compression mode and the at least one compression parameter are used to compare the original image The steps to compress include:
    根据所述压缩模式以及优先级别最高的压缩参数对原始图片进行压缩;Compress the original picture according to the compression mode and the compression parameter with the highest priority;
    所述重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤包括:The step of re-adjusting the compression parameters, re-compressing the original picture with the newly adjusted compression parameters and presenting it to the user for review includes:
    按优先级别的顺序选择下一级别的压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The compression parameter of the next level is selected in the order of priority level as the newly adjusted compression parameter, and the original picture is recompressed with the newly adjusted compression parameter and presented to the user for review.
  3. 根据权利要求2所述的基于人工智能的图片压缩方法,其特征在于,所述重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤之后,还包括:The artificial intelligence-based image compression method according to claim 2, wherein after the step of re-adjusting the compression parameters, recompressing the original image with the newly adjusted compression parameters and presenting it to the user for review, further include:
    若采用所有的压缩参数所压缩的图片均无法通过用户的审核时,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;If the pictures compressed with all the compression parameters fail to pass the user's review, the value of the compression parameter with the highest priority is gradually increased and/or decreased according to the preset interval and preset step length;
    以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;Using the gradually increasing and/or decreasing compression parameters as the newly adjusted compression parameters, recompress the original pictures respectively to obtain the compressed pictures to be selected;
    将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择;Present the compressed pictures to be selected to the user at the same time to obtain the user's choice of compressed pictures to be selected;
    当接收到用户确认的选取指令时,将用户选取的压缩图片上传至目标位置。When receiving the selection instruction confirmed by the user, upload the compressed picture selected by the user to the target location.
  4. 根据权利要求3所述的基于人工智能的图片压缩方法,其特征在于,所述将待选取压缩图片同时呈现给用户是将待选取压缩图片按照逐渐增加和/或递减后的压缩参数的大小顺序排列呈现给用户。The artificial intelligence-based picture compression method according to claim 3, wherein the simultaneous presentation of the compressed pictures to be selected to the user is to present the compressed pictures to be selected in the order of gradually increasing and/or decreasing compression parameters. The arrangement is presented to the user.
  5. 根据权利要求3所述的基于人工智能的图片压缩方法,其特征在于,所述将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择的步骤之后,还包括:The artificial intelligence-based image compression method according to claim 3, wherein after the step of simultaneously presenting the compressed image to be selected to the user to obtain the user's selection of the compressed image to be selected, the method further comprises:
    当接收到用户的取消选取指令时,向用户发出获取自定义压缩参数指令;When receiving the user's deselection instruction, issue the user-defined compression parameter instruction to the user;
    接收用户输入的自定义压缩参数,根据用户输入的自定义压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The custom compression parameter input by the user is received, and the original picture is recompressed according to the custom compression parameter input by the user and presented to the user for review.
  6. 根据权利要求1所述的基于人工智能的图片压缩方法,其特征在于,所 述压缩模式下只包含有一个压缩参数;所述当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤包括:The artificial intelligence-based image compression method according to claim 1, wherein said compression mode contains only one compression parameter; said when receiving a user’s approval failure instruction, readjust the compression parameters to The steps of recompressing the original picture with the newly adjusted compression parameters and presenting it to the user for review include:
    将所述压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;Gradually increasing and/or decreasing the value of the compression parameter according to a preset interval and a preset step length;
    以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;Using the gradually increasing and/or decreasing compression parameters as the newly adjusted compression parameters, recompress the original pictures respectively to obtain the compressed pictures to be selected;
    将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择;Present the compressed pictures to be selected to the user at the same time to obtain the user's choice of compressed pictures to be selected;
    当接收到用户的确认选取指令时,将用户选取的压缩图片上传至目标位置。When receiving the user's confirmation selection instruction, upload the compressed picture selected by the user to the target location.
  7. 根据权利要求6所述的基于人工智能的图片压缩方法,其特征在于,所述将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择的步骤之后,还包括:The artificial intelligence-based picture compression method according to claim 6, wherein after the step of simultaneously presenting the compressed pictures to be selected to the user to obtain the user's selection of the compressed pictures to be selected, the method further comprises:
    当接收到用户的取消选取指令时,向用户发出获取自定义压缩参数指令;When receiving the user's deselection instruction, issue the user-defined compression parameter instruction to the user;
    接收用户输入的自定义压缩参数,根据用户输入的自定义压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The custom compression parameter input by the user is received, and the original picture is recompressed according to the custom compression parameter input by the user and presented to the user for review.
  8. 一种基于人工智能的图片压缩装置,其特征在于,包括:A picture compression device based on artificial intelligence, characterized in that it comprises:
    指令接收模块,用于接收用户输入的图片压缩指令,所述指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数;An instruction receiving module, configured to receive a picture compression instruction input by a user, the instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
    压缩模块,用于响应所述图片压缩指令,根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片;The compression module is configured to respond to the picture compression instruction and compress the original picture according to the compression mode and at least one compression parameter to obtain the compressed picture to be reviewed;
    呈现模块,用于将待审核压缩图片呈现给用户,以使用户对压缩得到的图片进行审核;The presentation module is used to present the compressed picture to be reviewed to the user, so that the user can review the compressed picture;
    调整参数重压缩模块,用于当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核;The adjustment parameter recompression module is used to readjust the compression parameters when the user's review failure instruction is received, and recompress the original picture with the newly adjusted compression parameters and present it to the user for review;
    图片上传模块,用于当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。The image upload module is used to upload the compressed image confirmed by the user to the target location when the user's approval instruction is received.
  9. 如权利要求8所述的基于人工智能的图片压缩装置,其特征在于,所述压缩模块包括:The image compression device based on artificial intelligence according to claim 8, wherein the compression module comprises:
    优先压缩单元,用于根据所述压缩模式以及优先级别最高的压缩参数对原始图片进行压缩;A priority compression unit, configured to compress the original picture according to the compression mode and the compression parameter with the highest priority;
    重新压缩单元,用于按优先级别的顺序选择下一级别的压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The recompression unit is configured to select the compression parameter of the next level as the newly adjusted compression parameter in the order of priority level, and recompress the original picture with the newly adjusted compression parameter and present it to the user for review.
  10. 根据权利要求9所述的基于人工智能的图片压缩装置,其特征在于,所述基于人工智能的图片压缩装置还包括:The artificial intelligence-based picture compression device according to claim 9, wherein the artificial intelligence-based picture compression device further comprises:
    动态调参模块,用于若采用所有的压缩参数所压缩的图片均无法通过用户的审核时,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;The dynamic parameter adjustment module is used to gradually increase and/or decrease the value of the compression parameter with the highest priority according to the preset interval and preset step length if the image compressed by all the compression parameters fails to pass the user's review ;
    待选取压缩图片确定模块,用于以逐渐增加和/或递减后的压缩参数作为新 调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;The to-be-selected compressed picture determining module is used to use the gradually increasing and/or decreasing compression parameters as the newly adjusted compression parameters to re-compress the original pictures to obtain the to-be-selected compressed pictures;
    图片展示模块,用于将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择;The picture display module is used to present the compressed pictures to be selected to the user at the same time, so as to obtain the user's choice of the compressed pictures to be selected;
    图片传输模块,用于当接收到用户确认的选取指令时,将用户选取的压缩图片上传至目标位置。The picture transmission module is used to upload the compressed picture selected by the user to the target location when the selection instruction confirmed by the user is received.
  11. 一种计算机设备,包括存储器和处理器,其特征在于,所述存储器中存储有计算机可读指令,所述处理器执行所述计算机可读指令时实现如下基于人工智能的图片压缩方法的步骤:A computer device includes a memory and a processor, wherein the memory stores computer readable instructions, and the processor implements the following steps of the artificial intelligence-based image compression method when the processor executes the computer readable instructions:
    接收用户输入的图片压缩指令,所述图片压缩指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数;Receiving a picture compression instruction input by a user, the picture compression instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
    根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片;Compress the original picture according to the compression mode and at least one compression parameter to obtain the compressed picture to be reviewed;
    将待审核压缩图片呈现给用户,以使用户对压缩图片进行审核;Present the compressed image to be reviewed to the user so that the user can review the compressed image;
    当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核;When receiving the user's approval failure instruction, readjust the compression parameters, recompress the original picture with the newly adjusted compression parameters and present it to the user for approval;
    当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。When the user's approval instruction is received, the compressed image confirmed by the user is uploaded to the target location.
  12. 根据权利要求11所述的计算机设备,其特征在于,所述压缩模式下包含至少两个具有优先级别的压缩参数;所述根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩的步骤包括:The computer device according to claim 11, wherein the compression mode includes at least two compression parameters with priority levels; the step of compressing the original picture according to the compression mode and at least one compression parameter comprises :
    根据所述压缩模式以及优先级别最高的压缩参数对原始图片进行压缩;Compress the original picture according to the compression mode and the compression parameter with the highest priority;
    所述重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤包括:The step of re-adjusting the compression parameters, re-compressing the original picture with the newly adjusted compression parameters and presenting it to the user for review includes:
    按优先级别的顺序选择下一级别的压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The compression parameter of the next level is selected in the order of priority level as the newly adjusted compression parameter, and the original picture is recompressed with the newly adjusted compression parameter and presented to the user for review.
  13. 根据权利要求12所述的计算机设备,其特征在于,所述重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤之后,所述处理器执行所述计算机可读指令时还实现如下步骤:The computer device according to claim 12, characterized in that, after the step of re-adjusting the compression parameters to recompress the original picture with the newly adjusted compression parameters and present it to the user for review, the processor executes all The following steps are also implemented when the computer-readable instructions are described:
    若采用所有的压缩参数所压缩的图片均无法通过用户的审核时,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;If the pictures compressed with all the compression parameters fail to pass the user's review, the value of the compression parameter with the highest priority is gradually increased and/or decreased according to the preset interval and preset step length;
    以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;Using the gradually increasing and/or decreasing compression parameters as the newly adjusted compression parameters, recompress the original pictures respectively to obtain the compressed pictures to be selected;
    将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择;Present the compressed pictures to be selected to the user at the same time to obtain the user's choice of compressed pictures to be selected;
    当接收到用户确认的选取指令时,将用户选取的压缩图片上传至目标位置。When receiving the selection instruction confirmed by the user, upload the compressed picture selected by the user to the target location.
  14. 根据权利要求13所述的计算机设备,其特征在于,所述将待选取压缩图片同时呈现给用户是将待选取压缩图片按照逐渐增加和/或递减后的压缩参数的大小顺序排列呈现给用户。The computer device according to claim 13, wherein the simultaneous presentation of the compressed pictures to be selected to the user is to arrange and present the compressed pictures to be selected to the user in the order of gradually increasing and/or decreasing compression parameters.
  15. 根据权利要求13所述的计算机设备,其特征在于,所述将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择的步骤之后,所述处理器执行所述计算机可读指令时还实现如下步骤:The computer device according to claim 13, wherein after the step of simultaneously presenting the compressed picture to be selected to the user to obtain the user's selection of the compressed picture to be selected, the processor executes the computer-readable instruction It also implements the following steps:
    当接收到用户的取消选取指令时,向用户发出获取自定义压缩参数指令;When receiving the user's deselection instruction, issue the user-defined compression parameter instruction to the user;
    接收用户输入的自定义压缩参数,根据用户输入的自定义压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The custom compression parameter input by the user is received, and the original picture is recompressed according to the custom compression parameter input by the user and presented to the user for review.
  16. 一种计算机非易失性可读存储介质,其特征在于,所述计算机非易失性可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如下基于人工智能的图片压缩方法的步骤:A computer non-volatile readable storage medium is characterized in that computer readable instructions are stored on the computer non-volatile readable storage medium. When the computer readable instructions are executed by a processor, the following is The steps of the smart image compression method:
    接收用户输入的图片压缩指令,所述图片压缩指令携带有原始图片和压缩模式信息,所述压缩模式信息包含有压缩模式以及在所述压缩模式下的至少一个压缩参数;Receiving a picture compression instruction input by a user, the picture compression instruction carrying an original picture and compression mode information, the compression mode information including a compression mode and at least one compression parameter in the compression mode;
    根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩,得到待审核压缩图片;Compress the original picture according to the compression mode and at least one compression parameter to obtain the compressed picture to be reviewed;
    将待审核压缩图片呈现给用户,以使用户对压缩图片进行审核;Present the compressed image to be reviewed to the user so that the user can review the compressed image;
    当接收到用户的审核不通过指令时,重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核;When receiving the user's approval failure instruction, readjust the compression parameters, recompress the original picture with the newly adjusted compression parameters and present it to the user for approval;
    当接收到用户的审核通过指令时,将用户确认的压缩图片上传至目标位置。When the user's approval instruction is received, the compressed image confirmed by the user is uploaded to the target location.
  17. 根据权利要求16所述的非易失性可读存储介质,其特征在于,所述压缩模式下包含至少两个具有优先级别的压缩参数;所述根据所述压缩模式以及至少一个压缩参数对原始图片进行压缩的步骤包括:The non-volatile readable storage medium according to claim 16, wherein the compression mode contains at least two compression parameters with priority levels; the compression mode and the at least one compression parameter are compared to the original The steps for image compression include:
    根据所述压缩模式以及优先级别最高的压缩参数对原始图片进行压缩;Compress the original picture according to the compression mode and the compression parameter with the highest priority;
    所述重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤包括:The step of re-adjusting the compression parameters, re-compressing the original picture with the newly adjusted compression parameters and presenting it to the user for review includes:
    按优先级别的顺序选择下一级别的压缩参数作为新调整的压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The compression parameter of the next level is selected in the order of priority level as the newly adjusted compression parameter, and the original picture is recompressed with the newly adjusted compression parameter and presented to the user for review.
  18. 根据权利要求17所述的非易失性可读存储介质,其特征在于,所述重新调整压缩参数,以新调整的压缩参数对原始图片进行重新压缩并呈现给所述用户审核的步骤之后,所述计算机可读指令被所述处理器执行时,使得所述处理器还执行如下步骤:The non-volatile readable storage medium according to claim 17, wherein after the step of re-adjusting the compression parameter, recompressing the original picture with the newly adjusted compression parameter and presenting it to the user for review, When the computer-readable instructions are executed by the processor, the processor further executes the following steps:
    若采用所有的压缩参数所压缩的图片均无法通过用户的审核时,将优先级别最高的压缩参数的值按照预设区间和预设步长进行逐渐增加和/或递减;If the pictures compressed with all the compression parameters fail to pass the user's review, the value of the compression parameter with the highest priority is gradually increased and/or decreased according to the preset interval and preset step length;
    以逐渐增加和/或递减后的压缩参数作为新调整的压缩参数,分别对原始图片进行重新压缩,得到待选取压缩图片;Using the gradually increasing and/or decreasing compression parameters as the newly adjusted compression parameters, recompress the original pictures respectively to obtain the compressed pictures to be selected;
    将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择;Present the compressed pictures to be selected to the user at the same time to obtain the user's choice of compressed pictures to be selected;
    当接收到用户确认的选取指令时,将用户选取的压缩图片上传至目标位置。When receiving the selection instruction confirmed by the user, upload the compressed picture selected by the user to the target location.
  19. 根据权利要求18所述的非易失性可读存储介质,其特征在于,所述将待选取压缩图片同时呈现给用户是将待选取压缩图片按照逐渐增加和/或递减后的压缩参数的大小顺序排列呈现给用户。The non-volatile readable storage medium according to claim 18, wherein the simultaneous presentation of the compressed pictures to be selected to the user is to display the compressed pictures to be selected according to the size of the compression parameter after gradually increasing and/or decreasing. The order is presented to the user.
  20. 根据权利要求18所述的非易失性可读存储介质,其特征在于,所述将待选取压缩图片同时呈现给用户,以获取用户对待选取压缩图片的选择的步骤之后,所述计算机可读指令被所述处理器执行时,使得所述处理器还执行如下步骤:The non-volatile readable storage medium according to claim 18, wherein after the step of simultaneously presenting the compressed picture to be selected to the user to obtain the user's selection of the compressed picture to be selected, the computer readable When the instruction is executed by the processor, the processor further executes the following steps:
    当接收到用户的取消选取指令时,向用户发出获取自定义压缩参数指令;When receiving the user's deselection instruction, issue the user-defined compression parameter instruction to the user;
    接收用户输入的自定义压缩参数,根据用户输入的自定义压缩参数对原始图片进行重新压缩并呈现给所述用户审核。The custom compression parameter input by the user is received, and the original picture is recompressed according to the custom compression parameter input by the user and presented to the user for review.
PCT/CN2019/117738 2019-05-08 2019-11-13 Artificial intelligence-based image compression method and apparatus, device, and storage medium WO2020224215A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910383813.6A CN110298895B (en) 2019-05-08 Picture compression method, device, equipment and storage medium based on artificial intelligence
CN201910383813.6 2019-05-08

Publications (1)

Publication Number Publication Date
WO2020224215A1 true WO2020224215A1 (en) 2020-11-12

Family

ID=68026729

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/117738 WO2020224215A1 (en) 2019-05-08 2019-11-13 Artificial intelligence-based image compression method and apparatus, device, and storage medium

Country Status (1)

Country Link
WO (1) WO2020224215A1 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040174554A1 (en) * 2003-03-06 2004-09-09 Samsung Electronics Co., Ltd. Method and apparatus for compressing image data
CN104427341A (en) * 2013-08-28 2015-03-18 腾讯科技(深圳)有限公司 Image processing method and apparatus, and terminal
CN110298895A (en) * 2019-05-08 2019-10-01 平安科技(深圳)有限公司 Picture compression method, apparatus, equipment and storage medium based on artificial intelligence

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040174554A1 (en) * 2003-03-06 2004-09-09 Samsung Electronics Co., Ltd. Method and apparatus for compressing image data
CN104427341A (en) * 2013-08-28 2015-03-18 腾讯科技(深圳)有限公司 Image processing method and apparatus, and terminal
CN110298895A (en) * 2019-05-08 2019-10-01 平安科技(深圳)有限公司 Picture compression method, apparatus, equipment and storage medium based on artificial intelligence

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
NA LIANG: "Study on iOS (10): image compression ratio calculation, compression quality factors and image compression processing", HTTPS://WWW.JIANSHU.COM/P/A1D2D9F69BA5, 24 June 2018 (2018-06-24), pages 1 - 3, XP055751496 *

Also Published As

Publication number Publication date
CN110298895A (en) 2019-10-01

Similar Documents

Publication Publication Date Title
USRE48430E1 (en) Two-dimensional code processing method and terminal
RU2639651C2 (en) Image identification and organization according to model without user intervention
EP2874054B1 (en) Application text adjusting method, device, and terminal
CN110930467A (en) Image processing method, electronic device and readable storage medium
CN111681291A (en) Image processing method, device, equipment and computer readable storage medium
CN110996154B (en) Video playing method and device and electronic equipment
US20200213678A1 (en) Wager information based prioritized live event display system
CN108600675B (en) Channel path number expansion method, device, network video recorder and storage medium
WO2020006860A1 (en) Picture cache cleaning method and apparatus, terminal device and medium
WO2021036442A1 (en) Cyclic edge-preserving smooth filtering method and apparatus, and electronic device
CN106940722B (en) Picture display method and device
US20180248947A1 (en) Metered Network Synchronization
US20150007221A1 (en) Customizing language and content of media for an announcement
KR102398976B1 (en) System for cloud streaming service, method of image cloud streaming service using simultaneous encoding and apparatus for the same
CN108932703B (en) Picture processing method, picture processing device and terminal equipment
US9767075B2 (en) System and method for implementing screen capture
WO2021114709A1 (en) Live video interaction method and apparatus, and computer device
CN112801882B (en) Image processing method and device, storage medium and electronic equipment
CN111008934B (en) Scene construction method, device, equipment and storage medium
WO2020224215A1 (en) Artificial intelligence-based image compression method and apparatus, device, and storage medium
CN111246214B (en) Video decoding method and device
US20220191345A1 (en) System and method for determining compression rates for images comprising text
CN107680038B (en) Picture processing method, medium and related device
CN110298895B (en) Picture compression method, device, equipment and storage medium based on artificial intelligence
KR20160131827A (en) System for cloud streaming service, method of image cloud streaming service using alpha level of color bit and apparatus for the same

Legal Events

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

Ref document number: 19927971

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19927971

Country of ref document: EP

Kind code of ref document: A1