CN108009147B - Electronic book cover generation method, electronic device and computer storage medium - Google Patents
Electronic book cover generation method, electronic device and computer storage medium Download PDFInfo
- Publication number
- CN108009147B CN108009147B CN201711430412.9A CN201711430412A CN108009147B CN 108009147 B CN108009147 B CN 108009147B CN 201711430412 A CN201711430412 A CN 201711430412A CN 108009147 B CN108009147 B CN 108009147B
- Authority
- CN
- China
- Prior art keywords
- electronic book
- word
- words
- effective
- cover
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/10—Text processing
- G06F40/166—Editing, e.g. inserting or deleting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/50—Information retrieval; Database structures therefor; File system structures therefor of still image data
- G06F16/58—Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
- G06F16/583—Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content
- G06F16/5846—Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content using extracted text
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/20—Natural language analysis
- G06F40/279—Recognition of textual entities
- G06F40/289—Phrasal analysis, e.g. finite state techniques or chunking
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Computational Linguistics (AREA)
- General Health & Medical Sciences (AREA)
- Health & Medical Sciences (AREA)
- Artificial Intelligence (AREA)
- Library & Information Science (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Machine Translation (AREA)
Abstract
The invention discloses an electronic book cover generation method, electronic equipment and a computer storage medium. The method comprises the following steps: performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words; for each effective word, inquiring an image element library according to the effective word to obtain an image element corresponding to the effective word, wherein the image element library records the word and the image element corresponding to the word; and processing the plurality of picture elements to obtain a cover corresponding to the electronic book. Based on the scheme provided by the invention, the cover of the electronic book can be automatically generated according to the content of the electronic book, and the generated cover of the electronic book has stronger relevance with the content of the electronic book, so that a user can conveniently select the electronic book according to the cover, and the cover is generated without manual participation, thereby liberating manpower, reducing the labor cost, effectively shortening the time required by generating the cover of the electronic book, and improving the generation efficiency of the electronic book.
Description
Technical Field
The invention relates to the technical field of information processing, in particular to an electronic book cover generation method, electronic equipment and a computer storage medium.
Background
With the continuous development of electronic devices such as mobile phones and electronic book readers, more and more users like reading electronic books. The electronic book has the advantages of convenience in carrying and acquisition and the like. However, many electronic books do not have covers, and when the electronic book is displayed on the bookshelf, the electronic book reading application program displays the electronic book with a default cover, and the default cover has a single presentation mode, is not characterized, and cannot visually reflect the content of the electronic book, so that the user cannot select the electronic book in a targeted manner according to the covers of the electronic book. In the prior art, if an electronic book cover with strong relevance to electronic book content needs to be generated, manual participation is generally needed, the cover is designed and generated, the time for generating the electronic book cover is long, the generating efficiency is low, and the labor cost is greatly increased.
Disclosure of Invention
In view of the above, the present invention has been made to provide an electronic book cover generation method, an electronic device, and a computer storage medium that overcome or at least partially solve the above-mentioned problems.
According to an aspect of the present invention, there is provided an electronic book cover generation method, including:
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring an image element library according to the effective word to obtain an image element corresponding to the effective word, wherein the image element library records the word and the image element corresponding to the word;
and processing the plurality of picture elements to obtain a cover corresponding to the electronic book.
According to another aspect of the present invention, there is provided an electronic apparatus including: the processor, the memory and the communication interface complete mutual communication through the communication bus;
the memory is used for storing at least one executable instruction, and the executable instruction causes the processor to execute the following operations:
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring an image element library according to the effective word to obtain an image element corresponding to the effective word, wherein the image element library records the word and the image element corresponding to the word;
and processing the plurality of picture elements to obtain a cover corresponding to the electronic book.
According to yet another aspect of the present invention, there is provided a computer storage medium having at least one executable instruction stored therein, the executable instruction causing a processor to:
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring an image element library according to the effective word to obtain an image element corresponding to the effective word, wherein the image element library records the word and the image element corresponding to the word;
and processing the plurality of picture elements to obtain a cover corresponding to the electronic book.
According to the scheme provided by the invention, word segmentation processing is carried out on characters in a paragraph to be processed of the electronic book, a word segmentation result is matched with an effective word library, a plurality of effective words are obtained through screening, a picture element library is inquired according to the effective words aiming at each effective word, picture elements corresponding to the effective words are obtained, wherein the picture element library records the words and the picture elements corresponding to the words, and the plurality of picture elements are processed to obtain a cover corresponding to the electronic book. Based on the scheme provided by the invention, the cover of the electronic book can be automatically generated according to the content of the electronic book, and the generated cover of the electronic book has stronger relevance with the content of the electronic book, so that a user can conveniently select the electronic book according to the cover, and the cover is generated without manual participation, thereby liberating manpower, reducing the labor cost, effectively shortening the time required by generating the cover of the electronic book, and improving the generation efficiency of the electronic book.
The foregoing description is only an overview of the technical solutions of the present invention, and the embodiments of the present invention are described below in order to make the technical means of the present invention more clearly understood and to make the above and other objects, features, and advantages of the present invention more clearly understandable.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to refer to like parts throughout the drawings. In the drawings:
fig. 1 is a flowchart illustrating a method for generating covers of an electronic book according to a first embodiment of the present invention;
FIG. 2 is a flowchart illustrating a method for generating covers of an electronic book according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of an electronic device according to a fourth embodiment of the present invention;
fig. 4 is a schematic diagram of the generated cover of the electronic book.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
Example one
Fig. 1 is a flowchart illustrating a method for generating covers of an electronic book according to an embodiment of the present invention. As shown in fig. 1, the method comprises the steps of:
step S101, performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching word segmentation results with an effective word bank, and screening to obtain a plurality of effective words.
In order to generate a cover which fully reflects the content of the electronic book, the characters in the paragraphs to be processed of the electronic book need to be participled before generating the cover of the electronic book, and in the prior art, there are various word segmentation methods, for example, a word segmentation method based on character string matching, a word segmentation method based on understanding, a word segmentation method based on statistics, and the like, and a person skilled in the art can select the paragraphs according to needs or comprehensively use various methods for word segmentation.
The effective words are used for performing identification indication on the content of the electronic book, the effective word lexicon is a set of effective words, and a large number of words are stored, so that after word segmentation processing is performed to obtain word segmentation results, the effective words need to be screened from the word segmentation results, specifically, the word segmentation results obtained by the word segmentation processing can be matched with the effective word lexicon, if corresponding words can be inquired in the effective word lexicon, the words are considered as effective words, and then the effective words are screened from the word segmentation results.
And S102, inquiring the picture element library according to the effective words aiming at each effective word to obtain the picture elements corresponding to the effective words.
In the embodiment of the invention, the picture element library records words and picture elements corresponding to the words, the picture elements are important elements forming the cover, each picture element corresponds to one or more words, the picture elements are closely related to the words, and the picture elements can show emotional colors and the like carried by the words, so that after the effective words are determined by using the step S101, the picture element library can be inquired by using the effective words to obtain the picture elements corresponding to the effective words.
Step 103, processing the plurality of picture elements to obtain a cover corresponding to the electronic book.
After obtaining the picture element corresponding to the valid word according to step S102, a plurality of picture elements may be processed, for example, the plurality of picture elements are combined together to obtain a cover corresponding to the electronic book.
For different electronic books, the effective words obtained by screening are different, so that the picture elements obtained according to the effective words are also different, and further, the generated electronic book covers are also different, and which electronic book the cover corresponds to can be determined according to the electronic book covers, that is, the generated electronic book covers have a certain degree of identification.
According to the method provided by the above embodiment of the present invention, word segmentation processing is performed on characters in a to-be-processed paragraph of an electronic book, a word segmentation result is matched with an effective word lexicon, a plurality of effective words are obtained by screening, for each effective word, a picture element library is queried according to the effective word, and a picture element corresponding to the effective word is obtained, wherein the picture element library records the word and the picture element corresponding to the word, and the plurality of picture elements are processed to obtain a cover corresponding to the electronic book. Based on the scheme provided by the invention, the cover of the electronic book can be automatically generated according to the content of the electronic book, and the generated cover of the electronic book has stronger relevance with the content of the electronic book, so that a user can conveniently select the electronic book according to the cover, and the cover is generated without manual participation, thereby liberating manpower, reducing the labor cost, effectively shortening the time required by generating the cover of the electronic book, and improving the generation efficiency of the electronic book.
Example two
Fig. 2 is a flowchart illustrating a method for generating covers of an electronic book according to a second embodiment of the present invention. As shown in fig. 2, the method comprises the steps of:
step S201, counting the number of comment information added to each paragraph of the electronic book by the user.
If all the paragraphs of the electronic book are subjected to word segmentation to determine valid words and then determine that the picture elements corresponding to the valid words generate covers, a lot of time is occupied, and the information conveyed to a user by the generated covers is unclear and ambiguous, so that the paragraphs to be processed need to be determined first.
The comment information is the evaluation of the user on the content of the electronic book, and the number of the comment information added to each paragraph in the electronic book by the user can reflect whether the paragraph is a popular paragraph or not and whether the paragraph is a paragraph concerned by most users or not, so that the paragraph to be processed can be determined according to the number of the comment information, and specifically, the number of the comment information added to each paragraph of the electronic book by the user needs to be counted first.
Step S202, determining paragraphs to be processed according to the number of the comment information.
After the number of comment information added to each paragraph of the electronic book by the user is determined through statistics, each paragraph can be sequenced according to the number of the comment information, and the paragraph with a large number of comment information is selected as the paragraph to be processed.
In an optional embodiment of the present invention, other methods may also be used to determine the paragraphs to be processed, for example, a general e-book author may describe a climax part of the e-book with more characters, which is a most colorful part of a story line, so that the paragraphs to be processed may be determined according to the number of characters in the paragraphs, and specifically, the number of characters in each paragraph of the e-book may be counted; and determining paragraphs with the number of characters larger than or equal to a first preset number as paragraphs to be processed. Of course, the paragraphs in a highlight chapter in the electronic book may also be regarded as the to-be-processed paragraphs, where the chapters with a larger text length are regarded as the highlight chapter, or each chapter randomly selects a certain number of paragraphs as the to-be-processed paragraphs, for example, one or two paragraphs are randomly selected as the to-be-processed paragraphs.
Step S203, splitting characters in a to-be-processed paragraph of the electronic book into a plurality of words, filtering the split words, removing common words in the words, matching the remaining words with an effective word library, and screening to obtain a plurality of effective words.
After the paragraphs to be processed are determined, the picture element library can be queried according to the words in the paragraphs to be processed to obtain corresponding picture elements, and then the cover is generated according to the determined picture elements, however, the paragraphs may contain some words which cannot objectively represent the plot content of the electronic book and the like, and these words are called common words, and if the cover is made by using the picture elements obtained by querying the words, the effect of the cover on conveying the content of the electronic book to the user is seriously affected, so that the words in the paragraphs need to be firstly participled, the words in the paragraphs to be processed of the electronic book are divided into a plurality of words, and then the divided words are filtered to remove the common words, such as "my", "this", and the like.
Although common words are removed from the split words, the remaining words may also include words that have little meaning for generating a cover, and therefore the remaining words need to be matched with the valid word lexicon, and if corresponding words can be queried in the valid word lexicon, the words are considered as valid words, so that a plurality of valid words are obtained by screening.
Step S204, counting the word frequency of the effective words aiming at each effective word, selecting a second preset number of effective words according to the word frequency, and querying the picture element library by using the selected effective words to obtain corresponding picture elements.
After a plurality of effective words are obtained through screening, the word frequency of each effective word needs to be counted, wherein the word frequency is the number of times that the effective word appears in a paragraph to be processed, after the word frequency of the effective word is determined, the effective words can be sequenced according to the word frequency, a second preset number of effective words are selected from the effective words, the word frequency of the selected effective words is higher than the word frequency of the unselected effective words, then, the selected effective words are used for querying a picture element library, wherein the picture element library records the words and picture elements corresponding to the words, the picture elements are important elements forming a cover, each picture element corresponds to one or more words, the picture elements are closely related to the words, and the picture elements can represent emotional colors and the like carried by the words.
For example, 20 effective words are obtained by searching the effective word bank, the word frequency of the 20 effective words is statistically determined, the 20 effective words are ranked according to the sequence of the word frequency from high to low, then 10 effective words with the top rank are selected from the ranked effective words, the picture element bank is queried by using the selected 10 effective words to obtain the picture element corresponding to each effective word, which is only an example, and a person skilled in the art can set a second preset number of values according to actual needs, and is not specifically limited herein.
In the embodiment of the present invention, a term may also correspond to one or more picture elements, that is, one or more picture elements may be queried by querying the picture element library according to the valid term. For the case that a valid word is associated with a plurality of picture elements, the picture element that is most matched with the valid word may be determined according to the e-book tag, and specifically, the following method may be adopted:
in step S205, if a plurality of picture elements are found according to a valid word, a picture element corresponding to an e-book tag is screened out from the plurality of picture elements according to the e-book tag.
First, the e-book tag corresponding to the e-book can be determined according to the content of the e-book, where the e-book tag is a description of the type of the e-book, and for example, the e-book tag may be suspense, fantasy, inspirational, and the like, and here, the description is only an example, and does not have any limiting effect. In an optional embodiment of the present invention, a user may submit an e-book tag corresponding to an e-book according to content of the e-book, that is, obtain an e-book tag uploaded by a client, where an e-book tag obtaining manner is not specifically limited.
When a plurality of picture elements are searched according to an effective word, the picture elements corresponding to the e-book tags can be screened out from the plurality of picture elements according to the e-book tags, specifically, for the condition that a word corresponds to the plurality of picture elements, the type corresponding to each picture element, such as suspense, mysterious illusion and the like, can be recorded in the picture element library, the e-book tags represent the e-book types, the e-book tags are matched with the types corresponding to the picture elements, and the picture elements corresponding to the types consistent to the e-book tags are the picture elements corresponding to the effective word.
In the embodiment of the present invention, step S205 is an optional step, that is, if only one picture element is queried according to each valid word, step S205 may be skipped and subsequent method steps may be performed.
In step S206, cover text is acquired, and the position information of the cover text in the cover is determined according to the character number.
The cover text is a text part displayed in the cover, which can convey corresponding information to the user, specifically, the book name, the publisher, the publication time, etc. of the electronic book, and the cover text can be set according to the actual needs, for example, the cover may only contain the book name, or contain the book name, the publisher, the publication time, and may also contain other text.
After acquiring the cover text, the position of the cover text in the cover needs to be determined for the cover text, and specifically, the position of the text in the cover can be determined according to the text word number of the cover text, for example, the cover text with a larger word number can be set at one third of the cover, the cover text with a smaller word number can be set at the bottom of the cover, and for example, the cover text "XX publisher" can be set at the bottom of the cover, as shown in fig. 4, which is only an example and does not have any limiting effect.
In the embodiment of the present invention, step S206 is an optional step, that is, only the cover containing the picture elements can be generated by using the provided method for generating the cover of the electronic book, that is, the cover does not contain the text part, so that the subsequent method steps can be executed by skipping step S206.
Step S207, adjusting the size, direction and color of the picture element.
In order to make the picture elements more fully reflect the emotional colors and the like of words, the sizes, the directions, the colors and the like of the picture elements can be adjusted, for example, the color matching and the brightness of the picture elements can be adjusted through color adjustment, the sizes of the picture elements can be adjusted through adjusting the pixels of the picture elements, and a plurality of angles of the picture elements can be obtained through a rotating mode, so that various expression effects are achieved.
In the embodiment of the present invention, step S207 is an optional step, that is, the multiple picture elements may be directly processed without any adjustment on the picture elements, that is, step S207 is skipped, so as to obtain the cover corresponding to the electronic book.
And S208, combining the cover characters and the adjusted multiple picture elements according to the position information of the cover characters to obtain a cover corresponding to the electronic book.
After the position information of the cover text and the size, direction and color of the picture elements are determined, the cover text and the adjusted picture elements can be combined according to actual needs according to the position information of the cover text, and a cover corresponding to the electronic book is obtained.
The cover is generated by selecting the picture elements according to the characters in the electronic book, so that the cover of the electronic book is related to the content of the electronic book, different electronic books can query the picture element library according to the effective words because the selected effective words are different, the obtained picture elements are different, and the generated covers are different, namely, the generated cover of the electronic book has a certain identification degree, and which electronic book corresponds to the cover can be determined according to the cover of the electronic book.
In the embodiment of the present invention, if the cover does not include the text portion, after the size, the direction, and the color of the picture elements are adjusted, the adjusted picture elements may be directly processed to obtain the cover corresponding to the electronic book.
The method for generating the cover of the electronic book can generate a cover for the electronic book without the cover, and the electronic books can be made or downloaded by a user; or regenerating a new cover for the electronic book containing the cover of the electronic book to replace the original cover; the cover may also be generated for the e-book that has just been written, and is not limited in particular here.
The execution main body of the electronic book cover generation method provided by the embodiment of the invention can be a server side or a client side; if the execution main body is a client, the client can receive the valid word library and the picture element library sent by the server and store the valid word library and the picture element library to the local of the client, and after the client acquires the electronic book, the client executes the method to generate the cover of the electronic book and displays the cover of the electronic book. In order to generate an e-book cover with a strong correlation with the content of the e-book, the server may periodically send the updated valid word lexicon and picture element library to the client, so that the client updates the local valid word lexicon and picture element library.
According to the method provided by the above embodiment of the present invention, the paragraphs to be processed are determined according to the amount of comment information of each paragraph by the user, so that the generated cover can more accurately represent the content of the electronic book, after the paragraphs to be processed are subjected to word segmentation processing, common words are removed from the word segmentation result, the remaining words are matched with the valid word lexicon, a plurality of valid words are obtained by screening, the matching frequency can be effectively reduced, the cover generation efficiency is improved, the valid words with higher word frequency are selected to query the picture element library, if a plurality of picture elements are queried according to one valid word, the picture elements corresponding to the electronic book tags are screened from the plurality of picture elements according to the electronic book tags, the size, direction and color of the picture elements are adjusted, the cover is generated according to the adjusted picture elements, so that the generated cover can more accurately represent the content of the electronic book, according to the scheme provided by the invention, the cover of the electronic book can be automatically generated according to the content of the electronic book, the generated cover of the electronic book has strong relevance with the content of the electronic book, a user can conveniently select the electronic book according to the cover, the cover is not required to be generated manually, the manpower is liberated, the labor cost is reduced, the time required by generating the cover of the electronic book is effectively shortened, and the generating efficiency of the electronic book is improved.
EXAMPLE III
The third embodiment of the present application provides a non-volatile computer storage medium, where the computer storage medium stores at least one executable instruction, and the computer executable instruction may execute the method for generating an electronic book cover in any of the above method embodiments.
The executable instructions may be specifically configured to cause the processor to:
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring an image element library according to the effective word to obtain an image element corresponding to the effective word, wherein the image element library records the word and the image element corresponding to the word;
and processing the plurality of picture elements to obtain a cover corresponding to the electronic book.
In an alternative embodiment, the executable instructions further cause the processor to:
the method comprises the steps of splitting characters in a to-be-processed paragraph of the electronic book into a plurality of words, filtering the split words, removing common words in the words, matching the remaining words with an effective word lexicon, and screening to obtain a plurality of effective words.
In an alternative embodiment, the executable instructions further cause the processor to:
counting the number of comment information added to each paragraph of the electronic book by a user;
and determining the paragraphs to be processed according to the number of the comment information.
In an alternative embodiment, the executable instructions further cause the processor to:
counting the number of characters in each paragraph of the electronic book;
and determining paragraphs with the number of characters larger than or equal to a first preset number as paragraphs to be processed.
In an alternative embodiment, the executable instructions further cause the processor to:
counting the word frequency of the effective words aiming at each effective word, wherein the word frequency is the frequency of the effective words appearing in the paragraphs;
and selecting a second preset number of effective words according to the word frequency, and querying the picture element library by using the selected effective words to obtain corresponding picture elements.
In an alternative embodiment, the executable instructions further cause the processor to:
adjusting the size, direction and color of the picture elements;
and combining the adjusted picture elements to obtain a cover corresponding to the electronic book.
In an alternative embodiment, the executable instructions further cause the processor to:
acquiring an electronic book label;
processing the plurality of picture elements to obtain a cover corresponding to the electronic book further comprises:
if a plurality of picture elements are inquired according to an effective word, screening the picture elements corresponding to the electronic book labels from the plurality of picture elements according to the electronic book labels;
and combining the picture elements obtained by screening with the picture elements of other effective words to obtain a cover corresponding to the electronic book.
In an alternative embodiment, the executable instructions further cause the processor to:
acquiring cover characters, and determining position information of the cover characters in a cover according to the character number;
and combining the cover characters and the plurality of picture elements according to the position information of the cover characters to obtain a cover corresponding to the electronic book.
Example four
Fig. 3 is a schematic structural diagram of an electronic device according to a sixth embodiment of the present invention, and the specific embodiment of the present invention does not limit the specific implementation of the electronic device.
As shown in fig. 3, the electronic device may include: a processor (processor)302, a communication Interface 304, a memory 306, and a communication bus 308.
Wherein:
the processor 302, communication interface 304, and memory 306 communicate with each other via a communication bus 308.
A communication interface 304 for communicating with network elements of other devices, such as clients or other servers.
The processor 302 is configured to execute the program 310, and may specifically execute relevant steps in the above-described electronic book cover generation method embodiment.
In particular, program 310 may include program code comprising computer operating instructions.
The processor 302 may be a central processing unit CPU, or an application specific Integrated circuit (asic), or one or more Integrated circuits configured to implement an embodiment of the present invention. The electronic device comprises one or more processors, which can be the same type of processor, such as one or more CPUs; or may be different types of processors such as one or more CPUs and one or more ASICs.
And a memory 306 for storing a program 310. Memory 306 may comprise high-speed RAM memory and may also include non-volatile memory (non-volatile memory), such as at least one disk memory.
The program 310 may specifically be configured to cause the processor 302 to perform the following operations:
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring an image element library according to the effective word to obtain an image element corresponding to the effective word, wherein the image element library records the word and the image element corresponding to the word;
and processing the plurality of picture elements to obtain a cover corresponding to the electronic book.
In an alternative embodiment, program 310 further causes processor 302 to:
the method comprises the steps of splitting characters in a to-be-processed paragraph of the electronic book into a plurality of words, filtering the split words, removing common words in the words, matching the remaining words with an effective word lexicon, and screening to obtain a plurality of effective words.
In an alternative embodiment, program 310 also causes processor 302 to:
counting the number of comment information added to each paragraph of the electronic book by a user;
and determining the paragraphs to be processed according to the number of the comment information.
In an alternative embodiment, program 310 also causes processor 302 to:
counting the number of characters in each paragraph of the electronic book;
and determining paragraphs with the number of characters larger than or equal to a first preset number as paragraphs to be processed.
In an alternative embodiment, program 310 further causes processor 302 to:
counting the word frequency of the effective words aiming at each effective word, wherein the word frequency is the frequency of the effective words appearing in the paragraphs;
and selecting a second preset number of effective words according to the word frequency, and querying the picture element library by using the selected effective words to obtain corresponding picture elements.
In an alternative embodiment, program 310 further causes processor 302 to:
adjusting the size, direction and color of the picture elements;
and combining the adjusted picture elements to obtain a cover corresponding to the electronic book.
In an alternative embodiment, program 310 also causes processor 302 to:
acquiring an electronic book label;
if a plurality of picture elements are inquired according to an effective word, screening the picture elements corresponding to the electronic book labels from the plurality of picture elements according to the electronic book labels;
and combining the picture elements obtained by screening with the picture elements of other effective words to obtain a cover corresponding to the electronic book.
In an alternative embodiment, program 310 further causes processor 302 to:
acquiring cover characters, and determining position information of the cover characters in a cover according to the character number;
and combining the cover characters and the plurality of picture elements according to the position information of the cover characters to obtain a cover corresponding to the electronic book.
The algorithms and displays presented herein are not inherently related to any particular computer, virtual machine, or other apparatus. Various general purpose systems may also be used with the teachings herein. The required structure for constructing such a system will be apparent from the description above. Moreover, the present invention is not directed to any particular programming language. It is appreciated that a variety of programming languages may be used to implement the teachings of the present invention as described herein, and any descriptions of specific languages are provided above to disclose the best mode of the invention.
In the description provided herein, numerous specific details are set forth. It is understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure and aiding in the understanding of one or more of the various inventive aspects. However, the disclosed method should not be interpreted as reflecting an intention that: that the invention as claimed requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the detailed description are hereby expressly incorporated into this detailed description, with each claim standing on its own as a separate embodiment of this invention.
Those skilled in the art will appreciate that the modules in the device in an embodiment may be adaptively changed and disposed in one or more devices different from the embodiment. The modules or units or components of the embodiments may be combined into one module or unit or component, and furthermore they may be divided into a plurality of sub-modules or sub-units or sub-components. All of the features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or elements of any method or apparatus so disclosed, may be combined in any combination, except combinations where at least some of such features and/or processes or elements are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
Furthermore, those skilled in the art will appreciate that while some embodiments described herein include some features included in other embodiments, rather than other features, combinations of features of different embodiments are meant to be within the scope of the invention and form different embodiments. For example, in the following claims, any of the claimed embodiments may be used in any combination.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and that those skilled in the art will be able to design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. The usage of the words first, second and third, etcetera do not indicate any ordering. These words may be interpreted as names.
Claims (18)
1. An electronic book cover generation method includes:
determining a paragraph to be processed of the electronic book;
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring a picture element library according to the effective word to obtain picture elements corresponding to the effective word, wherein the picture element library records the word and the picture elements corresponding to the word, the picture elements are elements forming a cover, and each picture element corresponds to one or more words;
combining the plurality of picture elements to obtain a cover corresponding to the electronic book;
wherein, the combining the plurality of picture elements to obtain the cover corresponding to the electronic book further comprises: adjusting the size, direction and color of the picture elements; acquiring cover characters, and determining position information of the cover characters in a cover according to the character number; and combining the cover characters and the adjusted multiple picture elements according to the position information of the cover characters to obtain a cover corresponding to the electronic book.
2. The method of claim 1, wherein the performing word segmentation on the characters in the to-be-processed paragraphs of the electronic book, matching the word segmentation result with a valid word lexicon, and screening to obtain a plurality of valid words further comprises:
the method comprises the steps of splitting characters in a to-be-processed paragraph of the electronic book into a plurality of words, filtering the split words, removing common words in the words, matching the remaining words with an effective word lexicon, and screening to obtain a plurality of effective words.
3. The method of claim 1 or 2, wherein before performing the word segmentation processing on the characters in the to-be-processed paragraphs of the electronic book, the method further comprises:
counting the number of comment information added to each paragraph of the electronic book by a user;
and determining the paragraphs to be processed according to the number of the comment information.
4. The method of claim 1 or 2, wherein before performing the word segmentation processing on the characters in the to-be-processed paragraphs of the electronic book, the method further comprises:
counting the number of characters in each paragraph of the electronic book;
and determining paragraphs with the number of characters larger than or equal to a first preset number as paragraphs to be processed.
5. The method according to claim 1 or 2, wherein the querying, for each valid word, the picture element library according to the valid word to obtain the picture element corresponding to the valid word further comprises:
counting the word frequency of the effective words aiming at each effective word, wherein the word frequency is the frequency of the effective words appearing in the paragraphs;
and selecting a second preset number of effective words according to the word frequency, and querying the picture element library by using the selected effective words to obtain corresponding picture elements.
6. The method according to claim 1 or 2, wherein the method further comprises: acquiring an electronic book label;
the processing the plurality of picture elements to obtain a cover corresponding to the electronic book further comprises:
if a plurality of picture elements are inquired according to an effective word, screening the picture elements corresponding to the electronic book labels from the plurality of picture elements according to the electronic book labels;
and combining the picture elements obtained by screening with the picture elements of other effective words to obtain a cover corresponding to the electronic book.
7. An electronic device, comprising: the system comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete mutual communication through the communication bus;
the memory is configured to store at least one executable instruction that causes the processor to:
determining a paragraph to be processed of the electronic book;
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring a picture element library according to the effective word to obtain picture elements corresponding to the effective word, wherein the picture element library records the word and the picture elements corresponding to the word, the picture elements are elements forming a cover, and each picture element corresponds to one or more words;
combining the plurality of picture elements to obtain a cover corresponding to the electronic book;
wherein the executable instructions further cause the processor to: adjusting the size, direction and color of the picture elements; acquiring cover characters, and determining position information of the cover characters in a cover according to the character number; and combining the cover characters and the adjusted multiple picture elements according to the position information of the cover characters to obtain a cover corresponding to the electronic book.
8. The electronic device of claim 7, wherein the executable instructions further cause the processor to:
the method comprises the steps of splitting characters in a to-be-processed paragraph of the electronic book into a plurality of words, filtering the split words, removing common words in the words, matching the remaining words with an effective word lexicon, and screening to obtain a plurality of effective words.
9. The electronic device of claim 7 or 8, wherein the executable instructions further cause the processor to:
counting the number of comment information added to each paragraph of the electronic book by a user;
and determining the paragraphs to be processed according to the number of the comment information.
10. The electronic device of claim 7 or 8, wherein the executable instructions further cause the processor to:
counting the number of characters in each paragraph of the electronic book;
and determining paragraphs with the number of characters larger than or equal to a first preset number as paragraphs to be processed.
11. The electronic device of claim 7 or 8, wherein the executable instructions further cause the processor to:
counting the word frequency of the effective words aiming at each effective word, wherein the word frequency is the frequency of the effective words appearing in the paragraphs;
and selecting a second preset number of effective words according to the word frequency, and querying the picture element library by using the selected effective words to obtain corresponding picture elements.
12. The electronic device of claim 7 or 8, wherein the executable instructions further cause the processor to:
acquiring an electronic book label;
if a plurality of picture elements are inquired according to an effective word, screening the picture elements corresponding to the electronic book labels from the plurality of picture elements according to the electronic book labels;
and combining the picture elements obtained by screening with the picture elements of other effective words to obtain a cover corresponding to the electronic book.
13. A computer storage medium having at least one executable instruction stored therein, the executable instruction causing a processor to:
determining a paragraph to be processed of the electronic book;
performing word segmentation on characters in a to-be-processed paragraph of the electronic book, matching a word segmentation result with an effective word library, and screening to obtain a plurality of effective words;
for each effective word, inquiring a picture element library according to the effective word to obtain picture elements corresponding to the effective word, wherein the picture element library records the word and the picture elements corresponding to the word, the picture elements are elements forming a cover, and each picture element corresponds to one or more words;
combining the plurality of picture elements to obtain a cover corresponding to the electronic book;
wherein the executable instructions further cause the processor to: adjusting the size, direction and color of the picture elements; acquiring cover characters, and determining position information of the cover characters in a cover according to the character number; and combining the cover characters and the adjusted multiple picture elements according to the position information of the cover characters to obtain a cover corresponding to the electronic book.
14. The computer storage medium of claim 13, the executable instructions further causing the processor to:
the method comprises the steps of splitting characters in a to-be-processed paragraph of the electronic book into a plurality of words, filtering the split words, removing common words in the words, matching the remaining words with an effective word lexicon, and screening to obtain a plurality of effective words.
15. The computer storage medium of claim 13 or 14, the executable instructions further causing the processor to:
counting the number of comment information added to each paragraph of the electronic book by a user;
and determining the paragraphs to be processed according to the number of the comment information.
16. The computer storage medium of claim 13 or 14, the executable instructions further causing the processor to:
counting the number of characters in each paragraph of the electronic book;
and determining paragraphs with the number of characters larger than or equal to a first preset number as paragraphs to be processed.
17. The computer storage medium of claim 13 or 14, the executable instructions further causing the processor to:
counting the word frequency of the effective words aiming at each effective word, wherein the word frequency is the frequency of the effective words appearing in the paragraphs;
and selecting a second preset number of effective words according to the word frequency, and querying the picture element library by using the selected effective words to obtain corresponding picture elements.
18. The computer storage medium of claim 13 or 14, the executable instructions further causing the processor to:
acquiring an electronic book label;
if a plurality of picture elements are inquired according to an effective word, screening the picture elements corresponding to the electronic book labels from the plurality of picture elements according to the electronic book labels;
and combining the picture elements obtained by screening with the picture elements of other effective words to obtain a cover corresponding to the electronic book.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711430412.9A CN108009147B (en) | 2017-12-26 | 2017-12-26 | Electronic book cover generation method, electronic device and computer storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711430412.9A CN108009147B (en) | 2017-12-26 | 2017-12-26 | Electronic book cover generation method, electronic device and computer storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108009147A CN108009147A (en) | 2018-05-08 |
CN108009147B true CN108009147B (en) | 2020-11-03 |
Family
ID=62061366
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711430412.9A Active CN108009147B (en) | 2017-12-26 | 2017-12-26 | Electronic book cover generation method, electronic device and computer storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108009147B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109241323B (en) * | 2018-09-13 | 2019-10-22 | 掌阅科技股份有限公司 | The method for generating user's poster is commented on based on e-book and calculates equipment |
CN109213408B (en) * | 2018-09-20 | 2019-09-24 | 掌阅科技股份有限公司 | Books display methods, electronic equipment and computer storage medium |
CN110209898A (en) * | 2019-05-31 | 2019-09-06 | 苏州狗尾草智能科技有限公司 | Data cleaning method, answering method, device and medium based on human-computer interaction |
CN110490954B (en) * | 2019-08-07 | 2024-01-02 | 北京达佳互联信息技术有限公司 | Cover generation method and device, electronic equipment and storage medium |
CN111880888B (en) * | 2020-08-07 | 2022-12-27 | 北京达佳互联信息技术有限公司 | Preview cover generation method and device, electronic equipment and storage medium |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104915402A (en) * | 2015-06-01 | 2015-09-16 | 小米科技有限责任公司 | Method and device for setting cover of electronic book |
CN106485769A (en) * | 2016-10-13 | 2017-03-08 | 珠海市魅族科技有限公司 | E-book front cover generation method and device |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP3880307B2 (en) * | 2000-11-13 | 2007-02-14 | キヤノン株式会社 | Information processing apparatus and method |
CN104331496B (en) * | 2014-11-19 | 2018-09-18 | 杭州网易云音乐科技有限公司 | Picture sharing method and equipment |
CN104462590B (en) * | 2014-12-30 | 2019-03-12 | 百度在线网络技术(北京)有限公司 | Information search method and device |
CN107066596A (en) * | 2017-04-19 | 2017-08-18 | 北京小米移动软件有限公司 | The method and apparatus for generating link information |
-
2017
- 2017-12-26 CN CN201711430412.9A patent/CN108009147B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104915402A (en) * | 2015-06-01 | 2015-09-16 | 小米科技有限责任公司 | Method and device for setting cover of electronic book |
CN106485769A (en) * | 2016-10-13 | 2017-03-08 | 珠海市魅族科技有限公司 | E-book front cover generation method and device |
Also Published As
Publication number | Publication date |
---|---|
CN108009147A (en) | 2018-05-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108009147B (en) | Electronic book cover generation method, electronic device and computer storage medium | |
CN102930523B (en) | Picture processing system and picture splicing implementation method | |
CN105046678B (en) | A kind of device, method and picture processing system for realizing picture splicing | |
CN107590174B (en) | Page access method and device | |
US8812947B1 (en) | Ranking graphical visualizations of a data set according to data attributes | |
CN111125543B (en) | Training method of book recommendation sequencing model, computing device and storage medium | |
CN109829108B (en) | Information recommendation method and device, electronic equipment and readable storage medium | |
CN106096003B (en) | Data searching method and client | |
EP3109775A1 (en) | Multimedia content providing method and device | |
CN104598602A (en) | Scene-based information recommendation method realized through computer and device | |
US8290925B1 (en) | Locating product references in content pages | |
CN108170293A (en) | Input the personalized recommendation method and device of association | |
CN103902679B (en) | Method and apparatus are recommended in search | |
CN107748772B (en) | Trademark identification method and device | |
CN110515929B (en) | Book display method, computing device and storage medium | |
CN109408618B (en) | Keyword recommendation method and device, storage medium and electronic equipment | |
CN109783678B (en) | Image searching method and device | |
CN106649750B (en) | Searching method and device for multi-meaning term entry | |
CN110990701B (en) | Book searching method, computing device and computer storage medium | |
WO2016155384A1 (en) | Search optimization method, apparatus, and system | |
CN112528665A (en) | Information extraction method based on semantic understanding | |
CN109451018B (en) | Information object pushing method, computing device and computer storage medium | |
CN104657480B (en) | Caricature searching method and device | |
CN110990558B (en) | Electronic book content display method, computing equipment and computer storage medium | |
CN106407444A (en) | Retrieval method and device, and terminal |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right |
Effective date of registration: 20220630 Address after: 518054-13098, 13th floor, main tower of marine center, No. 59, Linhai Avenue, Qianhai Shenzhen Hong Kong cooperation zone, Shenzhen, Guangdong Patentee after: Shenzhen ZhangYue Animation Technology Co.,Ltd. Address before: 100124 2029e, Sihui building, Chaoyang District, Beijing Patentee before: ZHANGYUE TECHNOLOGY Co.,Ltd. |
|
TR01 | Transfer of patent right |